Commit Graph

85 Commits

Author SHA1 Message Date
Julia Reynolds
8da8951b4b 'Allow sound' = let the app decide
Bug: 37479730
Test: manual
Change-Id: Ia5073dd0ef79664229c5aff0b89e7ef36edb68ee
2017-04-25 08:53:26 -04:00
Alison Cichowlas
7f431e3cd1 In apps with no channels, provide settings for misc channel in top level.
Test: robolectric tests pass, plus manual verification
Bug: 36561295

Change-Id: I58872a41fab562787d85bade0552c7735d716e5b
2017-04-18 18:49:24 +00:00
TreeHugger Robot
526185c89b Merge "Channel settings updates" into oc-dev 2017-04-18 15:03:55 +00:00
Julia Reynolds
c68ae0b9fd Channel settings updates
- Update master switch preference to store enabled state in case
it's set before the view holder is bound
- Update master switch preference to prevent disabled switches
from being toggled
- Show an importance summary for max importance
- properly handle null notification sounds

Change-Id: I395b95b76d2a3c1c94b41d1c2720bb0cf1cae917
Fixes: 36920159
Fixes: 37421928
Fixes: 36939825
Test: RunSettingsRoboTests & manual
2017-04-17 14:42:09 -04:00
Fan Zhang
be6fab0135 Update action bar style in app header UI.
- Update background color of actionbar
- Remove elevation of actionbar so it appears to be the same entity as
  app header.
- Add a shadow below app header view. We can't set elevation on app
  header unfortunately because that will add shadow all round the view,
  but we only want shadow below it.
- Updated app icon size/text size per to match UI spec.

Change-Id: I63d7fa42b859a008fa662aaf19848cd40529c2ff
Fix: 37207527
Fix: 37079248
Test: visual && make RunSettingsRoboTests
2017-04-17 09:30:40 -07:00
TreeHugger Robot
d09c7e61f4 Merge "Allow settings preference title to span over multiple lines." into oc-dev 2017-04-12 17:57:28 +00:00
Doris Ling
aa805e70ed Allow settings preference title to span over multiple lines.
- add singleLineTitle=false to SettingsPreference style, so that it will
not confined the title to a single line.
- remove the custom multi line title from DividerPreference and
MasterSwitchPreference.

Change-Id: I5a78d2cd6ac00c4482e252b0789fd2d265bd9adf
Fix: 34886787
Test: manual
2017-04-11 13:17:38 -07:00
Julia Reynolds
7be0dbd86c Sort channels and groups by id
Test: manual
Change-Id: I3949e9eb7b901bd897d848627682878937aac0c1
2017-04-10 12:47:13 -04:00
Julia Reynolds
dd8d392d7d Don't run postexecute if activity is gone.
Change-Id: I9133a4d9e4e0fd2a92cc4df786e0bc5407d981fe
Fixes: 36551766
Test: monkey tests
2017-03-29 10:42:07 -04:00
Julia Reynolds
521c8751b3 Show channel description.
Test: manual
Change-Id: I0965b0ad2c64571a01a5f221f8d344c60d54b53d
2017-03-17 15:10:29 -04:00
Julia Reynolds
8973e2786d Notification channel settings updates
- Show a deleted count instead of individual deleted channels
- Make the link to app settings more prominent
- Reload settings onresume

Change-Id: I4f493181194943310ba536eb2bca270cec7cafce
Fixes: 36119790
Fixes: 36191444
Test: manual
2017-03-16 14:31:00 +00:00
Julia Reynolds
2194f3db37 Display channel/group names only.
Test: manual
Change-Id: I7da68f71ddb78f3150ebc64af40310de65cd010c
2017-03-16 14:21:56 +00:00
Julia Reynolds
dcee38d02e Prevent whitelisted apps from blocking and silencing
Change-Id: I34cb5c2c59d56b68ed1500c8c79cd65676c0af25
Fixes: 35841524
Test: manual
2017-03-13 18:46:03 +00:00
Doris Ling
f2cf2aea37 Remove code that check for dashboard feature.
- remove DashboardFeatureProvider.isEnabled() and all relating code
and tests.

Bug: 35764802
Test: make RunSettingsRoboTests
Change-Id: If7796677abc8904b7436525836d50cdef38e37a4
2017-03-07 11:15:03 -08:00
Julia Reynolds
ca662cc9a7 Notification channel group res id labels.
Test: manual
Change-Id: Icf7208dc952a7306f04d53f4d681ec794563f2fd
2017-03-02 16:02:17 -05:00
Julia Reynolds
3327eac198 Show localized channel names
Test: manual
Change-Id: I85d60e564aeff8074cdb8138fe7ac1c078be986a
2017-03-02 10:35:33 -05:00
Julia Reynolds
762a733afa Allow switch preferences to span lines.
Test: manual
Change-Id: Ifcc801873ed143c4d9ceb6fb928c276808a95f81
2017-02-28 16:30:48 -05:00
Fan Zhang
c6ca314c0b Log source with visibility change
- Add a method in VisibilityLoggerMixin to log visible event using
  LogMaker, which allows logging additional FIELD_CONTEXT field.
