Commit Graph

439 Commits

Author SHA1 Message Date
Mady Mellor
b91efb8b36 Visual changes to PIP drag to dismiss UI
Updated gradient asset, spacing, and added shadow to text

Test: Manual: have a PIP, move it around, observe drag to dismiss UI
Bug: 35358628
Change-Id: I8614468edfc14d0337d69184a7bbab5419f22ec3
2017-04-13 17:20:15 -07:00
Jason Monk
ec9afcd4c5 Merge "Visual changes to dual target tiles" into oc-dev 2017-04-12 17:00:02 +00:00
Jason Monk
209e03e2ff Visual changes to dual target tiles
Test: visual
Change-Id: I856cae03587fc9a1e49fbfbdbf1e6abfbbf114ca
Fixes: 37007988
2017-04-11 13:57:45 -04:00
Jason Monk
e763a26c11 Fix screen pinning in seascape
Test: visual
Change-Id: I7792d0f5f98e83f0b2fd57a831e82efa07533c2b
Fixes: 34072199
2017-04-11 14:16:06 +00:00
Mady Mellor
60421c9d45 Update PIP dismiss to show scrim + info text at the bottom of the screen
- Rather than testing how far off screen the PIP is, instead tests how far
  past the nav bar / on screen bars the PIP is to determine if it is a
  dismiss
- When dragging PIP around screen, display info text + scrim at bottom
  these are above the PIP in z-order
- On lift up or when PIP is dismissed, info text + scrim also hide
- Alters dismiss animation to use end point on trajectory of finger and
  use FlingAnimationUtils when flinging

Test: Drag PIP around screen, notice dismiss scrim + text appear, dismiss
      PIP and scrim / text also disappear
Bug: 35358628
Change-Id: Ibc0f6a884903f7d1b3ca2fd5c20647b4acf15a71
2017-03-30 17:30:38 -07:00
Jorim Jaggi
6f9dbcb742 Implement new thumbnail loading strategy
- By default, we load only the reduced resolution screenshots.
- As soon as the user stops scrolling fast, we also start loading
full resolution screenshots.
- We prefetch reduced resolution screenshots when scrolling from
back to front, as the other direction is automatically prefetched
because the thumbnails aren't immediately visible.

Test: Open many apps, adb restart, scroll fast and slow in recents
Test: runtest systemui -c com.android.systemui.recents.model.HighResThumbnailLoaderTest
Bug: 34829962
Change-Id: I7f7a9842eb28a09a18573426fa9677cee2877124
2017-03-21 14:59:48 +01:00
TreeHugger Robot
13b13f0816 Merge "Remove qs_footer_dialog_network_logging_icon_alpha" 2017-03-15 15:47:03 +00:00
Robin Lee
5760fd9b9c Remove qs_footer_dialog_network_logging_icon_alpha
This washes out the network logging icon in the network monitoring
dialog, making it look strange compared to the dark VPN key.

Fix: 35620542
Test: inspection of dialog
Change-Id: I72bc6337b88b16235dab7b48d11efee4410ede5e
2017-03-15 14:06:59 +00:00
Winson Chung
e7a3d2225c Updating expanded PiP menu.
- Adding consistent scrim behind menu
- Tweaking icon/button sizes
- Updating the expand button depending on the current placement of the PiP
- Better centering of the expand button

Bug: 35358425
Test: Expand pip
Change-Id: I34575bb08d4815f51b6f14f8b0e25b20b9a97320
2017-03-09 14:46:05 -08:00
Mady Mellor
a7f69740b5 Update how PIP size is determined
- minSize = 108dp
- defaultSmallestEdge = max(23% of screen width, minSize)
- the shortest edge of the PIP should be minSize and the rest scales
  according to the aspect ratio
- rather than a default PIP size, use default aspect ratio
- adding expand button
- fitting actions to spec

Fixes: 35358504
Test: manually used test app to try different aspect ratios
Change-Id: Ib6890fb7824889b9edeea7efb5b9771e64fc1514
Signed-off-by: Winson Chung <winsonc@google.com>
2017-03-06 16:39:11 -08:00
Jason Monk
e5b770e47d Updated QS UI
- Adds footer to QS which contains the date/alarm info
   and all touch targets (settings, edit, etc.)
 - Swaps out emergency + carrier text on cell tile for a
   standard CarrierText from lock screen in the header
   to make the header only contain status info.
 - Add dividing line
 - Work on animations

Test: runtest systemui
Change-Id: I97dfea1b1ea7006b53eb61ac3a1f942c64dd282d
2017-03-04 20:02:09 -05:00
TreeHugger Robot
8f1a1dd0fc Merge "Don't show the percentage twice when charging." 2017-02-22 21:11:34 +00:00
Selim Cinek
160bf4cbac Merge "Making the notification always center horizonally" 2017-02-21 22:05:21 +00:00
Dan Sandler
df14c20be4 Don't show the percentage twice when charging.
The old percentage textview is now gone from the layout.
When the device is charging (but the user doesn't have
percentage display turned on all the time) use the new
percentage built-in to BatteryMeterView.

