949 Commits

Author SHA1 Message Date
Ying Wang
33c29b0e16 Use BUILD_PREBUILT to install the shell script
NOTICE files will be picked up automatically.

Change-Id: Ia4938aff013f1c010cbbfceacf5685722c86c39a
2013-02-19 16:42:16 -08:00
Dianne Hackborn
c652de8141 Implement display overscan support.
The window manager now keeps track of the overscan of
each display, with an API to set it.  The overscan impacts
how it positions windows in the display.  There is a new set
of APIs for windows to say they would like to go into the
overscan region.  There is a call into the window manager to
set the overscan region for a display, and it now has a
concept of display settings that it stores presistently.

Also added a new "wm" command, moving the window manager
specific commands from the "am" command to there and adding
a new now to set the overscan region.

Change-Id: Id2c8092db64fd0a982274fedac7658d82f30f9ff
2013-02-19 12:08:58 -08:00
Dianne Hackborn
50707cc820 Fix issue #8133857: Tracking ANR in Gallery
Reworking the locking in resources so that we never hold the
state lock while calling in to potential long running operations.
This means the mTmpValue can no longer be final (since we need
to use it while the lock isn't held), so a new field needs to
be added as the lock and everything that touches mTmpValue must
deal with it being null, restoring the value in there when
possible, etc.

Change-Id: Ie5ffd0f66e5f2d0e869a62d72e7a55b1c74fe872
2013-02-08 17:18:03 -08:00
Dianne Hackborn
f51f61269a App ops: new operations for SMS.
Implementation required a new framework feature
to associate an app op with a broadcast.

Change-Id: I4ff41a52f7ad4ee8fd80cbf7b394f04d6c4315b3
2013-02-05 11:56:12 -08:00
Dianne Hackborn
f265ea9d83 App ops: vibration, neighboring cells, dialing, etc.
Improve handling of vibration op, so that apps are
better blamed (there is now a hidden vibrator API that
supplies the app to blame, and the system now uses this
when vibrating on behalf of an app).

Add operation for retrieving neighboring cell information.

Add a new op for calling a phone number.  This required
plumbing information about the launching package name through
the activity manager, which required changing the internal
startActivity class, which required hitting a ton of code that
uses those internal APIs.

Change-Id: I3f8015634fdb296558f07fe654fb8d53e5c94d07
2013-02-01 15:14:29 -08:00
Daniel Sandler
6fc736971a Merge "Implement support for method calls in the content tool." 2013-01-29 20:52:44 +00:00
Daniel Sandler
d2c0c1021e Implement support for method calls in the content tool.
$ content call
    --uri content://com.example
    --method methodname
    [--arg optional_string_arg]
    [--extra name:s:foo --extra value:i:0]

The URI is just used to resolve the provider. --extra has
the same syntax as --bind.

Change-Id: I98cb89f0174a00e7c29ca0d8c8d809d453de3623
2013-01-29 14:27:21 -05:00
Svetoslav Ganov
d0fd54648c Merge "Adding UI test automation APIs." 2013-01-29 03:16:40 +00:00
Svetoslav Ganov
80943d8daa Adding UI test automation APIs.
This change adds APIs support for implementing UI tests. Such tests do
not rely on internal application structure and can span across application
boundaries. UI automation APIs are encapsulated in the UiAutomation object
that is provided by an Instrumentation object. It is initialized by the
system and can be used for both introspecting the screen and performing
interactions simulating a user. UI test are normal instrumentation tests
and are executed on the device.

UiAutomation uses the accessibility APIs to introspect the screen and
a special delegate object to perform privileged operations such as
injecting input events. Since instrumentation tests are invoked by a shell
command, the shell program launching the tests creates a delegate object and
passes it as an argument to started instrumentation. This delegate
allows the APK that runs the tests to access some privileged operations
protected by a signature level permissions which are explicitly granted
to the shell user.

The UiAutomation object also supports running tests in the legacy way
where the tests are run as a Java shell program. This enables existing
UiAutomator tests to keep working while the new ones should be implemented
using the new APIs. The UiAutomation object exposes lower level APIs which
allow simulation of arbitrary user interactions and writing complete UI test
cases. Clients, such as UiAutomator, are encouraged to implement higher-
level APIs which minimize development effort and can be used as a helper
library by the test developer.

The benefit of this change is decoupling UiAutomator from the system
since the former was calling hidden APIs which required that it is
bundled in the system image. This prevented UiAutomator from being
evolved separately from the system. Also UiAutomator was creating
additional API surface in the system image. Another benefit of the new
design is that now test cases have access to a context and can use
public platform APIs in addition to the UiAutomator ones. Further,
third-parties can develop their own higher level test APIs on top
of the lower level ones exposes by UiAutomation.

bug:8028258

Also this change adds the fully qualified resource name of the view's
id in the emitted AccessibilityNodeInfo if a special flag is set while
configuring the accessibility service. Also added is API for looking
up node infos by this id. The id resource name is relatively more stable
compared to the generaed id number which may change from one build to
another. This API facilitate reuing the already defined ids for UI
automation.

bug:7678973

Change-Id: I589ad14790320dec8a33095953926c2a2dd0228b
2013-01-22 17:56:53 -08:00
Dianne Hackborn
fd7adedebf Add new disabled state for "optional" built-in apps.
The disabled state allows you to make an app disabled
except for whatever parts of the system still want to
provide access to them and automatically enable them
if the user want to use it.

Currently the input method manager service is the only
part of the system that supports this, so you can put
an IME in this state and it will generally look disabled
but still be available in the IME list and once selected
switched to the enabled state.

Change-Id: I77f01c70610d82ce9070d4aabbadec8ae2cff2a3
2013-01-22 17:10:23 -08:00
Dianne Hackborn
d8e1dbb6bc Rework ParceledListSlice to be much easier to use.
Take advantage of this to return better information about
packages filtered by permissions -- include the permissions
they have in the requested array.

Also fix issue #8026793 (Contact picture shows default pic
while searching for a contact in qsb) by using the base
package name of the Context when reporting the app name
of an operation.  Otherwise you could make a resource-only
context for another application and do calls through that
and get reported as the wrong app.

