Commit Graph

24813 Commits

Author SHA1 Message Date
Todd Kennedy
3e12f413d4 Merge "Implement 2-phase resolution" 2016-11-16 23:05:34 +00:00
Wale Ogunwale
782b247fdb Merge "Fixed issue with IME displaying on-top of nav bar." 2016-11-16 21:58:07 +00:00
Wale Ogunwale
93726a41a0 Merge "Don't include sysUI insets on secondary displays" 2016-11-16 21:56:55 +00:00
Wale Ogunwale
44fbdf5b1e Fixed issue with IME displaying on-top of nav bar.
Caused by some recent refactoring. We now make sure the IME
has the higher animation layer in its base layer of the window
it is targeting.
Also, consolidated some of our test functions.

Bug: 32916670
Test: bit FrameworksServicesTests:com.android.server.wm.WindowLayersControllerTests
Change-Id: I0b1abd6fead981cfc810488cc785261abba5341d
2016-11-16 20:38:50 +00:00
Chad Brubaker
c41c889b3e Merge "Use a 16 byte random suffix for installed apk directory name" 2016-11-16 18:38:21 +00:00
Fyodor Kupolov
de4355dd59 Merge "Log when priv permission is not whitelisted" 2016-11-16 18:24:55 +00:00
Fyodor Kupolov
b633f9d01f Log when priv permission is not whitelisted
Log violations for now, we will start enforcing it later.

Test: Manual - device boots
Bug: 32935038
Bug: 32935364
Change-Id: I1957c334f98852a5a87e093e24c72dd2c223c08b
2016-11-16 18:22:36 +00:00
Chad Brubaker
5e10e8f1b2 Use a 16 byte random suffix for installed apk directory name
This prevents apps (both normal and ephemeral) from learning what
applications are installed by checking for the existence of
/data/app/com.example.package-1. /data/app and /data/ephemeral-app are
already 771 and so cannot be ls'd but because the directory names are
guessable it is still possible to learn if known packages are installed.

Apps can still learn if a package is installed and where via the
standard APIs but not by directly using the filesystem. This is
important for ephemeral apps since normal apps should not be aware of
installed ephemeral apps (unless needed) and ephemeral apps shouldn't be
aware of other ephemeral apps.

Test: adb install --ephemeral, verify the code directory has random
suffix
Test: runtest -c android.content.pm.PackageManagerTests frameworks-core
Test: cts-tradefed run commandAndExit cts -m CtsAppSecurityTestCases
Change-Id: Id4883f5cfb9664307cf8518e2db3fef0e2d632d0
2016-11-16 09:50:17 -08:00
TreeHugger Robot
52f9473e57 Merge "Use StartFuseBridgeLoop function instead of FuseBridgeLoop class." 2016-11-16 05:30:09 +00:00
Andrii Kulian
db8e106fa3 Don't include sysUI insets on secondary displays
Currently there is a single instance of WindowManagerPolicy
used in Window Manager and it is configured according to
primary display settings. Because of that it reports display
size with navigation bar insets even for secondary displays.

This CL adds displayId param, so it can adjust reported metrics
correctly when requested.

Bug: 32910901
Test: android.display.cts.DisplayTest
Change-Id: I14967fc13907c4fde17aed6a769d03cbde3ec1be
2016-11-16 05:04:03 +00:00
longhai
1d687df2f7 Merge "Fixed the issue when some apps were gone and couldn't be installed successfully after updating from KK to M via OTA." am: 1813ae0159 am: 2be54fde72 am: 5c152a3d7f
am: d7e2ae5fc7

Change-Id: I9b24f761959dfe7a88509b65273e31916d9ddfc1
2016-11-16 03:28:17 +00:00
TreeHugger Robot
26c48fac73 Merge changes I99813278,I6285042b
* changes:
  Fix copypasta error.
  Aggressively clear cached data when forgetting.
2016-11-16 03:21:17 +00:00
longhai
d7e2ae5fc7 Merge "Fixed the issue when some apps were gone and couldn't be installed successfully after updating from KK to M via OTA." am: 1813ae0159 am: 2be54fde72
am: 5c152a3d7f

Change-Id: Ida06ea3d42d66cb2f1cc124fe3498e579141d16c
2016-11-16 03:18:08 +00:00
longhai
5c152a3d7f Merge "Fixed the issue when some apps were gone and couldn't be installed successfully after updating from KK to M via OTA." am: 1813ae0159
am: 2be54fde72

