Commit Graph

716 Commits

Author SHA1 Message Date
Julia Reynolds
73481c8837 Merge "Some channel model updates" 2016-11-02 01:20:20 +00:00
Julia Reynolds
85769915e7 Some channel model updates
- Apps cannot update their channel settings after creation.
- Importance is required when creating a channel.
- Some method name changes.
- Ranker can't modify fields a user has changed.
- High and Max importance mean the same thing.
- The default channel adopts app wide settings on creation.
- The default channel is limited to importance low once target api is post n mr1
  unless the user changed it.

Test: runtest --path frameworks/base/services/tests/servicestests/src/com/android/server/notification

Change-Id: I73c449a6abe6d709046de79c5c54339cb2edf0b8
2016-11-01 19:31:34 +00: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
Julia Reynolds
8f488d3f2f Move autogrouping into framework.
Test: runtest systemui, and post and dismiss notifications, checking that they
are grouped (or not) appropriately.

Change-Id: I8f3ec497cebcb14a7853fac98b844a3fd4503141
2016-10-19 22:30:58 +00:00
Julia Reynolds
72f1cbb3b9 Add support for snoozing notifications
To a notification listener, snoozing will appear as a cancel
(with reason snoozed) followed by a post (when the snooze period
ends).

Apps can repost a snoozed notification, but the updates will not be shown
to the user until the snooze period ends.

Snoozing is canceled if the posting app or a notification listener
cancels the notification.

Any notification listener can snooze a notification. Technically apps
can snooze their own notifications also, though that's not public.

In this iteration snoozed notifications will be lost on device reboot.

Test: included. Also, various post, snooze, update, cancel tests with
a listener.

Bug: 30997603
Change-Id: I568a6448196f0992a17d20a4dac296321ec5092b
2016-10-13 16:18:11 -04:00
Adrian Roos
35afe2d8de Fix wake lock logic during Dream startup am: 9ede1d2602 am: 042c2349c6
am: 4ffff73947

Change-Id: If3c1dd67f402bc549cad76e5072817a1d1104463
2016-09-26 08:59:08 +00:00
Adrian Roos
4ffff73947 Fix wake lock logic during Dream startup am: 9ede1d2602
am: 042c2349c6

Change-Id: I6c8a9119fd841b071dfb9f0e54680eb3dd7a1ef1
2016-09-23 22:24:32 +00:00
Adrian Roos
9ede1d2602 Fix wake lock logic during Dream startup
Fixes a crash that would happen in all dreams
that did not have permission to acquire wake locks.
Instead moves the wake lock logic into the system
process. Also fixes a bug in DozeService where the
wake lock was not held until dozing was actually
properly initialized.

Fixes: 31612287
Bug: 31044352
Related-CL: I85955a2b7d6bad5171accbc336117a9660b1b198
Test: adb shell settings put secure screensaver_components com.android.dreams.basic/.Colors; adb shell service call dreams 1

Change-Id: Idb3f921ee71b6da6c2ab0c44c332ef91f93ddbc0
2016-09-23 15:11:15 -07:00
Adrian Roos
8cbd52be80 Hold WakeLock while DreamService starts am: 7445c0bb86 am: 5e18c826f3
am: f71c33a6ae

Change-Id: I4e404bbf3fd1995c0899883a6d9cf12210329a1c
2016-09-21 04:12:48 +00:00
Adrian Roos
f71c33a6ae Hold WakeLock while DreamService starts am: 7445c0bb86
am: 5e18c826f3

Change-Id: I4c8d223c8968f554ceabd9dd80bb55e19a5b7e34
2016-09-20 05:24:03 +00:00
Julia Reynolds
90eba6d81c Merge "Add Notification channels" 2016-09-16 15:35:27 +00:00
TreeHugger Robot
84024c1f09 Merge "Allow Condition Providers to bind/unbind themselves" 2016-09-15 21:29:10 +00:00
Julia Reynolds
38e6ca4e74 Allow Condition Providers to bind/unbind themselves
So they only run when needed.