Change-Id: I5e0488bf773acea5a3d22f245641828e1a106fb8
2013-01-18 13:02:26 -08:00
Dianne Hackborn
35654b61e8 More work on App Ops service.
Implemented reading and writing state to retain information
across boots, API to retrieve state from it, improved location
manager interaction to monitor both coarse and fine access
and only note operations when location data is being delivered
back to app (not when it is just registering to get the data at
some time in the future).

Also implement tracking of read/write ops on contacts and the
call log.  This involved tweaking the content provider protocol
to pass over the name of the calling package, and some
infrastructure in the ContentProvider transport to note incoming
calls with the app ops service.  The contacts provider and call
log provider turn this on for themselves.

This also implements some of the mechanics of being able to ignore
incoming provider calls...  all that is left are some new APIs for
the real content provider implementation to be involved with
providing the correct behavior for query() (return an empty
cursor with the right columns) and insert() (need to figure out
what URI to return).

Change-Id: I36ebbcd63dee58264a480f3d3786891ca7cbdb4c
2013-01-16 12:11:01 -08:00
Kenny Root
7b172a49a9 am 58ed5d74: am 768d9e1a: Merge "Correct executable bit for source files"
* commit '58ed5d748c0b9b64845975ef5844ad313de7c3f6':
  Correct executable bit for source files
2012-11-07 13:08:25 -08:00
Kenny Root
58ed5d748c am 768d9e1a: Merge "Correct executable bit for source files"
* commit '768d9e1a72ceee7d4a5f608776b87b62d6ce4a04':
  Correct executable bit for source files
2012-11-07 11:52:12 -08:00
Kenny Root
3a084af2e9 Correct executable bit for source files
Many media files and source code files were marked as executable in Git.
Remove those.

Also a shell script and python script were not marked as executable.

Change-Id: Ieb51bafb46c895a21d2e83696f5a901ba752b2c5
2012-11-07 10:27:31 -08:00
Marco Nelissen
a4256d1d7b Fix typo
Change-Id: I8c3797fb2d343ec6f25765fba49ac097e816d1cf
2012-11-01 13:55:28 -07:00
Mike Lockwood
c59b2f9a77 More changes to fix PDK build:
move screencap back to frameworks/base
move libdiskusage to frameworks/native

Change-Id: I8abe425c4bbf305bbe8650094c40c16df8c6d5e4
2012-10-24 12:31:10 -07:00
Mike Lockwood
e0e9e9462c Move app_process and system_server back to frameworks/base
due to dependency on libandroid_runtime

Change-Id: I96c0ba72ea406c9e7e63b9a160498187b6ec9b21
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-10-24 11:52:57 -07:00
Mike Lockwood
6931061de6 Move non-Java commands to frameworks/native
Change-Id: Id77c2cecb27cec500dfe066e4430f9e67802a433
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-10-24 10:43:42 -07:00
Dave Burke
aea7b6903b am da2f2e51: am 799916e6: Merge "Revert "Check non-primary user dirs during package scan"" into jb-mr1-dev
* commit 'da2f2e51c71b5ebc50fe76c3cd5a920c81a5ee92':
  Revert "Check non-primary user dirs during package scan"
