Commit Graph

12698 Commits

Author SHA1 Message Date
TreeHugger Robot
59011d0f6f Merge "DozeService: Fix crash if StatusBar not yet initialized" 2017-01-11 21:19:30 +00:00
TreeHugger Robot
6e7ff7be76 Merge "Refactor ExpandableNotiRow" 2017-01-11 21:13:00 +00:00
Selim Cinek
6b74aba3d8 Merge changes Iedf3172f,I62aa349b,I38c6970b
* changes:
  Using a different interpolator when unlocking to an app
  Adapted the shade closing interpolator
  Fixed the appearing of the statusbar icons
2017-01-11 20:53:00 +00:00
TreeHugger Robot
3c4dd649da Merge "Show work unlock prompt on focus as well as touch" 2017-01-11 20:38:58 +00:00
Adrian Roos
0b2e23a427 DozeService: Fix crash if StatusBar not yet initialized
Fixes a bug where a crashing SystemUI may crash again after restarting
if the services restart in an unexpected order.

Bug: 34044765
Test: Crash SystemUI, observe that it doesn't crash again right away.
Change-Id: Id6f781ba29ff11be0850b1883ca2942f15e76324
2017-01-11 11:56:47 -08:00
TreeHugger Robot
97d9813245 Merge "Add one-shot plugin support" 2017-01-11 19:35:22 +00:00
Adrian Roos
eb434ff5b7 Refactor ExpandableNotiRow
Test: manual
Change-Id: I00e2b7ed3b710d3d6b656dfabec209bb8b22f390
2017-01-11 11:18:48 -08:00
TreeHugger Robot
3c6f28aa59 Merge "Added TaskWindowContainerController" 2017-01-11 19:14:55 +00:00
TreeHugger Robot
801e7bb7fd Merge "Do not select an importance for unspecified notifications" 2017-01-11 19:13:37 +00:00
Robin Lee
ad0118a358 Show work unlock prompt on focus as well as touch
With change I4576aaafa141ef5297f9c18935b747693a80f0fd we can be
reasonably sure this isn't going to instantly bring the prompt into
fullscreen, since launching this activity as an overlay in an
unfocused task won't bring it to the front.

But if it's launched in a focused task, it will get focused and
brought to the front, starting the unlock process. This saves us a
click, and user frustration, and is generally a good thing.

Bug: 31001762
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest (harness)
Change-Id: Ic5a33589e2b63d04e47c5f166da0077188cb55ea
2017-01-11 17:52:18 +00:00
Geoffrey Pitsch
4e7ae02ce0 Do not select an importance for unspecified notifications
Test: runtest systemui-notification
Bug: 34164846
Change-Id: I4988ce26264853fd9ab84ae02e995641edf933cd
2017-01-11 12:48:09 -05:00
Robin Lee
3101b3ad21 Merge changes I3fd28e69,If43820b6
* changes:
  Lock work tasks from SystemUI instead of ActivityStarter
  Bounce work challenge through a WorkLockActivity
2017-01-11 17:41:01 +00:00
Wale Ogunwale
e1fe7fa288 Added TaskWindowContainerController
For linking TaskRecord in AMS to Task window container in WMS.

Bug: 30060889
Test: bit FrameworksServicesTests:com.android.server.wm.AppWindowContainerControllerTests
Test: bit FrameworksServicesTests:com.android.server.wm.TaskWindowContainerControllerTests
Test: Existing test pass and manual testing.
Change-Id: I16248f3e96e5087ba24198a48a3bd10a12ae76a6
2017-01-11 09:19:35 -08:00
Jason Monk
59d86ed2a8 Add one-shot plugin support
Should have happened a while ago.