- In Utils.startFragment, add current page's metricsCategory as an extra
  to next page.
- In next page's onResume(), extract the previous page's metricsCategory
  and send it to VisibilityLoggerMixin.visible()
- Update all caller with additional paramters

Change-Id: I8e1f2597fa465b7d3aa16fa1d21c052a3219694a
Fix: 35359289
Test: RunSettingsRoboTests
2017-02-15 17:17:19 -08:00
Julia Reynolds
e971015fd9 Link back to app settings from channel page
Test: manual
Change-Id: Ieb1118bd662a662bd34027f2ef44b420d4c94183
2017-02-09 10:08:52 -05:00
Julia Reynolds
6f57f2c2af Notification app screen updates
- Load channels asynchronously
- Add importance summary & block/unblock toggle for channel list
- Change channel list headers and sorting.

Test: manual
Change-Id: If024c741df4d85227055563d5bbc8210705c420b
2017-02-08 14:49:01 -05:00
Julia Reynolds
5d1506a2af Show channel groups in settings.
Test: manual
Change-Id: Icfaed2d2d898245fcfa50b25d7ad456e4db07bae
2017-01-30 14:58:35 -05:00
Julia Reynolds
694928883d Let extra apps launch channel settings.
Test: manual
Change-Id: I689c0b35224dffc306ecbfa6f25ad3f072cd4dba
2017-01-25 12:43:29 -05:00
Julia Reynolds
1f178a9ed1 Notification settings updates
- Add 'show badge' for apps
- disable deleted channel rows
- Add an importance reset for pre-O apps

Test: manual
Change-Id: Ic32415497fe48a17f6cdb9aace37e35f9388195a
2017-01-20 09:38:33 -05:00
Julia Reynolds
b41cf299fe Show deleted channels.
Test: run cts, verify manually in Settings ui
Change-Id: Ib6376decaa4ae427bb706ea48608a5aa8924da2f
2017-01-17 15:01:15 -05:00
Julia Reynolds
d6835a20fc Support showing notifications as badges.
And remove unneeded app level settings.

Change-Id: I88f506b0704195181d1748a3135f8ee0f39b774f
Test: manual for now. will add tests when have real mocks for the pages
2016-12-20 13:07:04 -05:00
Tamas Berghammer
265d3c2a0c Update package names to work with the proto3 compiler
Bug: b/28974522
Change-Id: I5f3adf4946ee4ba1e09e4f40afe83c151405972a
2016-11-08 14:06:17 +00:00
Julia Reynolds
ec767cc440 Channel updates from users lock fields from interference.
Also some apis have changed.

Test: manual, modify settings and check policy xml.

Change-Id: I967cb1fb30d8d400bdc0f3aa92fa07b4c87ddcf5
2016-10-31 15:16:28 -04:00
Fan Zhang
fdb833873a Use new app header in more screens.
- This covers app data usage settings, power usage details
- Addded helper method on AppHeaderController to build the header as
  Preference because every fragment needs to do this anyway.

Bug: 32442716
Test: RunSettingsRoboTests

Change-Id: I6d38321b867154f8fb5194b993d118bcdbbfedc9
2016-10-28 17:16:39 -07:00
Fan Zhang
1ff25ba7e6 Modify AppHeaderController to provide UI for notif settings
- The AppHeaderController is no longer a singleton. Each time appheader
  should be updated we will create a new controller. It acts as a
  builder/mutator, user provides customizable inputs, and the controller
  will bind everything to UI when calling done().

Bug: 32442716
Test: RunSettingsRoboTests
Change-Id: Icfc5bcd8bc170a02b57432d864eaddf71db0d5b4
2016-10-27 17:23:33 -07:00
Julia Reynolds
b5ec2d71a2 Add notification channel settings.
If a user has set a preference at an app wide level, it cannot be
undone at a channel level, but channels can be more restrictive.

Tests: changing settings for apps and channels.

Change-Id: I7907b8179ffc24d68197c917f182e63d8e1ff7a7
2016-09-15 21:46:17 -04:00
Fan Zhang
6507613ebc Log visibility change for all fragments.
Bug: 30681771
Test: SettingsUnitTests

Refactor visibility logging from InstrumentedFragment into a mixin. And
apply mixin in remaining fragments.