Change-Id: I14e1d5aa6bda143e2a87bba1ea65b8384c44e3a1
2016-11-16 03:11:09 +00:00
longhai
2be54fde72 Merge "Fixed the issue when some apps were gone and couldn't be installed successfully after updating from KK to M via OTA."
am: 1813ae0159

Change-Id: Iae1a0cd25495206d596aed7d68ce7936071f9c6e
2016-11-16 03:04:38 +00:00
Treehugger Robot
1813ae0159 Merge "Fixed the issue when some apps were gone and couldn't be installed successfully after updating from KK to M via OTA." 2016-11-16 02:54:26 +00:00
Daichi Hirono
976e63bdd3 Use StartFuseBridgeLoop function instead of FuseBridgeLoop class.
The method is being renamed from FuseBridgeLoop::Start to StartFuseBridgeLoop
in libappfuse. The CL handles the change in the framework side.

Bug: 29970149
Test: None
Change-Id: I70b91e426fa817d84c7f1f5f24c9e3ba401e523b
2016-11-16 10:12:37 +09:00
Jorim Jaggi
3c9006d842 Merge "Fix that window was not hidden after policy hiding animation" 2016-11-16 00:40:53 +00:00
Svetoslav Ganov
63ff0d822b Merge "Temporary enable Build#SERIAL" 2016-11-16 00:33:16 +00:00
Svet Ganov
b5e603f270 Temporary enable Build#SERIAL
Filed STOPSHIP b/32918547

bug:31803186

Change-Id: I66b26e5948d19391513e007daad099f51cb64155
2016-11-15 16:29:38 -08:00
Jorim Jaggi
af221d16de Fix that window was not hidden after policy hiding animation
When we removed WindowState.isOnScreenIgnoringKeyguard we forgot
to change WindowState.isOnScreen to also check policy visibility.

Test: runtest frameworks-services -c com.android.server.wm.WindowStateTests
Test: Open camera app, make sure status bar is hidden

Change-Id: I780f50c8ed3e675f2fab623fdba4fcfc5b6f1d5b
Fixes: 32890266
2016-11-15 14:59:57 -08:00
Jeff Sharkey
b501ef1e21 Aggressively clear cached data when forgetting.
Otherwise the system server risks keeping open FDs to an adopted
storage device that could later be ejected.

Test: builds
Bug: 31596654
Change-Id: I6285042b4f0714dbf601c7dfa53efb704ea29d0b
2016-11-15 14:39:19 -07:00
Sudheer Shanka
2250d56a0b Rename MountService to StorageManagerService.
Bug: 30977067
Test: Existing tests pass
Change-Id: Ieac0f11c2b249dcd60441b14c1f391e6f8131d42
2016-11-15 12:43:37 -08:00
Fyodor Kupolov
3bfef01864 Merge "Control privileged permissions for priv-apps" 2016-11-15 19:29:14 +00:00
Andrii Kulian
03c403d273 Fix minor issues discovered with Multi-Display tests
- NPE when launching activity on secondary display
and there is a docked stack on primary.
- Activities not finished correctly on secondary display
when it is removed.

Change-Id: If527211e8192088790d32b9673b960535e27033f
Test: See ActivityManagerDisplayTests.
2016-11-15 18:29:25 +00:00
Andrii Kulian
53ad29fe53 Merge "Add API to launch activities on secondary displays" 2016-11-15 18:27:39 +00:00
Andrii Kulian
16802aab21 Add API to launch activities on secondary displays
displayId can be specified as a part of ActivityOptions.
We will look for a valid stack on the specified display, starting
from the topmost one. If no valid stack is found, new dynamic stack
can be created on external display.
Launch stack and display id can't be set at the same time, otherwise
exception will be thrown.

Test: ActivityManagerDisplayTests
Test: #testLaunchActivityOnSecondaryDisplay
Test: #testConsequentLaunchActivity
Test: #testConsequentLaunchActivityFromSecondaryDisplay
Test: #testLaunchActivityFromAppToSecondaryDisplay
Change-Id: I8a202bc076319e23948d81b99a2c68d7b733b5e4
2016-11-15 17:18:32 +00:00
Gustav Sennton
ebd8b62cfe Merge "Dump the entire state of WebViewUpdateService on demand." 2016-11-15 12:54:01 +00:00
Fyodor Kupolov
964d2ebb94 Control privileged permissions for priv-apps
Added support for privapp-permissions config element. It allows to explicitly
control what privileged permissions applications should be granted.

