Skip to content

Commit 12da2c5

Browse files
Jim MillerAndroid (Google) Code Review
authored andcommitted
Merge "Fix 6665117: ACTION_ASSIST visual improvements" into jb-dev
2 parents c494727 + 20039ad commit 12da2c5

File tree

21 files changed

+37
-30
lines changed

21 files changed

+37
-30
lines changed

core/java/com/android/internal/widget/multiwaveview/PointCloud.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,8 @@ public int getAlphaForPoint(Point point) {
180180
float glowDistance = hypot(glowManager.x - point.x, glowManager.y - point.y);
181181
float glowAlpha = 0.0f;
182182
if (glowDistance < glowManager.radius) {
183-
float cosf = FloatMath.cos(PI * 0.5f * glowDistance / glowManager.radius);
184-
glowAlpha = glowManager.alpha * max(0.0f, (float) Math.pow(cosf, 0.5f));
183+
float cosf = FloatMath.cos(PI * 0.25f * glowDistance / glowManager.radius);
184+
glowAlpha = glowManager.alpha * max(0.0f, (float) Math.pow(cosf, 10.0f));
185185
}
186186

187187
// Compute contribution from Wave
@@ -190,7 +190,7 @@ public int getAlphaForPoint(Point point) {
190190
float waveAlpha = 0.0f;
191191
if (distanceToWaveRing < waveManager.width * 0.5f) {
192192
float cosf = FloatMath.cos(PI * 0.5f * distanceToWaveRing / waveManager.width);
193-
waveAlpha = waveManager.alpha * max(0.0f, (float) Math.pow(cosf, 15.0f));
193+
waveAlpha = waveManager.alpha * max(0.0f, (float) Math.pow(cosf, 20.0f));
194194
}
195195

196196
return (int) (max(glowAlpha, waveAlpha) * 255);
21.7 KB
Loading
9.42 KB
Loading
2.4 KB
Loading
11.2 KB
Loading
5.67 KB
Loading
1.56 KB
Loading
13.6 KB
Loading
3.15 KB
Loading

core/res/res/drawable/ic_lockscreen_search.xml renamed to core/res/res/drawable/ic_action_assist_generic.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,18 @@
1919
android:state_enabled="true"
2020
android:state_active="false"
2121
android:state_focused="false"
22-
android:drawable="@drawable/ic_lockscreen_google_normal" />
22+
android:drawable="@drawable/ic_action_assist_generic_normal" />
2323

2424
<item
2525
android:state_enabled="true"
2626
android:state_active="true"
2727
android:state_focused="false"
28-
android:drawable="@drawable/ic_lockscreen_google_activated" />
28+
android:drawable="@drawable/ic_action_assist_generic_activated" />
2929

3030
<item
3131
android:state_enabled="true"
3232
android:state_active="false"
3333
android:state_focused="true"
34-
android:drawable="@drawable/ic_lockscreen_google_focused" />
34+
android:drawable="@drawable/ic_action_assist_generic_activated" />
3535

3636
</selector>

0 commit comments

Comments
 (0)