Bug: 35521962
Test: visual
Change-Id: I91f3350f6203fd007f003ca260ac0ed78e29b771
2017-02-21 16:17:09 -05:00
Julia Reynolds
027c7499d0 Move volume dialog expander
Bug: 33760714
Bug: 32727078
Test: manual
Change-Id: I06934bf140483957b734d5b1b20e3c7c6b7b4497
2017-02-17 22:18:49 +00:00
Selim Cinek
9e87cba5a9 Making the notification always center horizonally
The notification panel always center horizontal, since
it could lead to an offcenter notification sometimes.
Also applying the gravity correctly.

Change-Id: I2056dae0dfc1e4625e7903511464dc3edd8ac3f5
Fixes: 27566718
Test: rotate, observe HUN location after rotation
2017-02-17 13:29:54 -08:00
Jason Monk
f13413e2f3 Various QS fixes and cleanup
Test: runtest systemui
Change-Id: If87f58f2af00b23c5e1a8e38a63a6a63d903002c
2017-02-15 17:48:27 -05:00
Selim Cinek
87ed69bd6b Heads-up notifications of increased height behave better
In the shade, the heads-up version when their height is
increased now behave better and the notification shows more
then a single message as well.

Test: add heads-up for messaging style notification while shade is expanded
Bug: 34469375
Change-Id: Ia3475eec5b4474aae950ef0eb84afb28689245ae
2017-02-13 13:51:37 -08:00
Geoffrey Pitsch
df44b606f3 Updated Inline Notification Controls
Removed old xml resources, strings, dimens, etc
Different behavior when sent from the default channel.
Display how many notification categories are used by the app.
Group label when channel is associated with group.
Add package icon.
Fix tap-away-to-save behavior

Test: runtest systemui
Change-Id: Ib41a536a5c4e7c7747a2453eddc3b4b4b99ffa7a
2017-02-10 13:24:54 -05:00
TreeHugger Robot
ba89ed754f Merge "Move the logic of batteryMeterDrawable to settingslib" 2017-02-08 10:14:28 +00:00
jackqdyulei
597b10f6db Move the logic of batteryMeterDrawable to settingslib
In Settings, we also need a BatteryMeterDrawable to show battery meter,
that's why I move it to settingslib.

In this cl, what I have changed is listed below:
1. Create BatteryMeterDrawableLib that contains logic of battery
drawing.
2. Still Keep the battery control logic in systemui.
3. Remove hardcoded battery color by using the color state lists.
4. Move some tests to settingslib

Bug: 34771849
Test: make SettingsLibTests

Change-Id: I39c0f0e31ca5e1b958467298db1d0590d16c9f6d
2017-02-07 17:27:00 -08:00
Selim Cinek
4f3463290b Merge "Increased the collapsed size of messaging notifications" 2017-02-02 23:59:08 +00:00
Anthony Chen
3cb3ad9998 Refactor notification to allow for overlay by Android Auto.
Android Auto requires different styling for notifications. In
particular:

- Background of scrim to be a different color
- Notification shade should always be full width
- No quick settings
- User switcher always visible
- Card styling, such as rounded corners and more spacing between items.
- Notification shade to be triggered from a button on the navigation
  bar.

Refactored different areas of the framework to allow for this. This
mostly means extending notification code and overriding methods where
appropriate.

Test: manually tested
Bug: 33487455
Change-Id: Ifcea70e121c1cbbeb057bb6ce8d351336ae41554
2017-02-01 10:05:07 -08:00
Selim Cinek
7d1009b3bd Increased the collapsed size of messaging notifications
Messaging notifications now get an increased boost in size,
since those are usually important to the user.

Test: existing tests pass
Bug: 34469375
Change-Id: Idfc2d2403b04c4c2d17b821e3ccbbbd48d31654d
2017-01-31 10:26:03 -08:00
Mady Mellor
04d7a0fca0 Add snooze to notification menu row
Moves the snooze plugin code into system UI.
Does not include assistant suggestions.

Test: manual
Change-Id: Ie2c51d65381530c9a72cd8a871efdbf0d63da490
2017-01-25 13:43:09 -08:00
Mady Mellor
761cde1173 Rename notification settings icon row / gear to notification menu row
Test: manual
Change-Id: I3a84c5ea180bd1e53495c5a44a93fa1982056174
2017-01-25 12:23:36 -08:00
Jason Monk
3250885c9f Visual refresh for QS
Adds circles and things

