Skip to content

Commit

Permalink
fix: pauseKeymap() freezes input
Browse files Browse the repository at this point in the history
disabling it for now
  • Loading branch information
Xtr126 committed Feb 15, 2024
1 parent f145638 commit d0798cb
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
5 changes: 2 additions & 3 deletions app/src/main/java/xtr/keymapper/editor/EditorActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
import xtr.keymapper.TouchPointer;
import xtr.keymapper.profiles.ProfileSelector;
import xtr.keymapper.server.RemoteService;
import xtr.keymapper.server.RemoteServiceHelper;

public class EditorActivity extends Activity implements EditorUI.OnHideListener {
private EditorUI editor;
Expand All @@ -35,8 +34,8 @@ public void onCreate(Bundle savedInstanceState) {
WindowInsetsControllerCompat windowInsetsController = WindowCompat.getInsetsController(getWindow(), getWindow().getDecorView());
windowInsetsController.setSystemBarsBehavior(WindowInsetsControllerCompat.BEHAVIOR_SHOW_TRANSIENT_BARS_BY_SWIPE);
windowInsetsController.hide(WindowInsetsCompat.Type.systemBars());
// RemoteServiceHelper.pauseKeymap();
mService = RemoteService.getInstance();
RemoteServiceHelper.pauseKeymap();

if (editor != null) editor.hideView();
bindService(new Intent(this, TouchPointer.class), connection, Context.BIND_AUTO_CREATE);
Expand Down Expand Up @@ -101,7 +100,7 @@ protected void onDestroy() {
} catch (RemoteException ignored) {
}
editor = null;
RemoteServiceHelper.resumeKeymap();
// RemoteServiceHelper.resumeKeymap();
}

@Override
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/xtr/keymapper/server/InputService.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public class InputService implements IInputInterface {
private final KeyEventHandler keyEventHandler;
private KeymapConfig keymapConfig;
private KeymapProfile keymapProfile;
private static final Input input = new Input();
private final Input input = new Input();
public static final int UP = 0, DOWN = 1, MOVE = 2;
private final IRemoteServiceCallback mCallback;
final int supportsUinput;
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/xtr/keymapper/touchpointer/PidProvider.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

public final class PidProvider {
private final SimpleArrayMap<String, Integer> pidList = new SimpleArrayMap<>();

public Integer getPid(String keycode) {
// returns pointerIds on demand
public Integer getPid(String keycode) {
if (!pidList.containsKey(keycode))
pidList.put(keycode, pidList.size());
return pidList.get(keycode);
Expand Down

0 comments on commit d0798cb

Please sign in to comment.