Feature is controlled by ro.control_privapp_permissions property.
Possible values:
- 0/false, the feature is completely disabled - signature|privileged
  permissions are granted automatically without logging. *Default behavior*
- 1/true, enforce that only whitelisted permissions are granted. Only
  devices with ro.control_privapp_permission=1 will pass CTS tests.

Test: Manual
Bug:31008485
Change-Id: I93a8c2782cc72b3953f32c237086d08d82ac0d5b
2016-11-14 18:06:15 -08:00
Wale Ogunwale
7c73dd6a20 Merge "Removed WallpaperController dependency on WindowList." 2016-11-15 01:19:41 +00:00
Todd Kennedy
01ad0c7e40 Implement 2-phase resolution
Bug: 25119046
Test: build & install the sample resolver and run 'adb shell am start -a android.intent.action.VIEW -c android.intent.category.BROWSABLE -d "https://www.tripadvisor.com/Tourism-g33020-San_Jose_California-Vacations.html"'
Change-Id: I624b9028061aad35db80e0d51bfe0a39fb81806c
2016-11-14 15:05:21 -08:00
Gustav Sennton
1eb3820d7e Dump the entire state of WebViewUpdateService on demand.
It is especially useful to know which is the current WebView package but
we also add some other state to be able to debug WebViewUpdateService.

Bug: 32307028
Test: Run 'adb shell dumpsys webviewupdate' and inspect printed
contents.
Test: Take bug report and inspect the 'webviewupdate' dump section.
Change-Id: I79c2cda87ea7633a915eae5de3c3015b18ed6d7c
2016-11-14 20:50:19 +00:00
Sudheer Shanka
dc589ac82b Update usage of ActivityManagerNative.
- Remove references to ActivityManagerProxy.
- Add isSystemReady to ActivityManager.

Bug: 30977067
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test android.server.cts
      adb shell am instrument -e class com.android.server.am.ActivityManagerTest,com.android.server.am.TaskStackChangedListenerTest \
          -w com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner
Change-Id: I07390b6124fb1515821f5c0b37baf6ae74adc8fa
2016-11-14 11:27:12 -08:00
Wale Ogunwale
f4ebe2e2cc Removed WallpaperController dependency on WindowList.
WallpaperController now accesses the container hierarchy directly
to determine the state of the wallpaper windows and targets.

Bug: 30060889
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test \
      android.server.cts.ActivityManagerTransitionSelectionTests

Change-Id: Ib70beaf340f257ad4e1093cc127f81e7adf41636
2016-11-14 11:03:52 -08:00
TreeHugger Robot
18fe8f6359 Merge "Added a callback for AutoFillService." 2016-11-14 17:56:59 +00:00
Wale Ogunwale
059de0230b Merge "Removed used of DisplayContent.getReadOnlyWindowList()" 2016-11-13 01:01:11 +00:00
TreeHugger Robot
357c6e5e5b Merge "Fixing issue where PIP did not stay minimized after rotation." 2016-11-12 04:59:13 +00:00
Winson Chung
d5a01599f7 Fixing issue where PIP did not stay minimized after rotation.
- Ensure that we reapply the minimized offset after applying the snap
  fraction to the rotated bounds
- Fixing small issue where we weren't bottom aligning the PIP when the
  visible IME changes size (but is not made invisible)
- Also fixing an issue where the touch gesture continually allowed
  swiping offscreen even after dragging the PIP a distance. Now, if no
  gesture handles the drag, then the default gesture will disallow
  offscreen dragging once it handles the move.
- Shrinking PIP slightly to fit proportions of screen.

Test: Enable minimization in SysUI tuner, put PIP into minimized state,
      rotate the screen.  This is not final UX and the CTS tests will
      be updated to reflect this behavior once it is final.

Change-Id: I15c851a0bcf5f867289bc5ad50d298f82a103308
2016-11-11 16:25:04 -08:00
Marie Janssen
989c408137 Merge "Bluetooth: BLE app tracking fixes" am: 2174731449 am: 3d8d5dbb56 am: 56853771ae
am: ddede667fb