Test: runtest systemui
Change-Id: I0da4deb5c297e8030213810815a408364ec97e14
2017-01-11 11:29:17 -05:00
TreeHugger Robot
2d75264011 Merge "Fixes for FlashlightTile lifecycle" 2017-01-11 16:02:54 +00:00
Jason Monk
861e09ade2 Fixes for FlashlightTile lifecycle
Change-Id: I690440465ef5312d77a279e73eaa22ccbdfbcd53
Fixes: 33861261
Test: runtest systemui
2017-01-11 09:41:05 -05:00
Robin Lee
c41f6ec877 Lock work tasks from SystemUI instead of ActivityStarter
By adding an onTaskProfileLocked(taskId, userId) RPC to
TaskStackListener and routing that through to a new WorkLockController.

Bug: 31001762
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest
Change-Id: I3fd28e6926c3f928e78b3c6ce0fe27413617695f
2017-01-11 14:13:07 +00:00
Robin Lee
3fef1f2843 Bounce work challenge through a WorkLockActivity
This stops us from depending on Settings for keeping the work profile
secure. Instead that is delegated to a smaller Activity inside SystemUI
which has just two jobs:

 1) Don't let anyone see the content that's supposed to be locked.

 2) Start ConfirmCredentialsActivity (still lives in Settings for now)

Bug: 31001762
Test: //cts/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/MixedManagedProfileOwnerTest#testResetPasswordFbe
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest
Change-Id: If43820b683007a60a37edf32fb65b442a8fb709b
2017-01-11 14:13:03 +00:00
Santos Cordon
e89ba5222c Merge "Add Brightness setting for VR Mode." 2017-01-11 03:02:02 +00:00
Santos Cordon
3107d29c8f Add Brightness setting for VR Mode.
This change saves and loads a different brightness setting when the user
goes in and out of VR Mode.

Test: runtests frameworks-core
Test: Turn vr mode on and change brightness (should remain separate from
normal brightness)

Bug: 30984614
Change-Id: If3c3e81b592e0c6fd037e5783559683e5cb58379
2017-01-10 17:16:04 -08:00
Philipp Weiß
89a2cf74ba Merge "Re-Add VPN-"Settings" button to QSFooter dialog" 2017-01-10 10:14:37 +00:00
Peeyush Agarwal
d06030c515 Merge "Fix KeyboardShortcuts show" 2017-01-09 22:05:25 +00:00
TreeHugger Robot
e7e4998784 Merge "Updating PIP to match UX" 2017-01-09 19:33:09 +00:00
TreeHugger Robot
337e36c5f4 Merge "Allow CommandQueue to have multiple callbacks" 2017-01-09 19:11:07 +00:00
Jiaquan He
5ae46bcb73 Force Grid-based Recents to show at most 8 tasks. am: 883887eac9
am: e1aee8bc8c

Change-Id: I3c231912c7be65768e8ade869203bfdc3c155624
2017-01-09 18:08:03 +00:00
Jiaquan He
e1aee8bc8c Force Grid-based Recents to show at most 8 tasks.
am: 883887eac9

Change-Id: I3960939f61acd8834101767481e5cafa7d9aac23
2017-01-09 18:03:34 +00:00
Jason Monk
b5b0920170 Allow CommandQueue to have multiple callbacks
Allow for multiple callbacks to be added to CommandQueue.
This will allow PhoneStatusBar to be broken up into pieces
that make more sense.

Test: runtest systemui
Change-Id: I73a7da1c23c8e45a291e5957e7341f3930abc334
2017-01-09 12:51:56 -05:00
Jiaquan He
883887eac9 Force Grid-based Recents to show at most 8 tasks.
Bug: 32101881
Bug: 33975969

Change-Id: Icbadaa3ca12f53e57e06dd19d7809a23e0efa88c
2017-01-09 09:51:24 -08:00
phweiss
a99a3f70e2 Re-Add VPN-"Settings" button to QSFooter dialog
Button was removed during a redesign of the dialog in the case
of active device owner. However, when no DO is set, the button should
still be there.

Also, when VPN configuration is restricted, do not show the button, and
also do not show the link that is visible in the DO-version of the dialog.

Bug:34156553
Bug:29748723
Test: manual

