自定义Dialog横向不满屏

2020-02-08  本文已影响0人  我想放假休息

https://blog.csdn.net/suyimin2010/article/details/92072940

方法一,新建style


<style name="dialog" parent="@android:style/Theme.Dialog">
        <item name="android:windowFrame">@null</item>
        <item name="android:windowIsFloating">true</item>
        <item name="android:windowIsTranslucent">false</item>
        <item name="android:windowNoTitle">true</item>
        <item name="android:windowBackground">@android:color/white</item>
        <item name="android:backgroundDimEnabled">true</item>
</style>

然后在 代码添加Style
在构造方法改成 super(context,R.style.dialog);

二、
/**

上一篇 下一篇

猜你喜欢

热点阅读