Commit Graph

6370 Commits

Author SHA1 Message Date
Adrian Roos
59116440e7 Separate ambient display triggers
am: b7e4e10618

Change-Id: I575f96338cffa0f6e8adb1b9ff300dbd322398dc
2016-10-18 22:07:03 +00:00
Adrian Roos
b7e4e10618 Separate ambient display triggers
Allows configuring notification and sensor triggers
separately. Introduces a helper class that hosts the
logic for determining what kinds of triggers a device
supports.

Bug: 32073185
Change-Id: Ie7e8eb6b895dcc54e6f972e70642c7248b9e223a
Test: disable "ambient display", sensor triggers should still work
2016-10-18 10:43:44 -07:00
Yohei Yukawa
f8621ff5bf Handle exceptions from #requestPermission()
am: 93278ca144

Change-Id: I5e8a3a9a670b1e794ce3af670fb30ffc4b8302a5
2016-10-15 00:37:24 +00:00
Yohei Yukawa
93278ca144 Handle exceptions from #requestPermission()
This is a follow up CL to my previous CL [1] that let
IInputConnectionWrapper to call InputContentInfo#requestPermission()
automatically so that temporary URI permissions can be granted
automatically on API 25+ devices whenever
INPUT_CONTENT_GRANT_READ_URI_PERMISSION is specified.

