Skip to content

Commit 20ce19a

Browse files
committed
修复android弹窗模式下透明度问题。
1 parent 9177d4e commit 20ce19a

File tree

3 files changed

+21
-10
lines changed

3 files changed

+21
-10
lines changed

android/src/main/AndroidManifest.xml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,11 @@
1717
<uses-permission android:name="android.permission.WAKE_LOCK" />
1818

1919
<application>
20-
<!-- since 2.0.0 optional 可选项,使用一键登录功能必须添加 -->
21-
<!-- since 2.1.1 optional 可选项,通过screenOrientation设置授权页面横竖屏展示 -->
22-
<activity
23-
android:name="com.cmic.sso.sdk.activity.OAuthActivity"
24-
android:configChanges="orientation|keyboardHidden|screenSize"
25-
android:screenOrientation="portrait"
26-
android:launchMode="singleTop">
27-
</activity>
2820
<!-- since 2.0.0 optional 可选项,使用一键登录功能必须添加 -->
2921
<!-- since 2.1.1 optional 可选项,通过screenOrientation设置授权页面横竖屏展示 -->
3022
<activity
3123
android:name="com.cmic.sso.sdk.activity.LoginAuthActivity"
32-
android:theme="@android:style/Theme.Holo.NoActionBar"
24+
android:theme="@style/ActivityDialogStyle"
3325
android:configChanges="orientation|keyboardHidden|screenSize"
3426
android:screenOrientation="portrait"
3527
android:launchMode="singleTop">
@@ -38,7 +30,7 @@
3830
<!-- since 2.1.1 optional 可选项,通过screenOrientation设置授权页面横竖屏展示 -->
3931
<activity android:name="cn.jiguang.verifysdk.CtLoginActivity"
4032
android:configChanges="orientation|keyboardHidden|screenSize"
41-
android:theme="@android:style/Theme.Holo.NoActionBar"
33+
android:theme="@style/ActivityDialogStyle"
4234
android:screenOrientation="portrait"
4335
android:launchMode="singleTop">
4436
</activity>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<shape xmlns:android="http://schemas.android.com/apk/res/android">
3+
<corners android:radius="5dp"/>
4+
</shape>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<resources>
3+
<style name="ActivityDialogStyle" >
4+
<!--去掉action bar和标题栏-->
5+
<item name="android:windowActionBar">false</item>
6+
<item name="android:windowNoTitle">true</item>
7+
<!--背景透明-->
8+
<item name="android:windowIsTranslucent">true</item>
9+
<!--dialog圆角-->
10+
<item name="android:windowBackground">@drawable/dialog_bg</item>
11+
12+
<!--弹窗后整个屏幕的背景是否有遮障层,默认是半透明的-->
13+
<item name="android:backgroundDimEnabled">true</item>
14+
</style>
15+
</resources>

0 commit comments

Comments
 (0)