Test: visual
Change-Id: I7d974fcfe6257357abfd1a7d0ee521f0e6cee588
2017-01-20 11:29:25 -05:00
Adrian Roos
0aac04ff79 AOD: Show ambient versions of notifications
Introduces a new visible type that is shown on ambient display.

Bug: 30876804
Test: manual
Change-Id: I889e386430eda79bb362313d9834aa7ecd829871
2017-01-17 16:52:34 -08: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
Geoffrey Pitsch
4dd5006ff5 Change Notification Inline Settings for Channels
Removes slider advanced settings.
Move more Guts internals out of BaseStatusBar.

Test: runtest systemui
Change-Id: I0cf7f144859d1248bd54e281cfe0b35a817376a6
2016-12-28 10:13:02 -05:00
phweiss
9e450e1233 Rework Device Monitoring Dialog in Quicksettings
If a device owner is active, the layout is changed from a
standard AlertDialog with only one string to a custom dialog
that includes information on Device Owners, and VPN and Network Logging,
if enabled.

BUG: 29748723
BUG: 33126622
Test: Manual, CTS-Verifier tests will be added later

Change-Id: I2bfca9d9d02a42d9c3b17683625eda29e9369666
2016-12-19 17:53:00 +01:00
Manu Cornet
8e17342610 Delete the separate grid recents activity and related code
Bug: 32101881
Test: Made sure everything builds & boots on sw600dp device and checked recents
Change-Id: I1236a1ec5f5d2f485d9825c39702130bbfc243ca
2016-12-16 16:31:19 -08:00
Winson Chung
a29eb98d9f Adding support for PIP actions.
- Introduced generic RemoteAction to represents an action
  that can be made across processes with an icon and text
  description based on a Notification action.
- Modified PinnedStackController to ensure that it notifies
  the listeners from the source of truth, this ensures that
  SysUI is in the right state if killed and re-registers
  itself.

Test: Enable menu & minimize in SystemUI tuner.
Test: android.server.cts.ActivityManagerPinnedStackTests
Test: #testNumPipActions

Change-Id: I5b5d0cf9de3f06b5687337d59cfb91e17355bdb1
Signed-off-by: Winson Chung <winsonc@google.com>
2016-12-14 12:15:07 -08:00
Manu Cornet
c733803433 Revert "Grid recents: tweak task header layout to better match mocks"
This reverts commit 4701b99356.

Change-Id: Id1a2f93f55b32e6544083254bb16e3d3722aa3dd
2016-12-13 17:32:20 +00:00
Manu Cornet
4701b99356 Grid recents: tweak task header layout to better match mocks
Test: Checked layout on local sw600dp device
Bug: 32101881
Change-Id: Ic205beea47fc67fca9b3c95b3d1318c156ccc9c1
2016-12-13 07:26:03 -08:00
Selim Cinek
e67e2a28ed Merge changes I25effa3e,Ibb58d1aa,I92454a1b,I878d20a8,I21037b40, ...
* changes:
  Enforcing padding on the bottom of the keyguard
  Fixes that notifications were sometimes clipped on the lockscreen
  Don't reset the velocity when flinging down just because of falsing
  Don't do icon animations if we are scrolling fast
  Don't translate the notification content while scrolling
  Fixed the scrim drawing in seascape
  Placed the overflow indicator perfectly in the collapsed center
  Improved the low priority behavior with the shelf
  Improved the performance of the notification shelf
  Fixed a bug where heads up notifications had no icon
  Added possibility to use canned animation for icons
2016-12-08 18:48:49 +00:00
Selim Cinek
378053af93 Enforcing padding on the bottom of the keyguard
When calculating the maximum padding, we need to require
some padding such that the indication text isn't overlapped

Test: add 6 notifications on sailfish, see no overlap
Bug: 32437839
Change-Id: I25effa3e971d4a0bfaef70615c8a6e29c906a6ed
2016-12-07 17:09:00 -08:00
Selim Cinek
727903ce56 Don't do icon animations if we are scrolling fast
We are now not doing any icon animations anymore
in case we are scrolling fast.

Change-Id: I878d20a8e6114dc58c3908d18cc5ba20e59972cf
Test: add notifications, scroll fast
Bug: 32437839
2016-12-07 17:08:55 -08:00
Xiaohui Chen
40e978e0d1 sysui: fix navbar button view orientation
Before navbar assumes rotation 0 means portrait and rotation 90
means landscape.  This is not necessarily true, in certain devices
the natural orientation (0) is landscape.  Here we removed that
assumption and make sure we use the right inflater at all times.

Bug: 32516898
Test: Locally on test device
Change-Id: I3db44dcb35d8511fb9d42b147b2bd137ff0750f7
2016-12-02 13:51:49 -08:00
Adrian Roos
1381047f42 Merge "Lockscreen: Restrict double taps to prevent falsing" 2016-12-01 22:28:24 +00:00
Selim Cinek
0e8d77e0ba Fixed a crash when changing font scales
The shelf doesn't need to be reinflated but should
reload its properties. Recreating lead to a bunch
of crashes.