However, in that CL we forgot to handle exceptions thrown from
InputContentInfo#requestPermission().  This is problematic because it is
actually easy for IMEs to cause SecurityException by specifying a
content URI that does not allow grantUriPermission, e.g.:

  inputConnection.commitContent(
          new InputContentInfo(Uri.parse("content://call_log/test"),
          new ClipDescription("test", new String[]{"image/gif"}));

As a result, IMEs can let the application crash at any time because
InputContentInfo#requestPermission() is automatically called inside the
Framework.

This CL makes sure that exceptions thrown from
InputContentInfo#requestPermission() can be handled gracefully.

 [1]: Id955435dd2e72549ee7134f46b3c6951581694ad
      f3806f57a5

Bug: 32162481
Change-Id: I08916a1f54518390d3b67ab1673dc901e3f9716a
2016-10-14 22:26:35 +00:00
Nancy Zheng
1e746a415d Merge "Fix race condition in checkPattern and verifyPattern." into cw-f-dev 2016-10-07 17:47:47 +00:00
Nancy Zheng
9475460e66 Fix race condition in checkPattern and verifyPattern.
Bug: 31939282
Change-Id: I3250ab900f190ca9c820ac355ce94a699315b137
2016-10-07 10:41:00 -07:00
Dianne Hackborn
50b9f3513c Fix issue #31305336: File corrupt: too many wake locks 101
am: cb99a72e62

Change-Id: I01062999e2a1207c5d1bc826e8c9372c0fb012f7
2016-10-06 20:58:54 +00:00
Dianne Hackborn
cb99a72e62 Fix issue #31305336: File corrupt: too many wake locks 101
The limit is MAX_WAKELOCKS_PER_UID+1, since OverflowArrayMap
will add one more to contain the overflow.

Change-Id: I53004582daa0c405427308816728f2c1d2bef40d
2016-10-03 17:00:02 -07:00
Jorim Jaggi
0ea9093df7 Fix crash if drawable doesn't have constant state
am: 92d0602a7c

Change-Id: I8ab088ad588eac8baa674d551201713562d973ef
2016-09-30 09:10:11 +00:00
Jorim Jaggi
92d0602a7c Fix crash if drawable doesn't have constant state
Change-Id: I2364efb9dc1446bc1a8c50abf6bd34a73c226f7e
Fixes: 31755893
2016-09-29 14:37:14 +00:00
Hidenari Koshimae
ab8a42f7d9 Increase priority for broadcast intent triggered by HW key
am: 469e65e37f

Change-Id: I7b2aec06b7d2d0375b2f680e7880ca401684cddd
2016-09-26 19:33:25 +00:00
Hidenari Koshimae
469e65e37f Increase priority for broadcast intent triggered by HW key
Add the FLAG_RECEIVER_FOREGROUND flag to the broadcast intent
triggered by hardware key.
This prevents the framework from delaying the delivery of the
intent to its recipients, and improves the response for hardware
key event under heavy load on the system.

Bug: 28735973
Change-Id: Ib7f219845be34794f4c7545927e53cc6c2b504a3
2016-09-26 18:29:06 +01:00
dongwan0605.kim
4d590a91c2 Fix RTL issue of ImageFloatingTextView
am: dd8611fc5a

Change-Id: I101527b922604640fef684c6216b99289ac97f25
2016-09-23 22:04:42 +00:00
Selim Cinek
0e1f78da65 Added Emergency affordance feature
am: 705442fa7d

Change-Id: I03ebb84119f9cb310882ba9ea90ee1e1d7118d03
2016-09-23 22:00:42 +00:00
Selim Cinek
7f53b9bcb5 Merge changes If9baf6db,Idc6c5d7d into nyc-mr1-dev
* changes:
  Fix DismissView cannot be clicked sometimes after boot
  Fix RTL issue of ImageFloatingTextView
2016-09-23 21:52:13 +00:00
Selim Cinek
a05719a278 Merge changes If7c3a55e,I68dcba41,Ib96a15da into nyc-mr1-dev
* changes:
  Fixed a bug where the dimmed background could be invisible
  Fixed an issue where the inline controls where not usable
  Added Emergency affordance feature
2016-09-23 21:51:22 +00:00
Adam Powell
e698d8bfea ResolverComparator transitivity
am: 2366ff12a2

Change-Id: I8de9805eab7617a952579ff0c82616c0923e5513
2016-09-23 20:39:49 +00:00
dongwan0605.kim
dd8611fc5a Fix RTL issue of ImageFloatingTextView
Sometimes, makeSingleLayout() can be invoked before layout direction is resolved.
When not resolved, it indents in LTR layout although it should be RTL.

So, to guarantee the exact indenting, we should re-build the text layout
when the layout direction is changed.

Test: manual - Test BigTextStyle notifications with LargeIcon under RTL configurations.
Fixes: 31633875
Change-Id: Idc6c5d7d41632cb9e1b70d9c67c13852e3f25023
2016-09-23 13:07:22 -07:00
Adam Powell
2366ff12a2 ResolverComparator transitivity
Fix a bug where ResolverComparator's results were not consistent for
targets that cross profile boundaries.

Bug: 31640894
Change-Id: Ic6bf9512d2c2eb6f8fb7851e18eb9a347db29755
2016-09-23 10:36:01 -07:00
Selim Cinek
705442fa7d Added Emergency affordance feature
Added a service that listens whether emergency affordances
are necessary.

If the they are needed, it adds an option to the
global actions dialog that directly launches the
emergency call and also adds a long-press listener
to the keyguard emergency button.

Test: adb shell settings put global force_emergency_affordance 1 && adb shell settings put global emergency_affordance_number 111112
Fixes: 30404490
Change-Id: Ib96a15da2ef4b568a8d77140ebca6aa6f20f5ddb
2016-09-22 12:25:57 -07:00
TreeHugger Robot
81b4314540 Merge "Limit translation of bottom panel snapping to not overshoot." into cw-f-dev 2016-09-15 22:23:19 +00:00
Michael Kwan
b1440bdb17 Limit translation of bottom panel snapping to not overshoot.
Bug: 31444693
Change-Id: I84ff0d90eb67c6672dbf81985057bdf844c50cee
2016-09-12 22:48:34 -07:00
Erik Kline
3a28cf3f09 Have WakeupMessage call Handler#dispatchMessage()
am: a457ebbda6

Change-Id: I57ef0f980e4b63735affee6127fffe454e44756f
2016-09-13 03:33:39 +00:00
TreeHugger Robot
46de5f4917 Merge "Have WakeupMessage call Handler#dispatchMessage()" into nyc-mr1-dev 2016-09-13 03:25:39 +00:00
Svet Ganov
0dc4ff0753 [DO NOT MERGE] Backup account access grants
am: 72ed12c55f

Change-Id: I80029a2db1cbddc22ae545879fd757446610e154
2016-09-10 00:20:52 +00:00
TreeHugger Robot
ae9fa16bd0 Merge "[DO NOT MERGE] Backup account access grants" into nyc-mr1-dev 2016-09-10 00:04:28 +00:00
Adam Powell
8469ffdcc1 Fix duplicate entries in ChooserActivity
am: 00e587086b

Change-Id: I3bfed096c104751f80519f72d2d6be1aeacbd109
2016-09-09 21:35:01 +00:00
TreeHugger Robot
b548ae5d5f Merge "Fix duplicate entries in ChooserActivity" into nyc-mr1-dev 2016-09-09 21:31:04 +00:00
Adam Powell
00e587086b Fix duplicate entries in ChooserActivity
Fix use of wrong index when checking for duplicates.

Bug 31234526

Change-Id: Ia37d1b04a9054b8d90957057db857633e4b79569
2016-09-09 10:26:35 -07:00
Svet Ganov
72ed12c55f [DO NOT MERGE] Backup account access grants
Sync adapters without an account access cannot run until the
user approves the account access (for the case the account
access is not allowed by other policy such as being singed
with the same cert as the authenticator). If the sync adapter
does not have permission to access the account we ask the
user to grant access and take a note. This CL adds backup
for the explicit user grants.

bug:31162498

Change-Id: I31e3f3d010475352c7c54255ac2d3a2fed4d0c72
2016-09-09 10:16:57 -07:00
Mihai Nita
c3b11eb043 Changed the header of the region selection list to "All regions"
am: 543e45babe

Change-Id: I7e42e404d7021094376104119f7568fe1838e489
2016-09-08 20:54:43 +00:00
Mihai Nita
543e45babe Changed the header of the region selection list to "All regions"
Bug: 31257462
Change-Id: I3112b5700e23674d2c48c7ca96a2f1a17a5f15db
2016-09-08 11:00:34 -07:00
Erik Kline
a457ebbda6 Have WakeupMessage call Handler#dispatchMessage()
Handler has no fewer than three ways by which a message might be
handled:

    [1] the msg itself contains a callback (msg.callback.run())

    [2] the Handler was instantiated with a Handler.Callback
        (mCallback.handleMessage(msg))

    [3] the Handler instance was a subclass and could have
        overridden handleMessage()

Handler#dispatchMessage() tries to find the correct way to dispatch
a message, check the above in the above order.

Bug: 21859053
Change-Id: I284cf7ace93af167d95d13b297ec42d4bed15992
2016-09-02 13:03:44 +09:00
Amith Yamasani
f10d31f5d0 Call Debug.getPss without a lock held
am: 10e8f16add

Change-Id: I8b55ec20fb8cb99941783c88f0a6035e4dcb1e9b
2016-08-31 17:13:57 +00:00
Amith Yamasani
9edadbd87a Merge "Call Debug.getPss without a lock held" into nyc-mr1-dev 2016-08-31 17:09:18 +00:00
Amith Yamasani
10e8f16add Call Debug.getPss without a lock held
Attempt to reduce the chances of watchdog killing the system
server if process pss gathering takes too long during heavy load.

Bug: 30896716
Change-Id: I4ed1a15c0c512a8c82842cde74e733d99d887ee0
2016-08-30 16:39:03 -07:00
Patrick Tjin
56734f96ec BootReceiver: Report correct headers for last messages
am: 60c17395a6

Change-Id: Ib938941dc0cdc066a476964732fc6ce7ee3daac9
2016-08-30 05:22:48 +00:00
Pat Tjin
6c0d81520b Merge "BootReceiver: Report correct headers for last messages" into nyc-mr1-dev 2016-08-30 05:18:35 +00:00
Jorim Jaggi
314c05db45 Add animation when unoccluding windows (1/2)
am: 6626f54e65

Change-Id: I09be1e1b7d830067c354c6cdfd940deafa027a22
2016-08-30 00:25:52 +00:00
Jorim Jaggi
6626f54e65 Add animation when unoccluding windows (1/2)
Before there was a jump-cut when a window that was occluding Keyguard
was going away, leading to an ugly flicker. To fix this, we do the
following.

- Always show windows with FLAG_SHOW_WHEN_LOCKED above lockscreen, even
if they don't "match" the currently occluding app (which is null in the
animation case)
- Move wallpaper behind last window that is not hidden by policy, so the
window doesn't get occluded by the wallpaper.
- Add a flag in the setOccluded call whether to animate or not. SystemUI
then plays a nice animation when it's set.
- Override the animation to always be the animation that happens when we
exit a window which is revealing the wallpaper behind, to make it
consistent with the home screen case.

