ui crate, editor

This commit is contained in:
2026-06-18 11:40:06 -05:00
parent fb8f6df501
commit 1351055d27
14 changed files with 2277 additions and 104 deletions
+4
View File
@@ -31,6 +31,8 @@ pub enum InputMode {
Editor,
/// A dialog overlay is open over the editor; all input drives the dialog.
Dialog,
/// The script code editor is open; all input drives the editor.
CodeEditor,
/// An animation is running and has not claimed any input mode; all input is discarded.
Ignore,
/// Reserved for a post-transition freeze; nothing currently produces this mode.
@@ -54,6 +56,8 @@ pub(crate) fn current_input_mode(mode: &Mode, ui: &Ui) -> InputMode {
Mode::Edit(ed) => {
if ed.dialog.is_some() {
InputMode::Dialog
} else if ed.code_editor.is_some() {
InputMode::CodeEditor
} else {
InputMode::Editor
}