From 5ced9453d43ae4bf4689a432ba6a9ed577deabc7 Mon Sep 17 00:00:00 2001 From: Christopher Rothert Date: Mon, 25 Sep 2023 15:25:53 +0200 Subject: [PATCH] Fix editor window closing when using RMB + Ctrl + W for slow camera flight --- Source/Editor/Windows/EditorWindow.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Source/Editor/Windows/EditorWindow.cs b/Source/Editor/Windows/EditorWindow.cs index 60817a51b..ff0673c11 100644 --- a/Source/Editor/Windows/EditorWindow.cs +++ b/Source/Editor/Windows/EditorWindow.cs @@ -192,6 +192,13 @@ namespace FlaxEditor.Windows /// public override bool OnKeyDown(KeyboardKeys key) { + // Prevent closing the editor window when using RMB + Ctrl + W to slow down the camera flight + if (Editor.Options.Options.Input.CloseTab.Process(this, key)) + { + if (Root.GetMouseButton(MouseButton.Right)) + return true; + } + if (base.OnKeyDown(key)) return true;