1#ifndef YAZE_APP_EDITOR_EDITOR_MANAGER_H
2#define YAZE_APP_EDITOR_EDITOR_MANAGER_H
4#define IMGUI_DEFINE_MATH_OPERATORS
11#include "imgui/imgui.h"
18#include "absl/status/status.h"
40#include "yaze_config.h"
48class AgentControlServer;
76 const std::string& cards_str);
95 return &editor_set->overworld_editor_.overworld();
107 return &
sessions_[current_index].feature_flags;
114 ImGui::GetIO().FontGlobalScale = scale;
117 LOG_WARN(
"EditorManager",
"Failed to save user settings: %s",
118 status.ToString().c_str());
179 size_t session_index)
const;
219#ifdef YAZE_ENABLE_TESTING
220 void ShowTestDashboard() { show_test_dashboard_ =
true; }
225 void ShowChatHistory();
232 absl::Status
SaveRomAs(
const std::string& filename);
235 const std::string& template_name =
"Basic ROM Hack");
269 AutomationBridge harness_telemetry_bridge_;
287 std::unique_ptr<yaze::agent::AgentControlServer> agent_control_server_;
The Rom class is used to load, save, and modify Rom data.
Comprehensive AI Agent Platform & Bot Creator.
Central registry for all editor cards with session awareness and dependency injection.
EditorSet * prev_editor_set_
The EditorManager controls the main editor window and manages the various editor classes.
absl::Status SaveProjectAs()
std::deque< RomSession > sessions_
static bool IsCardBasedEditor(EditorType type)
std::unique_ptr< SessionCoordinator > session_coordinator_
void SaveWorkspacePreset(const std::string &name)
void InitializeTestSuites()
bool show_proposal_drawer_
absl::Status SaveRomAs(const std::string &filename)
project::YazeProject current_project_
void DrawContextSensitiveCardControl()
void HideCurrentEditorCards()
MenuBuilder menu_builder_
void JumpToDungeonRoom(int room_id)
void SwitchToSession(size_t index)
size_t GetActiveSessionCount() const
void ShowResourceLabelManager()
absl::Status OpenProject()
ProjectManager project_manager_
void CloseCurrentSession()
gfx::IRenderer * renderer_
EditorCardRegistry card_registry_
bool HasDuplicateSession(const std::string &filepath)
void SwitchToEditor(EditorType editor_type)
absl::Status RepairCurrentProject()
EditorSelectionDialog editor_selection_dialog_
WorkspaceManager * workspace_manager()
std::unique_ptr< LayoutManager > layout_manager_
void LoadWorkspacePreset(const std::string &name)
std::string GenerateUniqueEditorTitle(EditorType type, size_t session_index) const
void RenameSession(size_t index, const std::string &new_name)
void DrawMenuBar()
Draw the main menu bar.
void LoadWorkspaceLayout()
bool show_workspace_layout
MenuBuilder & menu_builder()
UICoordinator * ui_coordinator()
void DuplicateCurrentSession()
void Initialize(gfx::IRenderer *renderer, const std::string &filename="")
EditorRegistry editor_registry_
AgentChatHistoryPopup agent_chat_history_popup_
void ResetWorkspaceLayout()
absl::Status CreateNewProject(const std::string &template_name="Basic ROM Hack")
EditorSet blank_editor_set_
ToastManager toast_manager_
void RefreshWorkspacePresets()
auto overworld() const -> yaze::zelda3::Overworld *
auto GetCurrentEditorSet() const -> EditorSet *
void SetFontGlobalScale(float scale)
std::unique_ptr< MenuOrchestrator > menu_orchestrator_
ProjectFileEditor project_file_editor_
void SetSidebarVisible(bool visible)
size_t session_to_rename_
bool IsSidebarVisible() const
auto GetCurrentEditor() const -> Editor *
absl::Status SaveProject()
void LoadDesignerLayout()
absl::Status DrawRomSelector()=delete
void SaveWorkspaceLayout()
void OpenEditorAndCardsFromFlags(const std::string &editor_name, const std::string &cards_str)
void JumpToOverworldMap(int map_id)
absl::Status LoadRom()
Load a ROM file into a new or existing session.
bool show_chat_history_popup_
void ShowCommandPalette()
absl::Status Update()
Main update loop for the editor application.
size_t GetCurrentSessionIndex() const
absl::Status ImportProject(const std::string &project_path)
size_t GetCurrentSessionId() const
void LoadDeveloperLayout()
WindowDelegate window_delegate_
ShortcutManager shortcut_manager_
auto emulator() -> emu::Emulator &
EditorDependencies::SharedClipboard shared_clipboard_
UserSettings user_settings_
core::FeatureFlags::Flags * GetCurrentFeatureFlags()
WorkspaceManager workspace_manager_
auto GetCurrentRom() const -> Rom *
ProposalDrawer proposal_drawer_
void ShowPerformanceDashboard()
void ConfigureEditorDependencies(EditorSet *editor_set, Rom *rom, size_t session_id)
Injects dependencies into all editors within an EditorSet.
WelcomeScreen welcome_screen_
absl::Status LoadAssets()
absl::Status OpenRomOrProject(const std::string &filename)
void RemoveSession(size_t index)
std::unique_ptr< PopupManager > popup_manager_
std::unique_ptr< UICoordinator > ui_coordinator_
absl::Status SaveRom()
Save the current ROM file.
absl::Status SetCurrentRom(Rom *rom)
RomFileManager rom_file_manager_
char session_rename_buffer_[256]
Manages editor types, categories, and lifecycle.
Beautiful grid-based editor selection dialog.
Contains a complete set of editors for a single ROM instance.
Interface for editor classes.
Editor for .yaze project files with syntax highlighting and validation.
Handles all project file operations.
ImGui drawer for displaying and managing agent proposals.
Handles all ROM file I/O operations.
Handles all UI drawing operations and state management.
Manages user preferences and settings persistence.
Modern welcome screen with project grid and quick actions.
Low-level window operations with minimal dependencies.
void LoadDesignerLayout()
void LoadWorkspaceLayout()
void SaveWorkspaceLayout()
void ResetWorkspaceLayout()
void LoadDeveloperLayout()
Manages workspace layouts, sessions, and presets.
void SaveWorkspacePreset(const std::string &name)
void LoadWorkspacePreset(const std::string &name)
A class for emulating and debugging SNES games.
Defines an abstract interface for all rendering operations.
#define LOG_WARN(category, format,...)
Main namespace for the application.
Modern project structure with comprehensive settings consolidation.