Fixes: 30829255
Change-Id: Ib3fe20fc9003a0f9f291c974740f044ed8707e75
2016-08-29 14:15:33 -07:00
Teng-Hui Zhu
3687be955f Add TestApi to ValueAnimator for AnimationScaleListDrawable CTS test.
am: 0a815bb94f

Change-Id: I9b5d851f95349a7c8981ab8868608e21996a1bb5
2016-08-25 18:28:21 +00:00
Tenghui Zhu
1e37cc2f8a Merge "Add TestApi to ValueAnimator for AnimationScaleListDrawable CTS test." into nyc-mr1-dev 2016-08-25 18:24:12 +00:00
Michael Kwan
a064b9bb01 Merge "Add offset to round screens when an AlertDialog list item is shown." into cw-f-dev 2016-08-25 06:06:07 +00:00
Teng-Hui Zhu
0a815bb94f Add TestApi to ValueAnimator for AnimationScaleListDrawable CTS test.
Also rename an internal class.

b/30877925

Change-Id: Ib971ed090907a0ab387dd7c768e2b77eb9b69f75
2016-08-24 16:12:20 -07:00
Alan Viverette
ab508dd52b Override LinearLayout's onLayout pass in AlertDialogLayout
am: 1bb8f51e76

Change-Id: I63af639e859e2b7c72d93233c5b9ec7da2bb01cf
2016-08-24 18:28:40 +00:00
Alan Viverette
52306705c1 Merge "Override LinearLayout's onLayout pass in AlertDialogLayout" into nyc-mr1-dev 2016-08-24 18:17:04 +00:00
Teng-Hui Zhu
0bc9fa9896 Add an new internal DrawableContainer to handle animation scale == 0 case.
am: 0c03664fa6

