summaryrefslogtreecommitdiffstats
path: root/core/java
diff options
context:
space:
mode:
authorRomain Guy <romainguy@android.com>2009-05-12 10:54:51 -0700
committerRomain Guy <romainguy@android.com>2009-05-12 10:54:51 -0700
commit83b2107c4d2f07f46b6ae663115421749486f8b1 (patch)
treef7a5d08afc5933d98f5f70adc744184452e5d240 /core/java
parent08f3b5261fc31813e35cf04225ed8260f8a3bbe0 (diff)
downloadframeworks_base-83b2107c4d2f07f46b6ae663115421749486f8b1.zip
frameworks_base-83b2107c4d2f07f46b6ae663115421749486f8b1.tar.gz
frameworks_base-83b2107c4d2f07f46b6ae663115421749486f8b1.tar.bz2
Fixes #1846038. DrawableContainer was wrongly returning its opacity by ignoring the visibility of the currently selected layer. This change simply reports a TRANSPARENT opacity if there is no currently selected layer of if the selected layer is not visible. Otherwise it reports the opacity computed by the state class.
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/view/View.java1
-rw-r--r--core/java/android/widget/RelativeLayout.java2
2 files changed, 2 insertions, 1 deletions
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index 410adb0..335b43c 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -4556,6 +4556,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback {
*
* @hide Pending API council approval
*/
+ @ViewDebug.ExportedProperty
public boolean isOpaque() {
return mBGDrawable != null && mBGDrawable.getOpacity() == PixelFormat.OPAQUE;
}
diff --git a/core/java/android/widget/RelativeLayout.java b/core/java/android/widget/RelativeLayout.java
index c4f0abd..edbb3db 100644
--- a/core/java/android/widget/RelativeLayout.java
+++ b/core/java/android/widget/RelativeLayout.java
@@ -823,7 +823,7 @@ public class RelativeLayout extends ViewGroup {
@ViewDebug.IntToString(from = RIGHT_OF, to = "rightOf")
}, mapping = {
@ViewDebug.IntToString(from = TRUE, to = "true"),
- @ViewDebug.IntToString(from = 0, to = "NO_ID")
+ @ViewDebug.IntToString(from = 0, to = "FALSE/NO_ID")
})
private int[] mRules = new int[VERB_COUNT];