feat: Implement Jump-to Functionality for Cross-Editor Navigation

- Added JumpToDungeonRoom and JumpToOverworldMap methods to facilitate quick navigation between dungeon and overworld editors.
- Introduced SwitchToEditor method to manage editor tab activation based on the selected editor type.
- Enhanced DungeonEditorV2 with room and entrance selection capabilities, improving user experience and workflow efficiency.
- Updated header files to declare new methods and ensure proper integration within the editor management system.
This commit is contained in:
scawful
2025-10-07 12:31:26 -04:00
parent 33f64f38a5
commit 5e4e6f5d45
10 changed files with 365 additions and 32 deletions

View File

@@ -132,15 +132,24 @@ class EditorCard {
void SetMinimized(bool minimized) { minimized_ = minimized; }
bool IsMinimized() const { return minimized_; }
// Focus the card window (bring to front and set focused)
void Focus();
bool IsFocused() const { return focused_; }
// Get the window name for ImGui operations
const char* GetWindowName() const { return window_name_.c_str(); }
private:
std::string title_;
std::string icon_;
std::string window_name_; // Full window name with icon
ImVec2 default_size_;
Position position_ = Position::Free;
bool minimizable_ = true;
bool closable_ = true;
bool minimized_ = false;
bool first_draw_ = true;
bool focused_ = false;
bool* p_open_ = nullptr;
};