Change-Id: Ibbb59904336254a3e4bb9e8c7d0b36e5a6bc2622
2016-08-18 14:04:13 -07:00
Julia Reynolds
2c1eb80b1d Correct logic for showing overide dnd field.
Change-Id: Iae1d053d3816ccdae9f6d9bc6a16622b50e07440
Fixes: 29995563
2016-07-11 09:10:11 -04:00
Sudheer Shanka
2ad6adbd58 Add policy transparency to app notification settings on lockscreen.
Bug: 28390118
Change-Id: I395440b0f7e93da90f9f346574afa5501761d473
2016-05-09 10:57:34 -07:00
Julia Reynolds
21fd269ea3 Show 'on the lockscreen' setting in more contexts.
- For managed profile apps
- When 'auto' importance is on.

Bug: 28405255
Change-Id: Ia4c0bc6010f157cac18a828069bbcf54087fc663
2016-04-27 12:46:43 -04:00
Julia Reynolds
175bba9ed9 Don't crash on apps only installed for other users.
Change-Id: I13d415441aa1c7d09df7adccd4e2d2f9bbd3dbfb
Fixes: 28151314
2016-04-25 16:45:49 -04:00
Julia Reynolds
088fb52ef8 Notification slider changes.
Bug: 27558254
Change-Id: I15635ae19e82a57d6e6fcb2f8f946f31bebf5d0f
2016-04-15 11:04:13 -04:00
Julia Reynolds
3e912e7ea5 Notification summary updates.
Change-Id: I6b824acf27743637ca661b38b51c639ecf099208
2016-03-08 16:08:12 -05:00
Julia Reynolds
60e90ac07c Allow notifications be to hidden from the lockscreen by app.
Bug: 26642033
Change-Id: I932defebe00c566c0a930a0cabc118238c349272
2016-03-02 14:20:57 -05:00
Julia Reynolds
518b93f565 Introduce IMPORTANCE_MIN.
Bug: 22960980
Change-Id: Ia3876e0b3b5dae19553fd467313b46408fcbb0f4
2016-02-25 13:06:57 -05:00
Julia Reynolds
d4559a8035 Replace slider with switches; move slider to tuner.
Bug: 22451710
Change-Id: I86a57479757b3c7a43a789b0b3d7a81afb6d0cf9
2016-02-24 12:52:31 -05:00
Julia Reynolds
ed5c50a9cb Delete Notification Topics.
Bug: 23220370
Change-Id: I072b68650af35ae3d5c5ccf6222dc31f5f36f9bb
2016-02-17 15:13:44 -05:00
Andrei Stingaceanu
da49313845 Restrict notification preferences for suspended apps
Bug: 26856390
Bug: 22776761
Change-Id: I7f03b8b95af93db66f12c5ac1cbf490b4ae0e73c
2016-02-05 15:24:03 +00:00
Julia Reynolds
fe22e8998b Link to external settings activity from the app header.
Bug: 26288458
Change-Id: Ib7c723f23a09f2dbcb6c9738db8e455fb7b82462
2016-01-29 10:15:31 -05:00
Julia Reynolds
a7accd2064 Allow importance to be reset.
Change-Id: Ib2c2289631dfe4eb2aa09baf84d401eb2000c0d9
2016-01-28 17:27:22 -05:00
Andrei Stingaceanu
33e9656a53 Settings - disable notification settings for suspended apps
When we suspend an app we disable notifications for the app
(via notification manager as in Settings). While an app is
suspended do not allow the user to reach the
NotificationSettings screen.

Bug: 22776761
Change-Id: Ia0dbad6adce64b7d9238e1215a37c73e192dbc45
2016-01-28 21:21:54 +00:00
Chris Wren
9d1bfd1e8d port settings over to new metrics enum
Change-Id: I0b3efd2f4db773ccbc52bfe59ee8eb0dab9584fb
2016-01-27 10:58:58 -05:00
Julia Reynolds
92ea89c356 Show app level settings when app doesn't use topics.
Change-Id: I3c31a1bdddc70077182ea910911de1444472b7a9
2016-01-26 15:38:28 -05:00
Julia Reynolds
c9a1884ed8 Importance slide updates.
- Make settings match systemui
- prevent users from blocking system notification topics, and
share said code with systemui

Bug: 26575595
Change-Id: I3911046e2f96897b26b9b9597835a8d7b771996f
2016-01-15 15:18:02 -05:00
Julia Reynolds
df01cde11c Conditionally show settings.
Change-Id: I8e62ed6e2515b76de73d3d25adcfb121f809c646
2015-12-18 15:50:05 -05:00
Julia Reynolds
6f526fcaf3 Migrate package level notification settings to topic level.
Bug: 22854014
Change-Id: If0c20bec3b3f8b01b86d195d2e7ff7aa1e15882e
2015-11-20 15:09:29 -05:00