Fix volume buttons in photo viewer
This commit is contained in:
parent
8ee4b7992a
commit
6f74315b7f
|
@ -1,3 +1,5 @@
|
||||||
/build
|
/build
|
||||||
/release
|
/release
|
||||||
/debug
|
/debug
|
||||||
|
*.apk
|
||||||
|
output-metadata.json
|
||||||
|
|
|
@ -62,11 +62,14 @@ public class PhotoViewer implements ZoomPanView.Listener{
|
||||||
windowView=new FrameLayout(activity){
|
windowView=new FrameLayout(activity){
|
||||||
@Override
|
@Override
|
||||||
public boolean dispatchKeyEvent(KeyEvent event){
|
public boolean dispatchKeyEvent(KeyEvent event){
|
||||||
if(event.getAction()==KeyEvent.ACTION_DOWN && event.getKeyCode()==KeyEvent.KEYCODE_BACK){
|
if(event.getKeyCode()==KeyEvent.KEYCODE_BACK){
|
||||||
|
if(event.getAction()==KeyEvent.ACTION_DOWN){
|
||||||
onStartSwipeToDismissTransition(0f);
|
onStartSwipeToDismissTransition(0f);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public WindowInsets dispatchApplyWindowInsets(WindowInsets insets){
|
public WindowInsets dispatchApplyWindowInsets(WindowInsets insets){
|
||||||
|
|
Loading…
Reference in New Issue