Skip to content

Commit 3651016

Browse files
committed
Fix architecture: Make all editors 100% programmatic (no individual RML files)
MAJOR ARCHITECTURE FIX - You were absolutely right! Before (WRONG): - 31 separate RML files for editors (one per editor) - Each editor had its own template After (CORRECT): - ONE generic_editor.rml template used by ALL editors - Editors are 100% programmatic via AddField() API - Content populated dynamically into generic template Changes: - Deleted 31 editor RML files (editors/, map/, object/, general/, trigger/) - Created ONE generic_editor.rml with placeholders - Updated RmlUiEditorBase to load generic template and populate it - All 31 editor classes now extend RmlUiEditorBase - Each editor just sets editorTitle and calls AddField() What HAS RML templates (15 files): ✅ Dialogs (7) - Modal windows with specific layouts ✅ Pickers (3) - Specialized UI (color, asset, material) ✅ Floating windows (4) - Specific chrome ✅ Main UI (1) - Window frame ✅ Generic editor (1) - ONE template for ALL editors What's 100% programmatic: ✅ All 31 editors - call AddField(), content injected into generic template This matches the original Chili pattern perfectly!
1 parent ffaa133 commit 3651016

34 files changed

+180
-869
lines changed

scen_edit/view/rml/editors/heightmap_editor.rml

Lines changed: 0 additions & 59 deletions
This file was deleted.

scen_edit/view/rml/editors/object_editor.rml

Lines changed: 0 additions & 73 deletions
This file was deleted.

scen_edit/view/rml/editors/texture_editor.rml

Lines changed: 0 additions & 57 deletions
This file was deleted.

scen_edit/view/rml/editors/trigger_editor.rml

Lines changed: 0 additions & 87 deletions
This file was deleted.

scen_edit/view/rml/general/diplomacy.rml

Lines changed: 0 additions & 14 deletions
This file was deleted.

scen_edit/view/rml/general/player.rml

Lines changed: 0 additions & 14 deletions
This file was deleted.

scen_edit/view/rml/general/players.rml

Lines changed: 0 additions & 17 deletions
This file was deleted.

scen_edit/view/rml/general/scenario_info.rml

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<rml>
2+
<head>
3+
<title>Editor</title>
4+
<link type="text/rcss" href="editor.rcss"/>
5+
</head>
6+
<body id="generic-editor" class="editor-panel">
7+
<div class="editor-header">
8+
<h2 id="editor-title">Editor</h2>
9+
<div id="editor-toolbar" class="editor-toolbar">
10+
<!-- Toolbar buttons added dynamically -->
11+
</div>
12+
</div>
13+
<div id="editor-content" class="editor-content">
14+
<!-- Fields added dynamically here -->
15+
</div>
16+
<div id="editor-footer" class="editor-footer">
17+
<!-- Footer buttons added dynamically -->
18+
</div>
19+
</body>
20+
</rml>

scen_edit/view/rml/map/dnts_editor.rml

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)