Change-Id: I82db19aad214fee9aeec8a56e6e1efd13630a616
2016-11-12 00:17:47 +00:00
Marie Janssen
ddede667fb Merge "Bluetooth: BLE app tracking fixes" am: 2174731449 am: 3d8d5dbb56
am: 56853771ae

Change-Id: I2c0ac6fd2047643ae3c1e6450397b2cd9eed7e94
2016-11-12 00:05:19 +00:00
Felipe Leme
29a5b0d0f1 Added a callback for AutoFillService.
So far AutoFillService only received the assist data from framework; in
this CL, it also offers a method where the auto-fill provider can send
the auto-fill data back to framework.

The workflow is:

- AFMSI calls a new AM method (requestAutoFillData(), instead
  of requestAssistContextExtras()).
- The assist receiver is located in the app, not on system service.
- AM uses a new request type (ASSIST_CONTEXT_AUTOFILL) to request the
  assist data to the activity.
- ViewStructure has a new setAutoFillId() method which is used to set an
  unique id for the view.
- View uses the accessibility id to implement the auto-fill id.
- When the activity fullfills the request, it creates an IAutoFillCallback
  remote object - that will be used to set the auto-fill fields - and
  returns it in the assist bundle (using the
  VoiceInteractionSession.KEY_AUTO_FILL_CALLBACK key).
- The app-visible AutoFillService class offers an onFillRequest() method,
  which contains the assist data and a FillCallback used to handle it.

BUG: 31001899
Test: manually built and ran it

Change-Id: I3d208c14e81022dc96dd03f38bbe25a778b24a67
2016-11-11 16:02:55 -08:00
Marie Janssen
56853771ae Merge "Bluetooth: BLE app tracking fixes" am: 2174731449
am: 3d8d5dbb56

Change-Id: Ia9b8950f66f31b0d3b78f6e2f6c2314cf0b931f0
2016-11-11 23:53:47 +00:00
Marie Janssen
3d8d5dbb56 Merge "Bluetooth: BLE app tracking fixes"
am: 2174731449

Change-Id: Id07abb3d5ad76b318d1b7cee6d9fb9351737b141
2016-11-11 23:41:42 +00:00
TreeHugger Robot
4d5f44f619 Merge "Ensure consistent stack behind PIP when going to/from fullscreen." 2016-11-11 23:20:38 +00:00
Marie Janssen
2977c3e372 Bluetooth: BLE app tracking fixes
Simplify tracking registered BLE Apps and clear the state when we
try to recover bluetooth from starting to ON.

Test: enable and disable bluetooth an LE-only app running
Bug: 32609235
Change-Id: I3233bf8402a3c8fc4886ef21b1e9411bc78d4e2c
2016-11-11 21:30:33 +00:00
TreeHugger Robot
3a7c696fc5 Merge "Make getter & setting names consistent." 2016-11-11 20:19:49 +00:00
Winson Chung
0c1ca09dbb Ensure consistent stack behind PIP when going to/from fullscreen.
- When a fullscreen activity enters PIP, we were previously always
  bringing the home stack forward due to the return type being set
  to HOME_ACTIVITY_TYPE, causing the home screen to be visible if
  expanding PIP over a fullscreen activity and going back into PIP
  immediately.  This CL instead updates the return-to type to
  reflect the stack that was currently open before the pinned task
  was made fullscreen again to ensure that it is consistent when
  entering PIP again.

Test: android.server.cts.ActivityManagerPinnedStackTests
Test: #testPipUnPipOverHome
Test: #testPipUnPipOverApp

Change-Id: Id5dd7db1f5a8040ff21190cc347eb6aae5893006
2016-11-11 19:47:32 +00:00
Julia Reynolds
3785605a44 Make getter & setting names consistent.
Test: runtest systemui-notification
Change-Id: Iff746f0ae149d1b09792e240503db9d008fe267c
2016-11-11 09:36:52 -05:00
Jason Monk
97a06a12ed Add switchable theme to tuner
Allows option in tuner to switch between system theme overlays
if multiple exist. Requires a restart to take effect.

Test: Settings -> Tuner -> Other -> Theme
Change-Id: Iea43b9cbb67fd91c6008be594ad4cfd19c3f57ec
2016-11-11 09:01:20 -05:00
Yohei Yukawa
e9b99f8260 Merge changes I7918c0a3,I19d87fc1
* changes:
  Support content URIs w/ userId in IC#commitContent
  Fix up content URI for different users
2016-11-11 03:40:32 +00:00