Commit Graph

10 Commits

Author SHA1 Message Date
Hawkwood Glazier
b8eef87bc2 Add Customization Lib
Bug: 258424862
Test: Manually rebuilt everything
Change-Id: If683023d2f592bb09827a50fbc79559b5b57cb3a
2022-11-18 21:13:35 +00:00
Lucas Silva
f24be85e54 Implement DoubleShadowIconDrawable for use in dream complications
Also refactors the code to place the double shadow code in a shared
location, and specify the shadow config in xml instead of hardcoding.

Bug: 239089588
Test: manually on device by flashing and verifying the icon atop the
dream has the proper shadow

Change-Id: I18db07c243e20785409d5cc760b614a8ee775f1f
2022-09-20 01:34:30 -04:00
Hawkwood Glazier
6a62f99b50 [DO NOT MERGE] Correct large clock position
This corrects the large clock positioning error that was introduced with
Ia053aaec6987e00de980388a6c024d8bcf5203a2. It does this by rearranging
the layout slightly to get back to the same position. Of note:
 - Previously the margin for the large clock was computed dynamically
   and applied to the large clock frame from a static resource and
   dynamic value based on the font. Now the static portion is applied
   directly from the resource to the clock frame in the layout resource.
   The dynamic portion is applied to the AnimatableClockView directly
   instead of it's parent as before.
 - ChildClipping has been disabled on the parent view as the dynamic
   portion of this margin moves the AnimatableClockView outside of
   it's parent's bounds.
 - The margin that is now applied to the AnimatableClockView is
   scaled by 0.5 to account produce the ccorrect placement after
   center-aligning the view in it's parent. Before the full value
   was applied to the parent, creating an equivalent effect.

This also fixes the clock translation issue when the splitshade appears
and disappears. They were both fundamentally layout issues with the
refactored clock code.

This change was manually tested by flashing each device and comparing
the clock position in every configuration against a refenece image from
a dogfood build. Additionally the motion of the clock was validated
when the splitshade appears and disappears on a tablet in landscape.

Test: Manual validated screenshots from several devices against reference
images from a known good build. Additionally validated with a screenshot
test, although golden images had to be updated.

Bug: 229771520
Fixes: 241083568
Fixes: 241084042
Change-Id: I273c2996ff67c7b5f77c6bafb292d53275c7bc47
2022-08-31 22:27:06 +00:00
Hawkwood Glazier
843cd5ea89 [DO NOT MERGE] Revert "[DO NOT MERGE]Revert "Migrate KeyguardClockSwitch to new..."
Revert "[DO NOT MERGE]Revert "Expose the clock version of google..."

Revert "[DO NOT MERGE]Revert "Changes to SystemUIGoogle to suppo..."

Revert submission 19508951-revert-19451291-cherrypick-clock_migration-tvip0m638i-BKWSUCNJAV

Reason for revert: Double Revert w/ fixes
Reverted Changes:
Iccd8d2e19:[DO NOT MERGE]Revert "Add clock version of google-...
I432d3d814:[DO NOT MERGE]Revert "Migrate KeyguardClockSwitch ...
Ifd0aa59df:[DO NOT MERGE]Revert "Expose the clock version of ...
I9a6ca6349:[DO NOT MERGE]Revert "Changes to SystemUIGoogle to...

To minimize merge issues, this topic consists of just cherry-picks from
master. Fixes for bugs are provided as downstream commits and will be
merged back to master as those bugs exist there as well. The commits
in this topic weren't tested in isolation beyond automated testing.

Additionally, I've updated the ktfmt exclude list to include new files
from this cherry-pick instead of reformatting those files.

Test: Screenshot test and manually validated each downstream fix mostly by
comparing reference images from known good builds to test builds.

Change-Id: Iff1d0ee8c6d09c77185be1ca5bbbe1aa5870e0c7
2022-08-31 22:26:07 +00:00
Hawkwood Glazier
23535e29d1 [DO NOT MERGE]Revert "Migrate KeyguardClockSwitch to new shared Clock library"
Revert "Expose the clock version of google-sans"

Revert "Changes to SystemUIGoogle to support clock migration"

Revert submission 19451291-cherrypick-clock_migration-tvip0m638i

Reason for revert: b/241084042
Reverted Changes:
Ia053aaec6:Migrate KeyguardClockSwitch to new shared Clock li...
Ia3e067b93:Changes to SystemUIGoogle to support clock migrati...
I5dbf01a83:Add clock version of google-sans
Ia654d4f41:Expose the clock version of google-sans

Change-Id: I432d3d814c85b9ba20bbb7a88d2e52bd2337c10c
2022-08-03 15:22:58 +02:00
Hawkwood Glazier
a19e59d717 Migrate KeyguardClockSwitch to new shared Clock library
This change modifies the KeyguardClockSwitch and Controller
to get clocks from the ClockRegistry. Since the only clock
available from the registry is the default one, this should
have no user-facing changes, and is intended only to update
the relevant codepaths.

Bug: 229771520
Test: Manual and Automated
Change-Id: Ia053aaec6987e00de980388a6c024d8bcf5203a2
(cherry picked from commit c8b33ca43f)
Merged-In: Ia053aaec6987e00de980388a6c024d8bcf5203a2
2022-07-28 14:53:21 +00:00
Hawkwood Glazier
9158a60bce DefaultClockProvider implementation using AnimatableClockView
Bug: 229771520
Test: Automated
Change-Id: Iba6c81f8b469ef2d0a5bc38dd89454d75bfe8a43
(cherry picked from commit c742a9cb68)
Merged-In: Iba6c81f8b469ef2d0a5bc38dd89454d75bfe8a43
2022-07-28 00:51:26 +00:00
Hawkwood Glazier
8485dc1b85 Migrate AnimatableClockView to SystemUISharedLib
Bug: 229771520
Test: Automated
Change-Id: I93170c27d47017a81c4ef430823939fd0b9ec9c7
Merged-In: I93170c27d47017a81c4ef430823939fd0b9ec9c7
2022-07-26 15:51:05 +00:00
Nick Chameyev
d1d534031d Do not use shared lib resources
Temporary removes usages of SysUI shared
resources as it leads to crashes in Launcher
tests.

Bug: 204727471
Test: install launcher, try autorotate suggestion
Change-Id: I82dae0b2f5a9d2cb83f8a60e3c08353dc1bb60b6
2021-11-01 17:04:52 +00:00
Nick Chameyev
4309e6ec42 Move floating rotation button handling to Launcher
Moves handling of floating rotation button when navigation
bar is not created to the launcher. This button was not
showing when taskbar is visible as it was initialized in
navigation bar (which is not created for large screens).

Bug: 200103245
Test: rotate phone when autorotate disabled on inner screen
Test: showing rotate suggestion when gesture nav enabled/disabled
Change-Id: I0619acd9d24eb4ba36bdb601517f9a8370ee999a
Merged-In: I0619acd9d24eb4ba36bdb601517f9a8370ee999a
2021-10-29 16:19:39 +00:00