Clean up cacheColorHint to be better controlled by the theme.
Fixes generic lists in dialog themes, for example. Change-Id: I0ea1cae1641d8ab3756179ce80245ed0df942115
This commit is contained in:
@@ -2550,6 +2550,17 @@
|
|||||||
visibility="public"
|
visibility="public"
|
||||||
>
|
>
|
||||||
</field>
|
</field>
|
||||||
|
<field name="colorBackgroundCacheHint"
|
||||||
|
type="int"
|
||||||
|
transient="false"
|
||||||
|
volatile="false"
|
||||||
|
value="16843435"
|
||||||
|
static="true"
|
||||||
|
final="true"
|
||||||
|
deprecated="not deprecated"
|
||||||
|
visibility="public"
|
||||||
|
>
|
||||||
|
</field>
|
||||||
<field name="colorForeground"
|
<field name="colorForeground"
|
||||||
type="int"
|
type="int"
|
||||||
transient="false"
|
transient="false"
|
||||||
|
|||||||
@@ -28,6 +28,11 @@
|
|||||||
<attr name="colorForegroundInverse" format="color" />
|
<attr name="colorForegroundInverse" format="color" />
|
||||||
<!-- Color that matches (as closely as possible) the window background. -->
|
<!-- Color that matches (as closely as possible) the window background. -->
|
||||||
<attr name="colorBackground" format="color" />
|
<attr name="colorBackground" format="color" />
|
||||||
|
<!-- This is a hint for a solid color that can be used for caching
|
||||||
|
rendered views. This will be the color of the background when
|
||||||
|
there is a solid background color; it will be null when the
|
||||||
|
background is a texture or translucent. -->
|
||||||
|
<attr name="colorBackgroundCacheHint" format="color" />
|
||||||
<!-- Default disabled alpha for widgets that set enabled/disabled alpha programmatically. -->
|
<!-- Default disabled alpha for widgets that set enabled/disabled alpha programmatically. -->
|
||||||
<attr name="disabledAlpha" format="float" />
|
<attr name="disabledAlpha" format="float" />
|
||||||
<!-- Default background dim amount when a menu, dialog, or something similar pops up. -->
|
<!-- Default background dim amount when a menu, dialog, or something similar pops up. -->
|
||||||
|
|||||||
@@ -1175,6 +1175,7 @@
|
|||||||
<public type="attr" name="scrollbarFadeDuration" />
|
<public type="attr" name="scrollbarFadeDuration" />
|
||||||
<public type="attr" name="scrollbarDefaultDelayBeforeFade" />
|
<public type="attr" name="scrollbarDefaultDelayBeforeFade" />
|
||||||
<public type="attr" name="fadeScrollbars" />
|
<public type="attr" name="fadeScrollbars" />
|
||||||
|
<public type="attr" name="colorBackgroundCacheHint" />
|
||||||
|
|
||||||
<public type="style" name="Theme.Wallpaper" />
|
<public type="style" name="Theme.Wallpaper" />
|
||||||
<public type="style" name="Theme.Wallpaper.NoTitleBar" />
|
<public type="style" name="Theme.Wallpaper.NoTitleBar" />
|
||||||
|
|||||||
@@ -459,12 +459,13 @@
|
|||||||
|
|
||||||
<style name="Widget.ListView" parent="Widget.AbsListView">
|
<style name="Widget.ListView" parent="Widget.AbsListView">
|
||||||
<item name="android:listSelector">@android:drawable/list_selector_background</item>
|
<item name="android:listSelector">@android:drawable/list_selector_background</item>
|
||||||
<item name="android:cacheColorHint">?android:attr/colorBackground</item>
|
<item name="android:cacheColorHint">?android:attr/colorBackgroundCacheHint</item>
|
||||||
<item name="android:divider">@android:drawable/divider_horizontal_dark_opaque</item>
|
<item name="android:divider">@android:drawable/divider_horizontal_dark_opaque</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="Widget.ListView.White" parent="Widget.AbsListView">
|
<style name="Widget.ListView.White" parent="Widget.AbsListView">
|
||||||
<item name="android:listSelector">@android:drawable/list_selector_background</item>
|
<item name="android:listSelector">@android:drawable/list_selector_background</item>
|
||||||
|
<item name="android:cacheColorHint">?android:attr/colorBackgroundCacheHint</item>
|
||||||
<item name="android:divider">@android:drawable/divider_horizontal_bright_opaque</item>
|
<item name="android:divider">@android:drawable/divider_horizontal_bright_opaque</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
@@ -30,6 +30,7 @@
|
|||||||
<item name="colorForeground">@android:color/bright_foreground_dark</item>
|
<item name="colorForeground">@android:color/bright_foreground_dark</item>
|
||||||
<item name="colorForegroundInverse">@android:color/bright_foreground_dark_inverse</item>
|
<item name="colorForegroundInverse">@android:color/bright_foreground_dark_inverse</item>
|
||||||
<item name="colorBackground">@android:color/background_dark</item>
|
<item name="colorBackground">@android:color/background_dark</item>
|
||||||
|
<item name="colorBackgroundCacheHint">?android:attr/colorBackground</item>
|
||||||
<item name="disabledAlpha">0.5</item>
|
<item name="disabledAlpha">0.5</item>
|
||||||
<item name="backgroundDimAmount">0.6</item>
|
<item name="backgroundDimAmount">0.6</item>
|
||||||
|
|
||||||
@@ -289,6 +290,7 @@
|
|||||||
wallpaper appear behind them. -->
|
wallpaper appear behind them. -->
|
||||||
<style name="Theme.Wallpaper">
|
<style name="Theme.Wallpaper">
|
||||||
<item name="android:windowBackground">@android:color/transparent</item>
|
<item name="android:windowBackground">@android:color/transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowShowWallpaper">true</item>
|
<item name="android:windowShowWallpaper">true</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
@@ -308,6 +310,7 @@
|
|||||||
top of a dark background. -->
|
top of a dark background. -->
|
||||||
<style name="Theme.WallpaperSettings">
|
<style name="Theme.WallpaperSettings">
|
||||||
<item name="android:windowBackground">@android:drawable/screen_background_dark_transparent</item>
|
<item name="android:windowBackground">@android:drawable/screen_background_dark_transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowIsTranslucent">true</item>
|
<item name="android:windowIsTranslucent">true</item>
|
||||||
<item name="android:windowAnimationStyle">@android:style/Animation.Translucent</item>
|
<item name="android:windowAnimationStyle">@android:style/Animation.Translucent</item>
|
||||||
</style>
|
</style>
|
||||||
@@ -316,6 +319,7 @@
|
|||||||
top of a light background. -->
|
top of a light background. -->
|
||||||
<style name="Theme.Light.WallpaperSettings">
|
<style name="Theme.Light.WallpaperSettings">
|
||||||
<item name="android:windowBackground">@android:drawable/screen_background_light_transparent</item>
|
<item name="android:windowBackground">@android:drawable/screen_background_light_transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowIsTranslucent">true</item>
|
<item name="android:windowIsTranslucent">true</item>
|
||||||
<item name="android:windowAnimationStyle">@android:style/Animation.Translucent</item>
|
<item name="android:windowAnimationStyle">@android:style/Animation.Translucent</item>
|
||||||
</style>
|
</style>
|
||||||
@@ -335,6 +339,7 @@
|
|||||||
flag and appropriate animations for your windows. -->
|
flag and appropriate animations for your windows. -->
|
||||||
<style name="Theme.Translucent">
|
<style name="Theme.Translucent">
|
||||||
<item name="android:windowBackground">@android:color/transparent</item>
|
<item name="android:windowBackground">@android:color/transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowIsTranslucent">true</item>
|
<item name="android:windowIsTranslucent">true</item>
|
||||||
<!-- Note that we use the base animation style here (that is no
|
<!-- Note that we use the base animation style here (that is no
|
||||||
animations) because we really have no idea how this kind of
|
animations) because we really have no idea how this kind of
|
||||||
@@ -379,6 +384,8 @@
|
|||||||
<item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item>
|
<item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item>
|
||||||
<item name="android:windowSoftInputMode">stateUnspecified|adjustPan</item>
|
<item name="android:windowSoftInputMode">stateUnspecified|adjustPan</item>
|
||||||
|
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
|
|
||||||
<item name="textAppearance">@android:style/TextAppearance</item>
|
<item name="textAppearance">@android:style/TextAppearance</item>
|
||||||
<item name="textAppearanceInverse">@android:style/TextAppearance.Inverse</item>
|
<item name="textAppearanceInverse">@android:style/TextAppearance.Inverse</item>
|
||||||
|
|
||||||
@@ -422,6 +429,7 @@
|
|||||||
background, and turns off dimming behind the window. -->
|
background, and turns off dimming behind the window. -->
|
||||||
<style name="Theme.Panel">
|
<style name="Theme.Panel">
|
||||||
<item name="android:windowBackground">@android:color/transparent</item>
|
<item name="android:windowBackground">@android:color/transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowFrame">@null</item>
|
<item name="android:windowFrame">@null</item>
|
||||||
<item name="android:windowContentOverlay">@null</item>
|
<item name="android:windowContentOverlay">@null</item>
|
||||||
<item name="android:windowIsFloating">true</item>
|
<item name="android:windowIsFloating">true</item>
|
||||||
@@ -436,6 +444,7 @@
|
|||||||
background, and turns off dimming behind the window. -->
|
background, and turns off dimming behind the window. -->
|
||||||
<style name="Theme.Light.Panel">
|
<style name="Theme.Light.Panel">
|
||||||
<item name="android:windowBackground">@android:color/transparent</item>
|
<item name="android:windowBackground">@android:color/transparent</item>
|
||||||
|
<item name="android:colorBackgroundCacheHint">@null</item>
|
||||||
<item name="android:windowFrame">@null</item>
|
<item name="android:windowFrame">@null</item>
|
||||||
<item name="android:windowContentOverlay">@null</item>
|
<item name="android:windowContentOverlay">@null</item>
|
||||||
<item name="android:windowIsFloating">true</item>
|
<item name="android:windowIsFloating">true</item>
|
||||||
|
|||||||
Reference in New Issue
Block a user