Commit Graph

64653 Commits

Author SHA1 Message Date
TreeHugger Robot
37c20a369c Merge "Iteration on findPath API. Address Jeff's comment in ag/1542773." 2016-10-29 01:36:16 +00:00
Dianne Hackborn
d409b78728 Merge "Power manager now prevents wake locks from idle uids." 2016-10-28 23:53:34 +00:00
TreeHugger Robot
27e9c97803 Merge "Add FragmentLifecycleCallbacks" 2016-10-28 23:53:21 +00:00
Garfield Tan
5f2148077a Iteration on findPath API. Address Jeff's comment in ag/1542773.
* Add @Nullable to rootId in Path constructor.
* Erase rootId if findPath() doesn't return null rootId.
* Use Log.wtf() instead of throwing.

Bug: 30948740
Change-Id: I38354c5ac49aaa7e31a3ae56cd3379ffb19918c9
(Cherry picked from commit 04fdf6e18c97c2bf6ed58f8de9ba6723fa8c1613)
2016-10-28 23:49:35 +00:00
Adam Powell
38c67ff93b Add FragmentLifecycleCallbacks
Add a new callback object that can be attached to a FragmentManager to
observe all fragment lifecycle events within that
FragmentManager. Useful for dependency injection and other
shenanigans.

FragmentLifecycleCallbacks can be registered as recursive, in which
case they will be activated for any lifecycle events that happen in
descendant FragmentManagers as well.

Test: cts-tradefed run singleCommand cts --skip-preconditions --skip-device-info --module CtsFragmentTestCases
Change-Id: I816b1fbef6c29616ccc3fd729ee847c5f1a6f72f
2016-10-28 14:59:54 -07:00
John Reck
1952e2dc9b Merge "Add SurfaceHolder#lockHardwareCanvas()" 2016-10-28 19:38:45 +00:00
Dianne Hackborn
d33c7cd87a Power manager now prevents wake locks from idle uids.
The activity manager now pushes the idle/active state
down in to the power manager.  The power manager now
tracks a structure of data about each uid: how many
wake locks it holds, whether it is active, and (as before)
its current process state.

Now when apps are inactive, we always disable wake locks
they hold, regardless of the system's device idle or
other state.

Test: none

Change-Id: I2cd4077e4d8a8572525406ae9747f0a2435764da
2016-10-28 11:20:19 -07:00
Jakub Pawlowski
d649849928 Merge "Separate LE scanner from GATT client (1/4)" am: 87c997ca21 am: 81d5ecb7a6 am: 61d0088923
am: e582ab854d

Change-Id: Ibbf57cfccad50ae5d7dd9f80a13f08c5cfd1623e
2016-10-28 03:24:38 +00:00
Jakub Pawlowski
e582ab854d Merge "Separate LE scanner from GATT client (1/4)" am: 87c997ca21 am: 81d5ecb7a6
am: 61d0088923

Change-Id: I83c82b17064ee958fff6a98d90a0b351205ccf54
2016-10-28 03:01:56 +00:00
Jakub Pawlowski
61d0088923 Merge "Separate LE scanner from GATT client (1/4)" am: 87c997ca21
am: 81d5ecb7a6

Change-Id: If7688706be45e72e3ab98a35d3712ddae9d508a6
2016-10-28 02:56:54 +00:00
Jakub Pawlowski
81d5ecb7a6 Merge "Separate LE scanner from GATT client (1/4)"
am: 87c997ca21

Change-Id: I8fdf97a457d7566b4e0048624d47a6cfea693f13
2016-10-28 02:50:54 +00:00
TreeHugger Robot
42875e6cf6 Merge "Perform onDestroy when FragmentController is torn down." 2016-10-28 00:52:32 +00:00
TreeHugger Robot
9212fc742f Merge "Correctly use ByteBuffer in UsbRequest" 2016-10-27 23:47:32 +00:00
Jakub Pawlowski
1b49e6eb04 Separate LE scanner from GATT client (1/4)
Right now, LE scanning functionality is combined with the GATT client.
This is the source of various bugs, like scans suddenly stoppinging when
a GATT client is killed. It also increases memory consumption, because
we associate many structures with a GATT client, which are not necessary
when just scanning.

Test: sl4a BleScanApiTest ConcurrentBleScanTest
Change-Id: I0c25bd4a58bb430eb0ee4100d5f2bbab194f9621
2016-10-27 23:09:35 +00:00
Svetoslav Ganov
f9e2ad0b3c Add Bluetooth toggle prompts - framework
If permission review is enabled toggling bluetoth on or off
results in a user prompt to collect consent. This applies
only to legacy apps, i.e. ones that don't support runtime
permissions as they target SDK 22.

Also added a configuration resource which controls whether
permission review mode is enabled. By default it is not and
an OEM can change this via an overlay. For now we also keep
the old mechanism to toggle review mode via a build property
which is still used and will be removed when clients have
transitioned.

bug:28715749

Change-Id: I94c5828ad6c8aa6b363622a26ff9da4fc2e2fac7
(cherry picked from commit ac69be543f)
2016-10-27 22:49:11 +00:00
Sudheer Shanka
428868c1f0 Merge "Move IMountService to aidl." 2016-10-27 22:38:34 +00:00
George Mount
851179dbec Perform onDestroy when FragmentController is torn down.
Bug 32457575

Test: I9e33801c34bcb31e3d6ca0df3962cfe1a3203044
Change-Id: Id220dbfb3e42d2c91b99926c1e9b0c556c9b453a
2016-10-27 14:24:58 -07:00
John Reck
6bc7014210 Add SurfaceHolder#lockHardwareCanvas()
Bug: 26988043
Test: SurfaceViewTests#testSurfaceHolderHardwareCanvas CTS test
Change-Id: I3e5352d498dbe2fc56a18ca27360d129a14c7784
2016-10-27 14:13:44 -07:00
Sudheer Shanka
f734114280 Move IMountService to aidl.
Bug: 30977067
Test: Existing tests passing.
Change-Id: Icadfdcbc79708d3826b4e11afe35f5963aabcd4c
2016-10-27 12:36:37 -07:00
TreeHugger Robot
4452e751d4 Merge "Dumps total size of primary storage." 2016-10-27 19:09:26 +00:00
Fyodor Kupolov
08c75e4c49 Merge "Use app context to avoid memory leaks" 2016-10-27 18:21:49 +00:00
TreeHugger Robot
09c7a38755 Merge "Fix hide fragment transition" 2016-10-27 17:55:03 +00:00
Philip P. Moltmann
08b678c029 Correctly use ByteBuffer in UsbRequest
Meaning: Read/Write to correct area in buffer, set position correectly.

- Create a new method UsbRequest#enqueue that has correct behavior, deprecate
  UsbRequest#queue.
- Move all description of the weird (legacy) UsbRequest#queue behavior to
  this method.

Change-Id: Ibeed400b4ad2aa9d005ace345c7895a3dc4ba1ad
Fixes: 31050148
Test: Submitted alongside
2016-10-27 10:25:40 -07:00
Sunny Goyal
584264f6af Merge "Adding support for async view loading in RemoteViewsAdapter" 2016-10-27 17:14:47 +00:00
Leonard Mosescu
1ab879be90 Adding "attach-agent" to ActivityManagerShellCommand
This new command is used to attach runtime agents to a running application:

attach-agent <PROCESS> <FILE>
   Attach an agent to the specified <PROCESS>,
   which may be either a process name or a PID.

Test: m test-art-host, manual testing:
    . invalid syntax, missing arguments
    . invalid syntax, extra arguments
    . invalid numeric PID
    . invalid process name
    . valid process, not debuggable
    . valid process, missing agent
    . valid process, valid agent

Bug: 31682382

Change-Id: Ife88dbf23991dde7945d9208e54cd014bb7ecdc6

Merged-In: Ife88dbf23991dde7945d9208e54cd014bb7ecdc6
2016-10-27 17:03:57 +00:00
Philip P. Moltmann
411f8215fc Merge "Add UsbDeviceConnection.requestWait with a timeout" 2016-10-27 16:15:15 +00:00
George Mount
4fe4711760 Fix hide fragment transition
Bug 30699392

During optimized hide operations with fragment transitions, the
hidden fragment View should not be GONE, but instead be visible
and the exiting views should be made INVISIBLE. After the
transition completes, the fragment's view should be GONE.

Test: I189fb22883637888516fb04940dbb288cb9a49d2
Change-Id: I3a80fdaa198ed04916df02b1d2ca069e6992f88f
2016-10-27 09:08:55 -07:00
Andrii Kulian
debcf7603f Merge "Refactor stack removal methods" 2016-10-27 07:52:07 +00:00
TreeHugger Robot
ed9ee58170 Merge "resolve merge conflicts of 1238daf to master" 2016-10-27 02:50:25 +00:00
Marie Janssen
1e012d93c7 resolve merge conflicts of 1238daf to master
Change-Id: Icc70d291379d4f4816881e46704197513e6d548e
2016-10-26 17:57:22 -07:00
Tomasz Mikolajewski
1815241e78 Merge "Remove no longer used FLAG_ARCHIVE." 2016-10-27 00:56:31 +00:00
Marie Janssen
1238daf20d Bluetooth: prevent enabling BLE in airplane mode am: a80d745c65 am: 6affbde556
am: 73bfd25356

Change-Id: Ieb424a2d68058d4171e6c9bd04f8a42cc1f3d7e9
2016-10-27 00:29:51 +00:00
Marie Janssen
6affbde556 Bluetooth: prevent enabling BLE in airplane mode
am: a80d745c65

Change-Id: I05a57fa747abedab24e0509c1fb7ab8737b2256a
2016-10-27 00:20:17 +00:00
Andrii Kulian
6d6fb401c7 Refactor stack removal methods
Refactor some parts of stack removal to make methods implementations
correspond to their names.

