From 67d4bd484ad062e372c6c67fb49a848027cc708a Mon Sep 17 00:00:00 2001 From: Ishan09811 <156402647+Ishan09811@users.noreply.github.com> Date: Sun, 8 Dec 2024 17:09:31 +0530 Subject: [PATCH] Android: Fix device volume not working (#663) --- .../src/main/java/com/panda3ds/pandroid/app/GameActivity.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/GameActivity.java b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/GameActivity.java index 503684ac..c6764d38 100644 --- a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/GameActivity.java +++ b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/GameActivity.java @@ -152,6 +152,10 @@ public class GameActivity extends BaseActivity implements EmulatorCallback, Sens @Override public boolean dispatchKeyEvent(KeyEvent event) { + if (event.getKeyCode() == KeyEvent.KEYCODE_VOLUME_UP || event.getKeyCode() == KeyEvent.KEYCODE_VOLUME_DOWN) { + return super.dispatchKeyEvent(event); + } + if ((!drawerFragment.isOpened()) && InputHandler.processKeyEvent(event)) { return true; }