mirror of
https://github.com/ClassiCube/ClassiCube.git
synced 2025-01-22 09:01:57 -05:00
Android: Don't prevent physical volume buttons from working (Thanks 123DMWM)
This commit is contained in:
parent
89214706fb
commit
53e34eec26
1 changed files with 5 additions and 0 deletions
|
@ -205,6 +205,11 @@ public class MainActivity extends Activity implements SurfaceHolder.Callback2 {
|
|||
}
|
||||
|
||||
public boolean onKeyDown(int keyCode, KeyEvent event) {
|
||||
// Ignore volume keys
|
||||
if (keyCode == KeyEvent.KEYCODE_VOLUME_DOWN) return false;
|
||||
if (keyCode == KeyEvent.KEYCODE_VOLUME_MUTE) return false;
|
||||
if (keyCode == KeyEvent.KEYCODE_VOLUME_UP) return false;
|
||||
|
||||
// TODO: not always handle (use Window_MapKey)
|
||||
pushCmd(CMD_KEY_DOWN, keyCode);
|
||||
|
||||
|
|
Loading…
Reference in a new issue