mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-13 13:04:03 +00:00
Allow for closing screenshot dialog with same key
This commit is contained in:
parent
3f01c131c3
commit
3eddf88fd3
@ -79,6 +79,12 @@ export class HUDScreenshotExporter extends BaseHUDPart {
|
||||
buttons: ["cancel:good", "ok:bad"],
|
||||
});
|
||||
|
||||
dialog.inputReciever.keydown.add(({ keyCode }) => {
|
||||
if (keyCode === KEYMAPPINGS.ingame.exportScreenshot.keyCode) {
|
||||
this.root.hud.parts.dialogs.closeDialog(dialog);
|
||||
}
|
||||
});
|
||||
|
||||
this.root.hud.parts.dialogs.internalShowDialog(dialog);
|
||||
dialog.buttonSignals.ok.add(
|
||||
() => this.doExport(qualityInput.getValue(), overlayInput.getValue(), layerInput.getValue()),
|
||||
|
Loading…
Reference in New Issue
Block a user