Skip to content

Commit

Permalink
修复bug
Browse files Browse the repository at this point in the history
  • Loading branch information
cjyyx committed Jul 14, 2023
1 parent 862bb68 commit ca04a86
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 8 deletions.
Binary file modified app/release/app-release.apk
Binary file not shown.
4 changes: 2 additions & 2 deletions app/release/output-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"type": "SINGLE",
"filters": [],
"attributes": [],
"versionCode": 2,
"versionName": "1.1",
"versionCode": 3,
"versionName": "1.2",
"outputFile": "app-release.apk"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public FilterViewManager(Context c) {

layoutParams.type = WindowManager.LayoutParams.TYPE_ACCESSIBILITY_OVERLAY;
// width 和 height 尽可能大,从而覆盖屏幕
layoutParams.width = 1800;
layoutParams.width = 3200;
layoutParams.height = 3200;
layoutParams.format = PixelFormat.TRANSLUCENT;
layoutParams.flags = WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE |
Expand Down
3 changes: 1 addition & 2 deletions app/src/main/java/com/cjyyxn/screenfilter/GlobalStatus.java
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,6 @@ public static void setBrightness(float brightness) {
* 触发屏幕截图
* 先模拟上划操作,从而上拉任务栏
* 延时后打开系统截图服务
* 可能需要 500 ms
*/
public static void triggerScreenCap() {
if (appAccessibilityService != null) {
Expand Down Expand Up @@ -361,7 +360,7 @@ public void onCompleted(GestureDescription gestureDescription) {
new Handler(Looper.getMainLooper()).postDelayed(() -> {
Log.d("ccjy", "开启系统截图服务");
appAccessibilityService.performGlobalAction(GLOBAL_ACTION_TAKE_SCREENSHOT);
}, 200);
}, 500);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ public void run() {
}
}
};
// 每隔 0.1秒钟执行一次任务
new Timer().schedule(task, 0, 1000);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ public void run() {
}
}
};
// 每隔 0.1秒钟执行一次任务
new Timer().schedule(task, 0, 1000);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public void onClick() {
GlobalStatus.triggerScreenCap();
new Handler(Looper.getMainLooper()).postDelayed(() -> {
GlobalStatus.setTempControlMode(false);
}, 800);
}, 1300);
}, 400);
}
}

0 comments on commit ca04a86

Please sign in to comment.