Add a new option when entering play mode to always restore to the editor window after exiting play mode. Also made it the default option on new projects.
This commit is contained in:
@@ -287,6 +287,7 @@ namespace FlaxEditor.Modules
|
||||
case Options.InterfaceOptions.PlayModeFocus.None: break;
|
||||
|
||||
case Options.InterfaceOptions.PlayModeFocus.GameWindow:
|
||||
case Options.InterfaceOptions.PlayModeFocus.GameWindowThenRestoreEditor:
|
||||
gameWin.FocusGameViewport();
|
||||
break;
|
||||
|
||||
@@ -320,6 +321,11 @@ namespace FlaxEditor.Modules
|
||||
_previousWindow.Focus();
|
||||
}
|
||||
break;
|
||||
case Options.InterfaceOptions.PlayModeFocus.GameWindowThenRestoreEditor:
|
||||
var editorWin = Editor.Windows.EditWin;
|
||||
if (editorWin != null && !editorWin.IsDisposing)
|
||||
editorWin.Focus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user