2012-10-23 23:19:01 -07:00
Dave Burke
da2f2e51c7 am 799916e6: Merge "Revert "Check non-primary user dirs during package scan"" into jb-mr1-dev
* commit '799916e6ac706921e43a3382e5d9e06e13f87525':
  Revert "Check non-primary user dirs during package scan"
2012-10-23 23:17:23 -07:00
Dave Burke
799916e6ac Merge "Revert "Check non-primary user dirs during package scan"" into jb-mr1-dev 2012-10-23 23:14:15 -07:00
Dave Burke
383fa18b51 Revert "Check non-primary user dirs during package scan"
This reverts commit 4525f5b69cb44a9a0c92f9c525fc47541f456621

Change-Id: I31b7a0860972532478ab3420556b806bfa78739a
2012-10-23 23:12:19 -07:00
Kenny Root
5e24b92f04 am f461d3f6: am da2509c4: Merge "Check non-primary user dirs during package scan" into jb-mr1-dev
* commit 'f461d3f69f4533045167b4dc1f7445ad6ae47af3':
  Check non-primary user dirs during package scan
2012-10-23 17:10:24 -07:00
Kenny Root
f461d3f69f am da2509c4: Merge "Check non-primary user dirs during package scan" into jb-mr1-dev
* commit 'da2509c434ebb2a5a0da1bc270cae7f007cbb0f9':
  Check non-primary user dirs during package scan
2012-10-23 17:06:24 -07:00
Kenny Root
da2509c434 Merge "Check non-primary user dirs during package scan" into jb-mr1-dev 2012-10-23 17:03:09 -07:00
Kenny Root
4525f5b69c Check non-primary user dirs during package scan
During package scan, only the primary user data directories were
checked. If the secondary user didn't have an application directory, it
would happily ignore it. The app would then crash upon startup.

Bug: 7391882
Change-Id: I1fa92aa27386104d4ac6bc5dc92bfbf2e7dfac9f
2012-10-22 18:48:24 -07:00
Kenny Root
465fd635d5 am 3ce8eb4e: am 55708a9d: am e03c0244: Merge "Clear data deletes too much" into jb-mr1-dev
* commit '3ce8eb4eb24f90b8d850e3dc7c18569dd1fd361a':
  Clear data deletes too much
2012-10-22 16:19:52 -07:00
Kenny Root
3ce8eb4eb2 am 55708a9d: am e03c0244: Merge "Clear data deletes too much" into jb-mr1-dev
* commit '55708a9dce5be627f68e388d4ad355595ad5fef5':
  Clear data deletes too much
2012-10-22 16:17:17 -07:00
Kenny Root
55708a9dce am e03c0244: Merge "Clear data deletes too much" into jb-mr1-dev
* commit 'e03c0244717093e0fbc9b05073d3ae3dbd8fcea5':
  Clear data deletes too much
2012-10-22 16:14:14 -07:00
Kenny Root
9157d3f3b7 Clear data deletes too much
Bug: 7389445
Change-Id: Ic12d7a8e37747dc1a9b71ec5f881b5e440e0a75e
2012-10-22 15:20:52 -07:00
Kenny Root
a7fb9d907c am 9396f183: resolved conflicts for merge of a5d29b2c to jb-mr1-dev-plus-aosp
* commit '9396f183c2db5d6167f39a8d5667fb4abcc96e5e':
  Try to free cache before giving up on install
  Robustly add symlink and add for non-primary users
2012-10-19 17:20:03 -07:00
Kenny Root
9396f183c2 resolved conflicts for merge of a5d29b2c to jb-mr1-dev-plus-aosp
Change-Id: I21512d61b5c08cee5fed69b34c3275ba5c3fc0d8
2012-10-19 17:16:41 -07:00
Kenny Root
a5d29b2c14 am 9bef3294: Merge changes Ie3c8ca8d,Ia175b36d into jb-mr1-dev
* commit '9bef3294d3660a85442829a25c9777e25d3c3cc8':
  Try to free cache before giving up on install
  Robustly add symlink and add for non-primary users
2012-10-19 16:40:07 -07:00
Kenny Root
a3e90798b7 Robustly add symlink and add for non-primary users
Amazingly, some apps still don't use the nativeLibraryPath. So add a lib
symlink for non-primary users to fix that.

Also, there was an error when the symlink existed that it would give up.
This shouldn't really happen, but in that case, just remove it and
create a new one to be safe.

