am 0f1b4f46: am e58c9578: Merge "Make panel menu windows respect elevation" into lmp-dev
* commit '0f1b4f46f32d9a49c2023ee5c6a4ca6a7b4ee7ef': Make panel menu windows respect elevation
This commit is contained in:
@@ -978,6 +978,7 @@ please see themes_device_defaults.xml.
|
||||
<item name="listViewStyle">@style/Widget.Material.ListView</item>
|
||||
<item name="windowAnimationStyle">@style/Animation.DropDownUp</item>
|
||||
<item name="background">@null</item>
|
||||
<item name="windowElevation">@dimen/floating_window_z</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.Material.Light.CompactMenu">
|
||||
@@ -986,6 +987,7 @@ please see themes_device_defaults.xml.
|
||||
<item name="listViewStyle">@style/Widget.Material.Light.ListView</item>
|
||||
<item name="windowAnimationStyle">@style/Animation.DropDownUp</item>
|
||||
<item name="background">@null</item>
|
||||
<item name="windowElevation">@dimen/floating_window_z</item>
|
||||
</style>
|
||||
|
||||
<!-- Dialog themes for Material -->
|
||||
|
||||
@@ -1241,6 +1241,13 @@ public class PhoneWindow extends Window implements MenuBuilder.Callback {
|
||||
st.decorView = new DecorView(getContext(), st.featureId);
|
||||
st.gravity = Gravity.CENTER | Gravity.BOTTOM;
|
||||
st.setStyle(getContext());
|
||||
TypedArray a = getContext().obtainStyledAttributes(null,
|
||||
R.styleable.Window, 0, st.listPresenterTheme);
|
||||
final float elevation = a.getDimension(R.styleable.Window_windowElevation, 0);
|
||||
if (elevation != 0) {
|
||||
st.decorView.setElevation(elevation);
|
||||
}
|
||||
a.recycle();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user