Change-Id: I4628e0469f74c1a0201f7b1e6e86d187ad0e548d
Test: Change font size, observe no crash
Fixes: 33189282
2016-11-29 19:35:02 +00:00
Selim Cinek
0ec10ac7cf Merge changes from topic 'dyson'
* changes:
  Improved the transformation to an icon further
  Fixed a bug where the last notification could be invisible / faded
  Adapted the shelf color when transitioning
  Fully removed the bottom stack
  Fixed a bug where the first notification was cut off
  Fixed a a bug where clear all was invisible
  Fixed a flicker when expanding quicksettings on the lockscreen
  Added appear and disappear animations for the shelf icons
  Implemented a nicer transition when the icons overflow
  Added the possibility to animate X and refactoring
  Modified heads up experience
  Fixed a bug with not-gone notifications
  Adapted the animation to the full shade
  Fixed the lockscreen positon with a single notificaton
  Made heads up work again
  Fixed the transformation into the shelf
  Used different curve for the icons when expanding
  Refactored the stack animation logic
  Refactored shelf transformation code to support animations
  Improved the transition into the statusbar
  Adapted the icon transformation into the shelf
  Fixed the appearance of the shelf on the lockscreen
  Introduced the Notification shelf
  Refactored the viewstates for more modularity
2016-11-29 00:29:01 +00:00
Selim Cinek
875a3a11e2 Improved the transformation to an icon further
The content now shifts away more and without fading out.

Change-Id: I02b53400a68dc68ef49bc2bd830b51bced5a6ba1
Test: Add notification - test merging behavior
Bug: 32437839
2016-11-28 14:07:11 -08:00
Selim Cinek
db16737031 Fully removed the bottom stack
Moved the ambient notifications into the shelf
instead of having them behave with their own
physics. Previously the ambient notifications
were stuck in the old world behind the shelf,
but this doesn't make sense anymore.

This also fixed a bug where the notifications were
wrongly positioned on the lockscreen since the shelf
counted as a view that wasn't gone.

Test: add low-priority notifications, observe scrolling
Bug: 32437839
Change-Id: I3921ea9f80a06f1b6330315423b012174269ac8e
2016-11-28 13:55:56 -08:00
Selim Cinek
49014f8522 Implemented a nicer transition when the icons overflow
The overflowing icons are now represented as dots and
animate in and out nicer.
The shelf also animates much nicer from the regular statusbar
size if there are a lot of notifications.

Test: Add a lot of notifications, observe them nicely overflowing into dots
Bug: 32437839
Change-Id: I5906c076bbf5d48cbabdbacfd21234bed55c6caa
2016-11-28 13:44:34 -08:00
Manu Cornet
e138bd1955 Change the task layout to better match mocks, add "in" animation
This only adds an animation when transitioning into recents. "Out"
animations will come later as they need to be run in parallel with
launching the activity not to introduce any latency.

Test: Open recents on sw600dp device, check recents layout/animations
Bug: 32101881
Change-Id: I367f8e5c106cd06d2a7833c165ecb960a7821ed9
2016-11-23 14:48:30 -08:00
Selim Cinek
48ff9b4833 Improved the transition into the statusbar
When expanding, the shelf now transforms into
the statusbar, providing a more seemless transition.

This also modifies the panel peeking:
previously the panel was always peeking right after a tap timeout
which would take the panel away from the users finger.
The panel is now only peeking when the user clicked on the bar instead.

Test: Add some notification and collapse the panel. Observe nicer transition
Bug: 32437839
Change-Id: I772f6684e1cee2004e9b366d203a5c5188af4a93
2016-11-21 14:33:44 -08:00
Selim Cinek
0242fbb9fd Adapted the icon transformation into the shelf
The transformation is now more refined.

Test: Add notifications, scroll
Bug: 32437839
Change-Id: I2d553b2305fae508d2eb94ca4cee18faa41815a1
2016-11-21 14:33:44 -08:00
Selim Cinek
281c202784 Introduced the Notification shelf
Started the implementation of a new notification
scrolling model that dynamically transforms notifications
into a new icon shelf.

Test: Add notifications, scroll!
Bug: 32437839
Change-Id: Ic28cc1c82f2cda2ffa7a312648903b5bc2408820
2016-11-21 14:33:40 -08:00
Adrian Roos
9f0b002ecf Lockscreen: Restrict double taps to prevent falsing
Further restricts the second tap on ActivateableNotificationView
such that it must occur no further than 0.2in from the first tap.

Bug: 32766052
Change-Id: I033c1abc64c815d519153ced23ac9751471b1d05
Test: Tap notification on lockscreen. Verify that second touch is only accepted near the first tap
2016-11-10 16:33:35 +00:00