Skip to content

Commit a8a6584

Browse files
committed
更改快捷菜单背景遮罩覆盖状态栏,解决显示隐藏状态栏悬浮球上下移动的问题
1 parent 4302483 commit a8a6584

File tree

4 files changed

+10
-11
lines changed

4 files changed

+10
-11
lines changed

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ android {
1010
minSdkVersion 18
1111
targetSdkVersion 25
1212
resValue "string", "tray__authority", "${applicationId}.tray"
13-
versionCode 16
14-
versionName "1.4.2"
13+
versionCode 17
14+
versionName "1.4.3"
1515
}
1616

1717
signingConfigs {

app/src/main/java/com/hardwork/fg607/relaxfinger/SettingActivity.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ public void developerInfo() {
433433
TextView textView = new TextView(this);
434434
textView.setTextSize(16);
435435
textView.setTextColor(Color.BLACK);
436-
textView.setText("版本:v1.4.2\r\n作者:fg607\r\n邮箱:[email protected]");
436+
textView.setText("版本:v1.4.3\r\n作者:fg607\r\n邮箱:[email protected]");
437437
TextView url = new TextView(this);
438438
url.setTextSize(16);
439439
url.setTextColor(Color.BLACK);
@@ -470,11 +470,11 @@ public void questionsAnswer() {
470470
public void showUpdateInfo() {
471471

472472
AlertDialog dialog = new AlertDialog.Builder(this).create();
473-
dialog.setTitle("悬浮助手-1.4.2版本更新内容");
473+
dialog.setTitle("悬浮助手-1.4.3版本更新内容");
474474
dialog.setCancelable(true);
475475
dialog.setCanceledOnTouchOutside(true);
476-
dialog.setMessage("1.默认输入法遮挡悬浮球(解决不能避让的问题)\r\n" +
477-
"2.修复切换某些APP会重新打开APP的问题。");
476+
dialog.setMessage("1.更改快捷菜单背景遮罩覆盖状态栏和导航栏\r\n" +
477+
"2.解决全屏切换隐藏显示状态栏时悬浮球会上下移动的问题。");
478478
dialog.show();
479479

480480
}

app/src/main/java/com/hardwork/fg607/relaxfinger/service/FloatingBallService.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1207,7 +1207,7 @@ public void onAnimationRepeat(Animation animation) {
12071207

12081208
mMenuWmParams.type = WindowManager.LayoutParams.TYPE_TOAST;
12091209
}
1210-
mMenuWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE;//| WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM
1210+
mMenuWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE | WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN;
12111211
mMenuWmParams.gravity = Gravity.LEFT | Gravity.TOP;
12121212

12131213

@@ -1223,7 +1223,7 @@ private void initPopBackground() {
12231223

12241224
mPopBackWmParams.type = WindowManager.LayoutParams.TYPE_PHONE;
12251225

1226-
mPopBackWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE;//| WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM
1226+
mPopBackWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE | WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN;
12271227
mPopBackWmParams.gravity = Gravity.LEFT | Gravity.TOP;
12281228

12291229
//mPopBackWmParams.alpha=0.3f;
@@ -1469,7 +1469,8 @@ public void createFloatBallView() {
14691469

14701470
mBallWmParams.type = WindowManager.LayoutParams.TYPE_PHONE;
14711471

1472-
mBallWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE | WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM;
1472+
mBallWmParams.flags |= WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE
1473+
| WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM | WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN;
14731474
mBallWmParams.gravity = Gravity.LEFT | Gravity.TOP;
14741475

14751476
mBallWmParams.x = mPreferences.getInt("ballWmParamsX", FloatingBallUtils.getScreenWidth() - floatBallSize / 2 - DensityUtil.dip2px(MyApplication.getApplication(), 40));

app/src/main/java/com/hardwork/fg607/relaxfinger/utils/AppUtils.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,6 @@ public static boolean startApplication(String packageName) throws ActivityNotFou
170170
PackageManager pm = context.getPackageManager();
171171
Intent intent = pm.getLaunchIntentForPackage(packageName);
172172

173-
174-
175173
if (intent != null) {
176174

177175
String className = intent.getComponent().getClassName();

0 commit comments

Comments
 (0)