Change-Id: I7feae01c6302e2942087c6dfe1948109467f1326
2016-08-24 16:28:55 +00:00
Alan Viverette
1bb8f51e76 Override LinearLayout's onLayout pass in AlertDialogLayout
LinearLayout sets up internal state during onLayout that's missing when
we override onMeasure. Avoid calling super.onMeasure() by re-implementing
onLayout without the internal state dependencies.

Bug: 30494039
Change-Id: I1149517a2fe5f5afdb4125db5e7f573588fea740
2016-08-24 12:26:27 -04:00
Patrick Tjin
60c17395a6 BootReceiver: Report correct headers for last messages
BootReceiver was using current build information when reporting
various versions. This was causing A/B devices to report the
wrong build information when reporting crashes since rebooting
a A/B device with a pending OTA would automatically apply the
OTA. (the problem was not seen on devices without A/B due to
booting through recovery to apply the OTA)

Bug: 30594862
Change-Id: I6f52081142e338c822c9135cba48a1f88f4d4bdb
2016-08-23 14:07:10 -07:00
Teng-Hui Zhu
0c03664fa6 Add an new internal DrawableContainer to handle animation scale == 0 case.
This will help ProgressBar to show something meaningful when animation scale is 0.
b/30877925

Change-Id: Ieb2e78712999d2e3f3a2a234bc605b4821ae41c0
2016-08-22 15:36:32 -07:00