Change-Id: I5cf3a572837cb773dcb4f278a9f86a9d909147e4
Fixes: 30727598
2016-09-15 19:31:29 +00:00
Julia Reynolds
206c7e9d83 Delete L->M upgrade code.
Bug: 25497753
Change-Id: I0ae55e0d49b0aa488b86e336a6246fe57cba8601
2016-09-15 18:06:36 +00:00
Julia Reynolds
b5e44b7966 Add Notification channels
In this iteration:
-Every app gets a default channel that notifications will be posted
to if they don't specify a channel themselves. The default channel
inherits app-wide settings on upgrade.
-Apps can create new channels without user approval, but apps
cannot change the name of a channel once created, nor can they ever
set the importance.
- When a notification is posted:
  - If the channel is marked as 'vibrates', vibration will be
    applied to notifications that lack a vibration. unlike the default
    notification flag, notifications will retain their custom vibration
    if given
  - Same with sound and lights
  - A notification's importance is the min of the app and channel
    importance
  - A notification can bypass dnd if: either the app or channel settings
    say it can
  - A notification's show on lockscreen setting comes from the app first,
    and the channel second if the app has no preference

Tests: in cl. also there's a cl for cts and a test app.

Change-Id: I630f99df655800b00586dcfab538d320d04fe0f0
2016-09-15 08:42:35 -04:00
Adrian Roos
7445c0bb86 Hold WakeLock while DreamService starts
Fixes a bug where DozeService would not properly initialize
because the CPU went to sleep before onDreamingStarted completed,
causing the pickup gesture to not work.

Change-Id: I85955a2b7d6bad5171accbc336117a9660b1b198
Fixes: 31044352
2016-09-08 20:06:48 +00:00
Esteban Talavera
50421f1a38 Do not toggle OEM unlock if bootloader unlocked am: c48b20f8f1 am: 83583bd596
am: b9bef2fb7d

Change-Id: I87ffae46a63f1543b55e075cecffb1d2c2e1c160
2016-08-11 19:11:52 +00:00
Esteban Talavera
b9bef2fb7d Do not toggle OEM unlock if bootloader unlocked am: c48b20f8f1
am: 83583bd596

Change-Id: Ib8293a02ca13587154133a939c4515de1a114bd9
2016-08-11 19:00:37 +00:00
Esteban Talavera
c48b20f8f1 Do not toggle OEM unlock if bootloader unlocked
Bug: 30681215
Change-Id: Ia0fd55dd7b6b731d6f5733fc733621e99bd7b153
2016-08-11 18:14:03 +01:00
Julia Reynolds
98aa59e407 Merge \\"Snooze schedule rules that were canceled by alarms.\\" into nyc-mr1-dev am: ae0aed951b
am: 261b655396

Change-Id: Icd0ff5a828d0f2a39bb0e39085cd9fd7788f354f
2016-07-20 20:51:12 +00:00
Julia Reynolds
261b655396 Merge \"Snooze schedule rules that were canceled by alarms.\" into nyc-mr1-dev
am: ae0aed951b

Change-Id: I18bd8e7528a6c24f350c97268b26fe91ef198290
2016-07-20 20:45:13 +00:00
Julia Reynolds
fe58f1f386 Snooze schedule rules that were canceled by alarms.
So a reboot or snoozed alarm doesn't cause them to
reactivate.

Bug: 30087850
Change-Id: I83fdb88009b515d442993944aec40df7365e830f
2016-07-20 14:50:39 -04:00
Jason Monk
b55c3c60a8 Merge \\"QS: Don\\'t use ComponentName to identify tiles\\" into nyc-mr1-dev am: a0967ebbdf
am: 356d4914b2

Change-Id: I83fad6237edfb9516e1fe40612b820c319f26cc5
2016-07-15 20:16:44 +00:00
Jason Monk
356d4914b2 Merge \"QS: Don\'t use ComponentName to identify tiles\" into nyc-mr1-dev
am: a0967ebbdf

Change-Id: Ib98a48e46f711b927a1b9e8d2b8162a59bfa3240
2016-07-15 17:03:46 +00:00
Jason Monk
a0967ebbdf Merge "QS: Don't use ComponentName to identify tiles" into nyc-mr1-dev 2016-07-15 16:55:23 +00:00
Julia Reynolds
62d1abf0bd Merge \\"Attribute manual zen mode in volume panel footer.\\" into nyc-mr1-dev am: f6d766020f
am: c2381727a7

