mirror of
https://github.com/2009scape/2009Scape-mobile.git
synced 2025-12-19 21:10:11 -07:00
Set a lower priority for the mouseGrab thread.
This commit is contained in:
parent
af1f0d678b
commit
2d818e8786
1 changed files with 4 additions and 3 deletions
|
|
@ -213,7 +213,7 @@ public class BaseMainActivity extends LoggableActivity {
|
||||||
this.drawerLayout.closeDrawers();
|
this.drawerLayout.closeDrawers();
|
||||||
|
|
||||||
placeMouseAt(CallbackBridge.physicalWidth / 2, CallbackBridge.physicalHeight / 2);
|
placeMouseAt(CallbackBridge.physicalWidth / 2, CallbackBridge.physicalHeight / 2);
|
||||||
new Thread(() -> {
|
Thread virtualMouseGrabThread = new Thread(() -> {
|
||||||
while (!isExited) {
|
while (!isExited) {
|
||||||
if (lastGrab != CallbackBridge.isGrabbing())
|
if (lastGrab != CallbackBridge.isGrabbing())
|
||||||
mousePointer.post(() -> {
|
mousePointer.post(() -> {
|
||||||
|
|
@ -230,8 +230,9 @@ public class BaseMainActivity extends LoggableActivity {
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
}, "VirtualMouseGrabThread").start();
|
}, "VirtualMouseGrabThread");
|
||||||
|
virtualMouseGrabThread.setPriority(Thread.MIN_PRIORITY);
|
||||||
|
virtualMouseGrabThread.start();
|
||||||
|
|
||||||
if (isAndroid8OrHigher()) {
|
if (isAndroid8OrHigher()) {
|
||||||
touchPad.setDefaultFocusHighlightEnabled(false);
|
touchPad.setDefaultFocusHighlightEnabled(false);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue