mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-31 23:19:43 +07:00
Back button quitting
This commit is contained in:
@ -310,6 +310,10 @@ public class Control implements ApplicationListener{
|
||||
if(!state.isPaused()){
|
||||
Time.update();
|
||||
}
|
||||
|
||||
if(!scene.hasDialog() && Core.input.keyTap(KeyCode.BACK)){
|
||||
Platform.instance.hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -69,6 +69,9 @@ public abstract class Platform {
|
||||
*/
|
||||
public void showFileChooser(String text, String content, Consumer<FileHandle> cons, boolean open, String filetype){}
|
||||
|
||||
/**Hide the app. Android only.*/
|
||||
public void hide(){}
|
||||
|
||||
/**Forces the app into landscape mode. Currently Android only.*/
|
||||
public void beginForceLandscape(){}
|
||||
|
||||
|
Reference in New Issue
Block a user