Change-Id: Ibb38d3a68dd642b5d6507341b7e189b77bba9502
2016-07-13 15:41:55 +00:00
Julia Reynolds
c2381727a7 Merge \"Attribute manual zen mode in volume panel footer.\" into nyc-mr1-dev
am: f6d766020f

Change-Id: I89ee22c5304e7de651aa34bddf5635f2e87e6b01
2016-07-13 15:33:36 +00:00
Julia Reynolds
44ad6ff4c2 Attribute manual zen mode in volume panel footer.
So users know what app enabled DND.

Change-Id: I0aad862539b28302bf618641ad29cdfa956c8f33
Fixes: 29892371
2016-07-13 10:28:54 -04:00
Jason Monk
ee68fd889c QS: Don't use ComponentName to identify tiles
Evidently some apps redirect/obscure tiles in a way that makes
creating a ComponentName from the TileService useless.  Instead
generate a token which will be a much more stable way of identifying
tiles henceforth.

Change-Id: Id68550bcdcdc3e3987f09380f258610e7a5aca85
Fixes: 29121793
2016-06-30 14:49:50 -04:00
Jason Monk
099b337db9 Merge \\\"QS: Hacks to fix bigger problems in TileService binding\\\" into nyc-dev am: 1427bb3dc0 am: 955de27827
am: 1ae5fbb187

Change-Id: I07ea15c56048becb7cba5f27bb7037ae8e10aea2
2016-06-23 21:12:32 +00:00
Jason Monk
1ae5fbb187 Merge \\"QS: Hacks to fix bigger problems in TileService binding\\" into nyc-dev am: 1427bb3dc0
am: 955de27827

Change-Id: I54da9edd0593160ee38002cb2d97c64248a9ed96
2016-06-23 21:07:50 +00:00
Jason Monk
9981d94d54 Merge \"QS: Hacks to fix bigger problems in TileService binding\" into nyc-dev
am: 1427bb3dc0

Change-Id: I471055cbac21c09d23b60e6dab15bcc1cd1d6208
2016-06-23 21:02:13 +00:00
Jason Monk
955de27827 Merge \"QS: Hacks to fix bigger problems in TileService binding\" into nyc-dev
am: 1427bb3dc0

Change-Id: I9b5e57c302b6ae0f6accccf65b5e404a1ad780c0
2016-06-23 21:00:19 +00:00
Jason Monk
6edbefdd54 QS: Hacks to fix bigger problems in TileService binding
Bug: 29121793
Change-Id: I9cb8d8ee36ce5cc77ba3c11decb1b3a797fd7999
2016-06-23 14:59:22 -04:00
Jason Monk
4519b87423 Merge \\\"QS Tiles: Fix some problems with connecting through intent\\\" into nyc-dev am: 126088536d am: a5076ef7fa
am: 8f21a99bfa

Change-Id: Idd0944573e8db2b282795952ceb35d2fe9961419
2016-06-22 17:18:52 +00:00
Jason Monk
8f21a99bfa Merge \\"QS Tiles: Fix some problems with connecting through intent\\" into nyc-dev am: 126088536d
am: a5076ef7fa

Change-Id: I9bb70bc724c36906e014d6f86e48efe37bb42001
2016-06-22 17:10:34 +00:00
Jason Monk
a5076ef7fa Merge \"QS Tiles: Fix some problems with connecting through intent\" into nyc-dev
am: 126088536d

Change-Id: I7e8ee5c59d7f26dcbc2406a53c0c6c39a9d8f55e
2016-06-22 16:54:06 +00:00
Jason Monk
d8aa42f3e2 Merge \"QS Tiles: Fix some problems with connecting through intent\" into nyc-dev
am: 126088536d

Change-Id: Ie187a5c2e062f9b51fd21e80e81cac15f02ccbe6
2016-06-22 16:53:58 +00:00
Jason Monk
8753e184f9 QS Tiles: Fix some problems with connecting through intent
- Don't send Tile through intent, it can cause crashes
 - Clean up other issues surrounding this