Also, move the downgrade code to the appropriate place. This downgrade
case triggered the above symlink existing bug.

Bug: 7318366
Bug: 7371571
Change-Id: Ia175b36d98f00bdc2f2433b909aafd524eb34d15
2012-10-18 15:12:09 -07:00
Kenny Root
ebf5569880 am 63a183c4: Merge "resolved conflicts for merge of 40f2f751 to jb-mr1-dev-plus-aosp" into jb-mr1-dev-plus-aosp
* commit '63a183c41f26e4eb475dfbcc4386b37372eb5fba':
  Fix mistaken removal of setfilecon
2012-10-17 10:53:51 -07:00
Kenny Root
367400491a resolved conflicts for merge of 40f2f751 to jb-mr1-dev-plus-aosp
Change-Id: I6075e2bf98b0f8310c93fac649c34cbbbd89707f
2012-10-17 10:50:14 -07:00
Kenny Root
115198ba1a am ed3ce513: Fix bad merge
* commit 'ed3ce513a64b9f26358dc77187d6d04fe91abae9':
  Fix bad merge
2012-10-17 10:10:27 -07:00
Kenny Root
ed3ce513a6 Fix bad merge
Change-Id: I9f05f96e3607b994368a8d4e1e454af8fe84424d
2012-10-17 10:06:17 -07:00
Kenny Root
21dc0aa5a4 am ad0090e7: resolved conflicts for merge of 85f9ba9e to jb-mr1-dev-plus-aosp
* commit 'ad0090e7b8c70cf44609aafbfea8c3946e2802a9':
  Remove HAVE_SELINUX guards
2012-10-17 10:05:58 -07:00
Kenny Root
ad0090e7b8 resolved conflicts for merge of 85f9ba9e to jb-mr1-dev-plus-aosp
Change-Id: I9ae49075935f0e9ec432ce9d828ee26a4fcdb44c
2012-10-17 10:02:22 -07:00
Kenny Root
57c63d8f9b Fix mistaken removal of setfilecon
Previous commit attempted to move setfilecon above chown, but mistakenly
squashed libdir and pkgdir setfilcon into one incorrect setfilecon.

Change-Id: I1ad00eae8a0e69ae88ce47cd5571558ce1ad2145
2012-10-17 09:50:37 -07:00
Kenny Root
c9a1aabc49 Remove HAVE_SELINUX guards
Change-Id: I6c2161471f657aa1645695ffd56ff434b0c2b426
2012-10-16 23:32:31 -07:00
Jeff Sharkey
0fa6bf683c am a1fda2e3: am 77ce60a5: am 7789c9bb: Merge "Support pm clear as --user." into jb-mr1-dev
* commit 'a1fda2e388603152d45ea5ef43b1c9b6d6935b6b':
  Support pm clear as --user.
2012-10-15 20:22:37 -07:00
Jeff Sharkey
a1fda2e388 am 77ce60a5: am 7789c9bb: Merge "Support pm clear as --user." into jb-mr1-dev
* commit '77ce60a59330d6059011d737142bd210db845d85':
  Support pm clear as --user.
2012-10-15 20:19:04 -07:00
Jeff Sharkey
77ce60a593 am 7789c9bb: Merge "Support pm clear as --user." into jb-mr1-dev
* commit '7789c9bbfca079655e9285173d6175b94bc774b0':
  Support pm clear as --user.
2012-10-15 18:29:51 -07:00
Jeff Sharkey
a3e9ff7deb Support pm clear as --user.
Bug: 7352703
Change-Id: I0e9cc4f2313e5424d234c3cb051004c0321d9dac
2012-10-15 16:16:39 -07:00
Jeff Sharkey
3b5259fcbe am 1e8f7262: am a00ffa53: am 1016b288: Merge "Pm command to get maximum users." into jb-mr1-dev
* commit '1e8f7262febf77580e830374af2f5c5236081a0f':
  Pm command to get maximum users.
2012-10-12 12:21:46 -07:00
Jeff Sharkey
1e8f7262fe am a00ffa53: am 1016b288: Merge "Pm command to get maximum users." into jb-mr1-dev
* commit 'a00ffa53fbe7ced0147451242232f47d117d5e2d':
  Pm command to get maximum users.
2012-10-12 12:19:34 -07:00
Jeff Sharkey
a00ffa53fb am 1016b288: Merge "Pm command to get maximum users." into jb-mr1-dev
* commit '1016b2881d2b5f5d5e142afa287bd876b6360c2b':
  Pm command to get maximum users.
2012-10-12 12:17:17 -07:00