Change-Id: Ie686c463d67232d9d5fd96468fe3911003d22471
Test: Manual and existing tests still pass.
2016-10-26 16:22:31 -07:00
Marie Janssen
a80d745c65 Bluetooth: prevent enabling BLE in airplane mode
Enabling BLE in airplane mode puts BluetoothManagerService in an
unexpected state which causes Bluetooth to be on when airplane mode
is disabled.

Also fixes a bug where a crash of a BLE client would trigger a restart
into ON mode.

Test: SL4A BleBackgroundScanTest:test_airplane_mode_disables_ble

Bug: 32140251
Bug: 32140271
Bug: 32369494

Change-Id: Ie65157e65c3a1ca914f567a7a0c631175d1e5835
(cherry picked from commit bd93b7b3dc6141cef6236cf0ca7dcc5acf5bfeed)
2016-10-26 14:55:47 -07:00
TreeHugger Robot
199e3683d1 Merge changes I2d9f1a2d,I01fd8ba6
* changes:
  Ensure PIP retains bounds on device rotation.
  Fix wrong bounds being used in landscape.
2016-10-26 21:48:09 +00:00
TreeHugger Robot
a917d708e9 Merge "Fix bug in which some Views were not executing enter transition." 2016-10-26 20:07:47 +00:00
Winson Chung
303c6b78b6 Fix wrong bounds being used in landscape.
- Ensure we use the right display size when calculating PIP bounds.
- Also update interface to take the display id.

Test: android.server.cts.ActivityManagerPinnedStackTests
Test: #testPinnedStackDefaultBounds
Test: #testPinnedStackMovementBounds

Change-Id: I01fd8ba6dee212c29a9a092673ee8f7843e41af6
2016-10-26 12:49:40 -07:00
TreeHugger Robot
89aa8b9266 Merge "Import android.hardware.thermal@1.0 constants into HardwarePropertiesManager." 2016-10-26 19:40:42 +00:00
Philip P. Moltmann
927fefe813 Add UsbDeviceConnection.requestWait with a timeout
Test: Test is submitted alongside this change
Change-Id: I1c46143030a2822ee76676ddc80d3b5c8c62ee80
Fixes: 31288102
2016-10-26 10:21:21 -07:00
Andreas Huber
cbd1bb9532 Merge "Adds support for specifying the version of a service to register/lookup." am: c3d8550cf3 am: 8bd63a39f3 am: 63f0ebc7a8
am: 525489b087

Change-Id: I00eb3f6e26fbb01592d09d581488a903f17a4fa4
2016-10-26 16:03:29 +00:00
Andreas Huber
63f0ebc7a8 Merge "Adds support for specifying the version of a service to register/lookup." am: c3d8550cf3
am: 8bd63a39f3

Change-Id: I00c3d6441f15011a6ddbb281169bfcac71aff062
2016-10-26 15:54:20 +00:00
Andreas Huber
8bd63a39f3 Merge "Adds support for specifying the version of a service to register/lookup."
am: c3d8550cf3

Change-Id: I6b12021c6100f33de7f4b4702bdb4bf1a48c0259
2016-10-26 15:49:52 +00:00
Andreas Huber
c3d8550cf3 Merge "Adds support for specifying the version of a service to register/lookup." 2016-10-26 15:38:45 +00:00
Romain Guy
1de993c768 Merge "Add a half-precision floating point type" 2016-10-25 23:41:57 +00:00
Leonard Mosescu
f3409ceee5 Adding "attach-agent" to ActivityManagerShellCommand
This new command is used to attach runtime agents to a running application:

attach-agent <PROCESS> <FILE>
   Attach an agent to the specified <PROCESS>,
   which may be either a process name or a PID.

Test: m test-art-host, manual testing:
    . invalid syntax, missing arguments
    . invalid syntax, extra arguments
    . invalid numeric PID
    . invalid process name
    . valid process, not debuggable
    . valid process, missing agent
    . valid process, valid agent

Bug: 31682382

Change-Id: Ife88dbf23991dde7945d9208e54cd014bb7ecdc6
2016-10-25 22:42:39 +00:00
Dianne Hackborn
fe51103711 Merge "Tweak ActivityManager.getPackageImportance()" 2016-10-25 22:41:00 +00:00
Jakub Pawlowski
bd7c33967c Merge "Add helper method to convert Bluetooth UUID to bytes" am: 8a0a58b218 am: f169ecb76f am: f68a0c6dec
am: 94aaa0a705

Change-Id: I6cbff5dba97d53763861b60c015cf6ff349eaa23
2016-10-25 22:02:54 +00:00
TreeHugger Robot
f2ec2c1e42 Merge "Apply display override config for secondary displays" 2016-10-25 22:00:57 +00:00
Jakub Pawlowski
f68a0c6dec Merge "Add helper method to convert Bluetooth UUID to bytes" am: 8a0a58b218
am: f169ecb76f

Change-Id: I035eb25c9a320b1760221bc5928919a148801488
2016-10-25 21:54:44 +00:00