Change-Id: I177afdc94dc396754fc7703e4316edaa7ce104cd
2017-01-09 18:42:17 +01:00
Winson Chung
a5acf18dfe Updating PIP to match UX
- Updating menu actions to match design, fixing issue where
  the actions background would still be visible if there were
  no actions
- Enabling tap-to-show-menu, minimizing, snap-to-edge by default,
  and removing swipe to dismiss option.
- Making the visible size a fixed value instead of a fraction of
  the PIP size

Test: android.server.cts.ActivityManagerPinnedStackTests
Change-Id: Ib767df497ca7bc901c553d35168080f3b737033a
Signed-off-by: Winson Chung <winsonc@google.com>
2017-01-06 16:20:52 -08:00
Andrew Sapperstein
fcf6cc3062 Add temperature config for high temp warning.
am: 1cac83218c

Change-Id: I1aedaf0714e0f020f6e062bac716841ec472db2a
2017-01-06 20:04:30 +00:00
Andrew Sapperstein
1cac83218c Add temperature config for high temp warning.
Adds an integer resource (config_warningTemperature) that is used
to display the high temp warning. If it is set to less than 0,
the value from HardwarePropertiesManager#getDeviceTemperatures(
HardwarePropertiesManager.DEVICE_TEMPERATURE_SKIN,
HardwarePropertiesManager.TEMPERATURE_THROTTLING) is used instead.

Test: manual
Bug: 30995038
Change-Id: I05aa1b5930c6c151ebac439dfd5c00b3305dc46d
(cherry picked from commit 7518471ab6)
2017-01-06 18:28:10 +00:00
Andrew Sapperstein
e7dc98733d Merge "Add temperature config for high temp warning." 2017-01-06 18:27:26 +00:00
Julia Reynolds
bb983d20d2 Use internal volume controller and status bar.
Remove code that let these components be replaced by external
processes.

Bug: 33006669
Bug: 34106436
Test: manual. reboot device, play music, change volume,
view notifications
Change-Id: I458f11537ab9db6f23735487513815553004613f
2017-01-06 15:59:45 +00:00
Peeyush Agarwal
1a0f36f42d Fix KeyboardShortcuts show
The keyboard shortcuts should be shown only if they have not been
dismissed already (by using the dismiss method). Check that sInstance is
not null in the onKeyboardShortcutsReceived callback before displaying
the dialog. Earlier, a call to activity's dismissKeyboardShortcutsHelper
right after a call to requestShowKeyboardShortcuts would not dismiss the
popup which is not the case now.

Test: Manual
Change-Id: I544708b003d6baab92cac2b6fce71698dbbdaf0c
2017-01-06 15:51:53 +00:00
Chris Wren
5e6c0ffd3e Create a global registry for system message IDs
Port all system UI notifications to use the registry.  Retain stable
integer IDs where they exist. Assign new stable IDs where resource IDs
were previously used.

Using "message" rather than "notification" since we may eventually
want to include dialogs and toasts.

Bug: 32584866
Bug: 30995038
Test: runtest systemui
Change-Id: Iec4d7cebbd88683e339ada29a279315222699942
2017-01-06 09:22:02 -05:00
Andrew Sapperstein
7518471ab6 Add temperature config for high temp warning.
Adds an integer resource (config_warningTemperature) that is used
to display the high temp warning. If it is set to less than 0,
the value from HardwarePropertiesManager#getDeviceTemperatures(
HardwarePropertiesManager.DEVICE_TEMPERATURE_SKIN,
HardwarePropertiesManager.TEMPERATURE_THROTTLING) is used instead.

Test: manual
Bug: 30995038
Change-Id: I05aa1b5930c6c151ebac439dfd5c00b3305dc46d
2017-01-05 16:45:37 -08:00
Winson Chung
31c568274b Add logging for task view thumbnail state. am: eb2206cb51
am: 96a5c216b7

