Josh Engebretson 8 жил өмнө
parent
commit
8ba2cc3a63

+ 7 - 0
Script/AtomicEditor/ui/Shortcuts.ts

@@ -206,6 +206,13 @@ class Shortcuts extends Atomic.ScriptObject {
 
             if (!Atomic.ui.focusedWidget && !this.cmdKeyDown()) {
 
+                if (ev.key == Atomic.KEY_ESCAPE) {
+
+                    if (Atomic.ui.consoleIsVisible) {
+                        Atomic.ui.showConsole(false);
+                    }
+                }
+
                 if (ev.key == Atomic.KEY_W) {
                     this.invokeGizmoEditModeChanged(Editor.EditMode.EDIT_MOVE);
                 } else if (ev.key == Atomic.KEY_E) {

+ 3 - 2
Source/Atomic/Resource/Image.cpp

@@ -38,11 +38,12 @@
 #include <libsquish/squish.h>
 #endif
 
-// ATOMIC END
-
 #include <STB/stb_image.h>
 #include <STB/stb_image_write.h>
 
+// ATOMIC END
+
+
 #include "../DebugNew.h"
 
 #ifndef MAKEFOURCC

+ 3 - 0
Source/Atomic/UI/UI.h

@@ -109,6 +109,9 @@ public:
     void ShowConsole(bool value);
     void ToggleConsole();
 
+    /// Get whether the console is currently visible
+    bool GetConsoleIsVisible() const { return consoleVisible_; }
+
     bool GetFocusedWidget();
 
     /// request exit on next frame