Change-Id: I08c626cf39b36d349592c1e0b81627b9bc7eeeb3
Fixes: 29519485
2016-06-22 10:52:58 -04:00
Jason Monk
fe5ff2279f Merge \"QS API: Fix mService and mTile being null once and for all\" into nyc-dev
am: fc70b07385

Change-Id: I7327f5e4f7ac2180e0c584dc761b861c14dd475f
2016-06-18 02:09:57 +00:00
Jason Monk
6831aee5fa Merge \\\"QS API: Fix mService and mTile being null once and for all\\\" into nyc-dev am: fc70b07385 am: c552a36992
am: 6a06372bb9

Change-Id: I8164179f96be4195bcafb3528e8dcbc45946bee2
2016-06-17 21:49:07 +00:00
Jason Monk
6a06372bb9 Merge \\"QS API: Fix mService and mTile being null once and for all\\" into nyc-dev am: fc70b07385
am: c552a36992

Change-Id: I7a0cc08bbad4ae7ccfd3344f3235ab88eddefab4
2016-06-17 18:50:05 +00:00
Jason Monk
c552a36992 Merge \"QS API: Fix mService and mTile being null once and for all\" into nyc-dev
am: fc70b07385

Change-Id: I2aed24cf36354fbe332787082bcf628357bab3b1
2016-06-17 18:45:04 +00:00
Jason Monk
a3453b8bd9 QS API: Fix mService and mTile being null once and for all
Change-Id: Idd82e4c2f6cfc2b30432e15e23963c1d7a959e43
Fixes: 29121793
2016-06-17 13:04:05 -04:00
Jorim Jaggi
f5e5c3a72a Merge "Add new attributes for wallpaper info" into nyc-mr1-dev am: c27660d45a
am: acfed07f72

* commit 'acfed07f725466e866445cfdf4fda94fa0e8f0a0':
  Add new attributes for wallpaper info

Change-Id: Ie439547cb6964c1f90b2ac313408a502027ccd25
2016-06-04 00:41:07 +00:00
Jorim Jaggi
acfed07f72 Merge "Add new attributes for wallpaper info" into nyc-mr1-dev
am: c27660d45a

* commit 'c27660d45a920af49c9e53b1cabaa32fd4b3046c':
  Add new attributes for wallpaper info

Change-Id: I3dc04d70f50809ff20ec0fb23e0c3265450ff621
2016-06-04 00:27:04 +00:00
Jorim Jaggi
526505da25 Add new attributes for wallpaper info
Adjust test wallpaper to use these attributes.

Also fix some issues where wallpaper got laid out differently in the preview
mode.

Bug: 28770685
Change-Id: I259f3884f5f2c0b723a6a5ce012d45170f64c4c7
2016-06-03 15:50:31 -07:00
Svetoslav Ganov
0649158cad Merge "Properly set default voice interactor" into nyc-dev am: e34bb5a1ff am: 13f802dc01
am: a8cdb6f645

* commit 'a8cdb6f6453d23f915d5c470bbdf1000153df383':
  Properly set default voice interactor

Change-Id: I6310a3da7aeb0b8b78918399ef79a0fcc91d4792
2016-06-02 22:52:13 +00:00
Svetoslav Ganov
a8cdb6f645 Merge "Properly set default voice interactor" into nyc-dev am: e34bb5a1ff
am: 13f802dc01

* commit '13f802dc013866986be51328af21378783d19e61':
  Properly set default voice interactor

Change-Id: I29c2a1490877d4b25ca64fee8a53c6970d07a1f2
2016-06-02 22:47:29 +00:00
Svetoslav Ganov
bd28e027ed Merge "Properly set default voice interactor" into nyc-dev
am: e34bb5a1ff

* commit 'e34bb5a1ffc5fe35b2fbc58824ad5bfbc7ecad3d':
  Properly set default voice interactor

Change-Id: Ifcad5647ee8ab09765fe89f40693eb335996982a
2016-06-02 22:47:26 +00:00