Change-Id: Id6f8fbdac18861ea1244b2c43885d978851694e7
2017-01-05 19:45:06 +00:00
Winson Chung
96a5c216b7 Add logging for task view thumbnail state.
am: eb2206cb51

Change-Id: Ibf8fed3d189483f8a8b351d87f406c90d0259fc5
2017-01-05 19:38:37 +00:00
TreeHugger Robot
1d513b28e3 Merge "Add logging for task view thumbnail state." into nyc-mr2-dev 2017-01-05 19:33:48 +00:00
Lei Yu
2cba0e8b0f Merge "Remove hardcoded color for cellular data usage view" 2017-01-05 18:57:57 +00:00
Ben Murdoch
f0b74e306d Remove two unused filters on PowerUI receiver.
Removing some dead code.

Test: None, remove dead code.
Change-Id: Ibcb31797dc1551f7fed540843afc58cb4eb7d077
2017-01-05 14:57:43 +00:00
Andrew Sapperstein
b54a792429 Added alert icon to high temp dialog.
am: bd4eeb7259

Change-Id: I8f6d4a0c9ba5c15478010714995243c305982707
2017-01-05 03:07:47 +00:00
Andrew Sapperstein
a477ead31c Add VR mode check for thermal notification
am: d51ac7322e

Change-Id: I056136375b74a38a4973951fb33f795e784bab1e
2017-01-05 03:07:01 +00:00
Andrew Sapperstein
104c66d71e Show notif when device reaches throttling temp
am: 67e97053c5

Change-Id: I44639cb19b7fa9547dc1e579a5beb34f923da2a7
2017-01-05 03:05:59 +00:00
Andrew Sapperstein
bd4eeb7259 Added alert icon to high temp dialog.
Test: manual
Bug: 30995038
Change-Id: I966294c5fb0b8297b2f336102996291f66c08d2c
(cherry picked from commit e26dc3d194)
2017-01-04 16:54:31 -08:00
Andrew Sapperstein
d51ac7322e Add VR mode check for thermal notification
When in VR mode, don't show the high temp notification
since VR shows its own notification.

Test: manual
Bug: 30995038
Change-Id: I845480d968a9b0da9997f035875885bc261c577a
(cherry picked from commit 65d8a5fc73)
2017-01-04 16:54:15 -08:00
Andrew Sapperstein
67e97053c5 Show notif when device reaches throttling temp
Adds logic to SystemUI that shows a notification alerting the user
that their phone has reached a certain temperature and has throttled
itself in order to cool down.

The logic is controlled by a configuration resource:
R.bool.config_showTemperatureWarning. If false, no action is taken.

When true, PowerUI checks every 30 seconds if the current temp of
HardwarePropertiesManager.DEVICE_TEMPERATURE_SKIN is greater than
the throttling temp of HardwarePropertiesManager.DEVICE_TEMPERATURE_SKIN.
If any one of the temperatures returned is greater, a notification is shown.

Clicking on the notification will show a dialog explaining more details
about what the device is doing in response to the high temperature.

The notification will disappear once the temperature drops below
the throttling temperature.

In order to check the temperature in SystemUI, HardwarePropertiesManager
has been updated to also allow any calls made by callers holding the
signature-level DEVICE_POWER permission.

Test: runtest systemui
Bug: 30995038

Change-Id: I1b3f122341911c68e90c8a49ad35267ac382b356
(cherry picked from commit b7caf1d06d)
2017-01-04 16:53:44 -08:00
jackqdyulei
b68fd7ae0a Remove hardcoded color for cellular data usage view
1. Remove hardcoded color and create colorStateList instead
2. Remove warning color and use attr textColorError instead
3. Add function to extract color from colorStateList

Bug: 32592245
Test: manual - Take screenshots
Change-Id: I7f0a54b304b09b99ba1f255952e7e99e009a4d2a
2017-01-04 16:12:44 -08:00
Andrew Sapperstein
388ef5df44 Merge "Added alert icon to high temp dialog." 2017-01-04 21:08:38 +00:00