fix #52, allow using the volume buttons as shutter

This commit is contained in:
tibbi 2017-05-07 12:25:42 +02:00
parent 62ab418c86
commit 605a2a96f0
1 changed files with 3 additions and 0 deletions

View File

@ -73,6 +73,9 @@ class MainActivity : SimpleActivity(), PreviewListener, PhotoProcessor.MediaSave
mIsHardwareShutterHandled = true mIsHardwareShutterHandled = true
shutterPressed() shutterPressed()
true true
} else if (config.volumeButtonsAsShutter && (keyCode == KeyEvent.KEYCODE_VOLUME_DOWN || keyCode == KeyEvent.KEYCODE_VOLUME_UP)) {
shutterPressed()
true
} else { } else {
super.onKeyDown(keyCode, event) super.onKeyDown(keyCode, event)
} }