summaryrefslogtreecommitdiffstats
path: root/services/core/java/com/android/server/notification
Commit message (Collapse)AuthorAgeFilesLines
* VolumeZen: Introduce internal vs external ringer mode.John Spurlock2014-11-253-95/+172
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Stabilize mapping between ringer-mode=silent and zen=priority by keeping track of two ringer modes: - Internal ringer mode: Used for underlying stream muting - External ringer mode: Reported to clients The mapping between external ringer mode + zen is: - normal = all - vibrate = all - silent = priority (read-write) or none (read) Changes include: - Remove "zen check" from audio service, back to audio service having no knowledge of zen. - Maintain a new external ringer mode in audio service, this is the ringer mode reported through AudioManager to callers, also mapped to the change intent. - Introduce a "ringer mode delegate" to the local audio manager interface, responsible for observing external / internal mode changes, and making changes if necessary. - Internal ringer mode changes are still interesting to the volume dialog, wire up a callback through the existing IVolumeController interface. - On devices without vibration, the mapping is the same but since no ringer mode change is possible, disable the icon toggle and remove the mute icon when volume=0. - On devices with vibration, volume down presses should pulse the vibrate icon (and vibrate) as a hint that this is as low as the device can go using the keys. Since the mechanics are similar to the existing zen=none hint, pull into shared helper. - Log ringer mode changes to the zen log, include calling package information for issue diagnosis. - Include whether vibration is supported in the audio service dump. - Update the status bar icon policy to use the internal ringer mode, not the external mode (for vibrate icon). - Update the "Muted by <x>" logic, include current suppressor in dumpsys, ensure suppression icon is enabled & !clickable, regardless of zen mode. Bug: 17884168 Bug: 15471679 Bug: 16824970 Change-Id: Ia7d3bb23ce6d1e37b24fb6521d1c1ab9bb8f60c0
* LED should not be blocked by interruption filtering.Chris Wren2014-11-241-3/+3
| | | | | Bug: 17204854 Change-Id: Ife30c2ebbcf3fce87ac262dbd339b694d4a57728
* Use stream type if set by userMarco Nelissen2014-11-181-7/+4
| | | | | Bug: 18426086 Change-Id: I0df390ddb850f8e2a02e24296f2a0d39f5718839
* Zen: Update condition text for current condition.John Spurlock2014-11-132-7/+31
| | | | | | | | | | | | | | If the provider sends us an updated summary (or other text) for the currently selected exit condition, update the UI and persisted condition. Update the downtime condition text (end time/line2 + summary) when the next alarm changes (if downtime = none). Also, clear the fired-alarm cache on time or time-zone resets. Bug: 16373455 Change-Id: Ib38c52104a281fcc04a89612b643a219fd82b40b
* Zen: Exit downtime on next alarm (if mode=none).John Spurlock2014-11-112-14/+69
| | | | | Bug: 16373455 Change-Id: Ie5d878ea4f930556ed84225c21d7c6df61024fbc
* Zen: Pull next-alarm tracking out into separate helper.John Spurlock2014-11-104-205/+340
| | | | | | | In preparation for sharing with DowntimeConditionProvider. Bug: 16373455 Change-Id: If8d90187fa399935137c7ba6152925a9106a4596
* Zen: Track next-alarm condition across reboots.John Spurlock2014-11-061-19/+54
| | | | | | | | During a reboot, wait for the initial alarm registration - which is traditionally done in response to ACTION_BOOT_COMPLETED. Bug: 16373455 Change-Id: I00dd737fa5c9ea15d646779c5b92e5637a69595a
* Zen: Add the ability to enter "None" mode during downtime.John Spurlock2014-11-053-27/+36
| | | | | | | Updates to the shared config structure and the service backend. Bug: 16373455 Change-Id: I45761690ba6b32eb81c9e2a5c1f2d4adad93e58d
* Zen: Create a new exit condition for "next alarm".John Spurlock2014-11-053-1/+339
| | | | | | | | | | | | - If the user's next alarm is in the next 12 hrs, provide this as an exit condition trigger for leaving none/priority. - Don't display the next alarm condition when downtime is active. - When the next-alarm exit condition is active, follow changes to the next alarm, assuming it remains within the 12-hr window. - Tweak the downtime condition strings to be consistent. Bug: 16373455 Change-Id: I4020b91d323dead998e62d655132eca07438b148
* Merge "Listen for package changes for all users not just owner." into ↵Kenny Guy2014-10-291-7/+27
|\ | | | | | | lmp-mr1-dev
| * Listen for package changes for all users not just owner.Kenny Guy2014-10-281-7/+27
| | | | | | | | | | | | | | | | Listen for package changes for all users to cancel notifications for secondary users and profiles when an app is uninstalled. Bug: 18151696 Change-Id: I6921729e2878e1e5890411b173a56849eb2e0745
* | NoMan: Add update bit to notification_enqueue logChristoph Studer2014-10-271-8/+8
|/ | | | | | | | Log whether an enqueued notification updated a previously present notification. Bug: 18083122 Change-Id: Ie6ed69f0bf53c668701b44e33282ca74b509a7e3
* NoMan: Log canceled notificationsChristoph Studer2014-10-241-0/+2
| | | | | | | | In addition to logging cancelation command, also log actually canceled notifications via the new eventlog tag notification_canceled. Bug: 18083122 Change-Id: I1e3e1e1368f39519f34c002ae374f318f647a401
* SysUI/NoMan: Log clicks on notification buttonsChristoph Studer2014-10-222-0/+15
| | | | | | | | | Introduce notification_action_click logtag that is logged whenever the user clicks any notification button. For standard templates, we also log the index of the pressed action button. Bug: 18064190 Change-Id: Icb07795ff711729d16bde0b7e03d13c2f466779c
* Disable zen log printouts by defaultGriff Hazen2014-10-201-1/+2
| | | | | Bug: 18056528 Change-Id: I77359476ff2f67027383fcdb91d2843d040533c7
* Leave zen when apps set ringer-mode = non-silent (normal/vibrate).John Spurlock2014-10-151-1/+1
| | | | | | | | | | Apps can end up in priority mode by setting ringer-mode = silent. Now they can leave priority mode by setting ringer-mode = non-silent. (normal or vibrate) Bug: 17884168 Change-Id: I54c853885f4ae9ee618041dd7ac6ab0663fc7b37
* Put in real "code" (aka marketing) name.Dianne Hackborn2014-10-071-2/+2
| | | | Change-Id: Idb3976edfae37293ed75cb5b869b4b42d8042bbe
* Disable notification effects during phone calls.John Spurlock2014-10-023-7/+50
| | | | | | | | Listen for phone call state changes in NoMan, and disable incoming non-call notification effects when non-idle. Bug:17658454 Change-Id: I6f7d66413970fbff6822ab29a12f91cbed068261
* Zen: Fix new event category check.John Spurlock2014-10-011-33/+35
| | | | | | | | Allow events through if configured, and use a switch for separating mode-specific logic. Bug:17580878 Change-Id: Id7b5d8b50173015d6a78568ed0a90e0bccf98549
* Merge "Zen: Fix downtime calculation for Sunday mornings." into lmp-devJohn Spurlock2014-09-291-1/+2
|\
| * Zen: Fix downtime calculation for Sunday mornings.John Spurlock2014-09-291-1/+2
| | | | | | | | | | | | | | | | Previous calculation would always exit downtime on Sunday mornings, due to the target day ending up at zero (an invalid day). Bug:17682999 Change-Id: Icc5f01a42c3c644170eea9e60442cf77ce15a06c
* | NoMan: Evaluate all contacts matching EXTRA_PEOPLE URIChristoph Studer2014-09-291-33/+29
|/ | | | | Bug: 17660485 Change-Id: I8684067538fcd2d43a9f95c6aa707b275b13ee40
* NoMan: Add 3s timeout in matchesCallFilter()Christoph Studer2014-09-243-8/+68
| | | | | | | | | | | | In Priority mode, NoMan can block the telecom Ringer indefinitely when looking up the caller contact details via ContactsProvider. Fix this by introducing a 3s timeout and assume the call matches the call filter when the timeout is hit. Bug: 17598245 Change-Id: Ia0893cf203e6ffd943c749719ebb9e0f0958eb01
* Zen: Add events as a new config attribute.John Spurlock2014-09-221-3/+12
| | | | | | | | Decouple events from alarms in the zen interception function, and default the new allowEvents to true. Bug:17580878 Change-Id: Iff10df385206ad73c3423ff118c79e94a10918d9
* Remove FLAG_FOREGROUND_SERVICE on Service.stopForeground()Christoph Studer2014-09-193-0/+29
| | | | | | | | | | | | | | | When services call Service.stopForeground(), remove FLAG_FOREGROUND_SERVICE from the notification that was supplied to Service.startForeground(). This enables services to post notifications that become user dismissable when they switch to being a background service. Restrict this to targetSdk=L apps to reduce the risk of breaking existing apps. Bug: 17551106 Change-Id: Iff8541e5bb2a23ad1fbc9ad80df5fd6eb683148b
* Renaming Telecomm to Telecom.Tyler Gunn2014-09-121-3/+3
| | | | | | | | | | - Changing package from android.telecomm to android.telecom - Changing package from com.android.telecomm to com.android.server.telecomm. - Renaming TelecommManager to TelecomManager. Bug: 17364651 Change-Id: I192cb5d189f55db012ea72ee82ccc5aedbc21638
* Invalidate the people cache on Contacts provider changes.Chris Wren2014-09-121-0/+21
| | | | | | | | | The Contacts database only seem to notify that a change has happened, not which row was changed. We simply invalidate the whole cache on changes. Added an info log for even 100th invalidation, so we can see how often it happens. Bug: 17466975 Change-Id: I9988ea8db776c88afd835a4b3c50b9a982a309d0
* Merge "NoMan: Refresh ManagedServices on user switch" into lmp-devChristoph Studer2014-09-122-0/+20
|\
| * NoMan: Refresh ManagedServices on user switchChristoph Studer2014-09-122-0/+20
| | | | | | | | | | | | | | | | Fix a bug where ManagedServices didn't unbind from obsolete and bind to new services after switching the current user. Bug: 17477093 Change-Id: Ica28978a01f84ba17bdd93e2feaf68547e837bcc
* | Merge "remove unused matchesCallFilter(Bundle, int)" into lmp-devChris Wren2014-09-122-8/+2
|\ \
| * | remove unused matchesCallFilter(Bundle, int)Chris Wren2014-09-052-8/+2
| | | | | | | | | | | | | | | Bug: 17402728 Change-Id: I0be7c70597a629ca0bd60b7230ffcc58e8e7aeac
* | | Fix a NPE in NotificationManagerSerivice.cancelNotificationFromListenerGriff Hazen2014-09-111-5/+4
| |/ |/| | | | | | | | | | | If a provided notification key does not resolve to a Notification Record Bug: 17473071 Change-Id: Ib4b4156ca91eb9e545274a36722c2dc547aa39a3
* | Merge "Prevent NotificationManagerService from using bad stream type" into ↵Jean-Michel Trivi2014-09-091-6/+12
|\ \ | | | | | | | | | lmp-dev
| * | Prevent NotificationManagerService from using bad stream typeJean-Michel Trivi2014-09-081-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When deriving AudioAttributes from a Notification instance, and having to use the legacy stream type field, make sure it has a valid value, or use the default notification attributes. Bug 17408227 Change-Id: Icd1a122b33b8eceb1f6a177699885b0fb8a99b7c
* | | Merge "Zen: Map transition to ringer-mode silent to "priority"." into lmp-devJohn Spurlock2014-09-091-2/+2
|\ \ \
| * | | Zen: Map transition to ringer-mode silent to "priority".John Spurlock2014-09-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of "none". Bug:16875664 Change-Id: I2a425663f08f35854e7e857330afc20eef01ef2e
* | | | Merge "Remove reference to StatusBarNotification after the value is ↵Griff Hazen2014-09-091-2/+5
|\ \ \ \ | |/ / / |/| | | | | | | accessed." into lmp-dev
| * | | Remove reference to StatusBarNotification after the value is accessed.Griff Hazen2014-09-051-2/+5
| |/ / | | | | | | | | | | | | | | | | | | | | | StatusBarNotificationHolder values are fetched exactly once. Bug: 15426276 Bug: 16575857 Change-Id: I3d11aba717d17426d31e7b1a07560f6b7e79c4ec
* | | Merge "NoMan: Fix speedbump with multiple package priorities" into lmp-devChristoph Studer2014-09-081-0/+5
|\ \ \
| * | | NoMan: Fix speedbump with multiple package prioritiesChristoph Studer2014-09-051-0/+5
| | |/ | |/| | | | | | | | | | Bug: 16782616 Change-Id: I747dc981f7974720da9f277ec6e3fba31c21f226
* | | Merge "Zen: Remove suppression of untagged vibrations in zen mode." into lmp-devJohn Spurlock2014-09-081-6/+0
|\ \ \
| * | | Zen: Remove suppression of untagged vibrations in zen mode.John Spurlock2014-09-081-6/+0
| | |/ | |/| | | | | | | | | | Bug:17313184 Change-Id: I07d24a7d9ce15160a4990391c53d7d6309a13c3e
* | | Merge "Update downtime to handle TimeZone change" into lmp-devJason Monk2014-09-081-0/+4
|\ \ \ | |/ / |/| |
| * | Update downtime to handle TimeZone changeJason Monk2014-09-051-0/+4
| | | | | | | | | | | | | | | Bug: 17344461 Change-Id: Ic18d0c469fac5a4c8973e52dd1e687cea2266b55
* | | Merge "Reduce chance of notification listener dropped messages." into lmp-devGriff Hazen2014-09-051-2/+23
|\ \ \ | |_|/ |/| |
| * | Reduce chance of notification listener dropped messages.Griff Hazen2014-09-021-2/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing code for notification manager/listeners uses a oneway binder api to deliver messages. One problem with this is that notification objects can sometimes get fairly large, and can bump into the oneway binder transaction buffer if many happen at once. To reduce this issue, flip the service into a oneway delivery of a status bar notification holder, whose wrapped content is then immediately fetched upon receipt of the one-way message. This moves the meat of the fetch to be over a two-way interface without changing the properties of which object is actually sent (a tickle solution with lookup key would have changed this) Further research: attempt to chunk notification objects themselves. They can sometimes transfer hundreds of KB over a binder transaction. Bug: 15426276 Change-Id: Ib1a1f4ff848c16f80bcf2ae4dfd2b87a9091f0b2
* | | Merge "Keep contact affinities separate across users." into lmp-devChris Wren2014-09-054-59/+112
|\ \ \
| * | | Keep contact affinities separate across users.Chris Wren2014-09-054-59/+112
| | |/ | |/| | | | | | | | | | | | | | | | Also ignore people extras on USER_ALL notifications. Bug: 16213960 Change-Id: Ic0341c88d42d4a4f12cac35c0f41c2746aec02ac
* | | Merge "NoMan: Fix speedbump for PRIORITY_MIN intrusives" into lmp-devChristoph Studer2014-09-051-0/+3
|\ \ \
| * | | NoMan: Fix speedbump for PRIORITY_MIN intrusivesChristoph Studer2014-09-051-0/+3
| |/ / | | | | | | | | | | | | Bug: 16782616 Change-Id: I35fb875bed8cbd90ecd37edc8973c1771be3584d