History log of /packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
0ecf5bcfcb329728231c2289f0ade8a0830860a9 09-Jun-2017 Tony Wickham <twickham@google.com> resolve merge conflicts of 7092db024 to ub-launcher3-dorval-polish

Test: I solemnly swear I tested this conflict resolution.x
Change-Id: I0f9ed3d42fcb04299c3c23d06629f855614c0538
7092db02410562026da17a7b38f48025cc847de2 07-Jun-2017 Tony Wickham <twickham@google.com> Add support for color extracted notification dots

Changing the badge_color in colors.xml to transparent
will cause them to be color extracted.

When an extracted color is used in the IconPalette, we
desaturate the background. Otherwise we respect the
exact color specified in colors.xml.

Change-Id: Ie82d0c5335fa5f24d4cc47766e4c1719c4916f8b
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
47ab9b1fc5a8625bc714a1def91374d762927877 07-Jun-2017 Tony Wickham <twickham@google.com> Generalize findContrastColor() to work for dark backgrounds

Previously it assumed the background was lighter than the foreground.

Bug: 62380473
Change-Id: Icd53750a2f9181890c8b9c62721d07946e115e99
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
e6a790e5ae98ecfd754638a9ff5e87ee45aad069 16-May-2017 Tony Wickham <twickham@google.com> Use a single color for all icon badges.

Bug: 38346375
Change-Id: I26b7ad3dcfea6a18e169d656e19605c9794eadd3
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
f77a6f7fd75243999912d040470a543e825d6d12 27-Apr-2017 Tony Wickham <twickham@google.com> Re-enable badges, with all dots

Also updated folder badge (dot) color to light gray,
added notification header back (with same number as
before, where each notification counts as >= 1),
and increased shadow opacity for the dots.

Change-Id: I53a3e0d94f23f482b55b3c10a922939ebb381314
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
0530e8c60809afa92b1aa907376f0553ad94d58f 27-Apr-2017 Tony Wickham <twickham@google.com> Support notifications with 0 count (show as dots)

- Show number if number > 0
- Show icon if number == 0 and a notification specified an icon to show
- Show a dot otherwise
- In cases of multiple notifications, stack a second badge behind the
first (visuals will be updated in future CL, as well as support
stacked dots)
- Folders always show dot if any app within has a badge.

Change-Id: I0a89059b0e0a0d174fe739c9da4f75fa18c0edfa
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
1237df0a7cb89570b90b30fa30a3c76417ce3b64 24-Feb-2017 Tony Wickham <twickham@google.com> Update icon badges to match spec

- Size defined as percentage of app icon size
- Width changes when there are 2 or 3 digits (round rect)
- Offset slightly away from the app icon
- Had to move drawing to BubbleTextView instead of
FastBitmapDrawable
- Hide badge when dragging and while popup is open
- Tweaks for some color/text parameters

Bug: 35744066
Change-Id: Ibb15ca634abaa0729aea637c904c4c6889a58c7c
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
6c82867a7ea3a95a19d6cec7d1fe164d234d2cb6 27-Feb-2017 Tony Wickham <twickham@google.com> Add shadow to badges

- Add static method to ShadowGenerator to generate a
circle Bitmap with a shadow.
- Move setColorScale() from DragView to Themes, and
use it to apply color to the shadowed Bitmap.

Bug: 35744066
Change-Id: I8d1da528bbf94dc83851f0b4016361ed9f8d5349
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
1f3f07d47c29cba3b70bcd15ebb65a077f55a558 11-Feb-2017 Sunny Goyal <sunnygoyal@google.com> Simplifying some launcher themes

> Replacing some colors with theme attributes
> Simplifying styles definition by removing unnecessary inheritance and inlining some definitions

Change-Id: Ifa167515cae6a7fd3720f1a52ff9ce11abb4495f
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
11ba507eab83f591b924ae42d42fa47073b78917 02-Feb-2017 Tony Wickham <twickham@google.com> Add badges to folders

- The folder badge contains the sum of the badge counts within.
- This is represented by FolderBadgeInfo, a subclass of BadgeInfo.

Bug: 34828806
Bug: 32410600
Change-Id: I977a69cc7baf80a7207af9adf98dddb0a3509c47
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
96ac68a481ce5b794b5227e09ace7c30d6dd5e7b 03-Feb-2017 Sunny Goyal <sunnygoyal@google.com> Updating the PreloadIconDrawable

> The drawable gets the path from MaskIconDrawable path, instead of
using a circle
> The progress changes are animated as well

Bug: 34831873
Change-Id: I4e7f0b610f4fd94de8e0cfcf8b179b775cf0b4d8
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
f79877c04c071b7ae1618395f0a1dce134fec36e 27-Jan-2017 Tony Wickham <twickham@google.com> Ensure notification icons have enough contrast with background.

This uses the same color calculations as the system, except that
we use the extracted notification background instead of assuming
it is white.

Bug: 32410600
Change-Id: I7be8b9459ca38d01a6780758898541e69ec42576
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
9438ed414fdabadb4cd09da184867b1c44b91095 20-Jan-2017 Tony Wickham <twickham@google.com> Add swipe-to-dismiss notifications in popup menu.

- Next secondary icon animates up to replace dismissed main notification
- Add padding around main notification so it always aligns with the
straight edges of the view (not the rounded corners); looks more
dismissable
- Notification view collapses as notifications are dismissed
- To mimic system notification behavior, we copy SwipeHelper,
FlingAnimationUtils, and Interpolators. We also apply elevation
to notifications and reveal a darker color beneath when dismissing.

Bug: 32410600
Change-Id: I9fbf10e73bb4996f17ef061c856efb013967d972
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java
9a8d11f930ced4c2706db150b7bbbb21330bd68d 11-Jan-2017 Tony Wickham <twickham@google.com> FastBitmapDrawable can draw an icon badge (notification count)

- Added BadgeInfo to contain data to be shown in a badge
(currently just notification count).
- Added BadgeRenderer in DeviceProfile to contain things
relevant to drawing the badge, such as size and Paint's.
- Added IconPalette to compute colors for the badge based
on a dominant color (will also be used for notifications)
- FastBitmapDrawable uses these classes to draw the badge.

Bug: 32410600
Change-Id: I6595a4879943357590f7d20c22594691a573ecaf
/packages/apps/Launcher3/src/com/android/launcher3/graphics/IconPalette.java