summaryrefslogtreecommitdiffstats
path: root/libs/hwui
diff options
context:
space:
mode:
authorChet Haase <chet@google.com>2012-05-01 10:05:13 -0700
committerChet Haase <chet@google.com>2012-05-01 10:05:13 -0700
commit6f9ad204cc529babeb3aa7c9a57cf00ed7188471 (patch)
treeebd4cc3f8f598ec8da1d778103fedf05dc3036d3 /libs/hwui
parent427db9b3d10d5c203d0351e683c3cddfd270250c (diff)
downloadframeworks_base-6f9ad204cc529babeb3aa7c9a57cf00ed7188471.zip
frameworks_base-6f9ad204cc529babeb3aa7c9a57cf00ed7188471.tar.gz
frameworks_base-6f9ad204cc529babeb3aa7c9a57cf00ed7188471.tar.bz2
Fix launcher invisibility bug
There was a bug in the DisplayList code for layers where we would set the alpha value for a layer only if the alpha were non-1. This works most of the time (since the value is usually 1 and doesn't need to be set at all, and if the value is non-1, it is set correctly). But when the value has been set to a non-1 value, setting alpha back to 1 cannot happen due to this logic. This caused launcher to have some invisible pages when returning to Home because those pages previously had an alpha value of 0, and setting the alpha to 1 had no effect due to this DisplayList code. The fix is to simply remove the check for non-1 values; we should always set the alpha value of layers to handle all cases. Issue #6413892 alpha value is messed up after AlphaAnimation Change-Id: Ia51acb2eaaf0609ea7189998ed449bdd9ea7e05f
Diffstat (limited to 'libs/hwui')
-rw-r--r--libs/hwui/DisplayListRenderer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/hwui/DisplayListRenderer.cpp b/libs/hwui/DisplayListRenderer.cpp
index 7e19932..92207b1 100644
--- a/libs/hwui/DisplayListRenderer.cpp
+++ b/libs/hwui/DisplayListRenderer.cpp
@@ -962,7 +962,7 @@ status_t DisplayList::replay(OpenGLRenderer& renderer, Rect& dirty, int32_t flag
float x = getFloat();
float y = getFloat();
SkPaint* paint = getPaint(renderer);
- if (mCaching && mMultipliedAlpha < 255) {
+ if (mCaching) {
paint->setAlpha(mMultipliedAlpha);
}
DISPLAY_LIST_LOGD("%s%s %p, %.2f, %.2f, %p", (char*) indent, OP_NAMES[op],
@@ -975,7 +975,7 @@ status_t DisplayList::replay(OpenGLRenderer& renderer, Rect& dirty, int32_t flag
float x = getFloat();
float y = getFloat();
SkPaint* paint = getPaint(renderer);
- if (mCaching && mMultipliedAlpha < 255) {
+ if (mCaching) {
paint->setAlpha(mMultipliedAlpha);
}
DISPLAY_LIST_LOGD("%s%s %p, %.2f, %.2f, %p", (char*) indent, OP_NAMES[op],