#include <window_sidebar.h>

Public Member Functions | |
| WindowSidebar (WorkspaceWindowManager &window_manager, std::function< bool()> is_dungeon_workbench_mode={}, std::function< void(bool)> set_dungeon_workflow_mode={}, std::function< float()> get_bottom_reserved_height={}, std::function< EditorContextSnapshot(const std::string &)> context_provider={}) | |
| void | SetUserSettings (UserSettings *settings) |
| void | DrawContextDetailsWindow (size_t session_id) |
| void | Draw (size_t session_id, const std::string &category, std::function< bool()> has_rom) |
Static Public Member Functions | |
| static bool | MatchesWindowSearch (const std::string &query, const std::string &display_name, const std::string &window_id, const std::string &shortcut_hint) |
| static bool | IsDungeonWindowModeTarget (const std::string &window_id) |
| static std::string | SidebarSectionFor (const std::string &workflow_group) |
| static std::string | SidebarSectionFor (const WindowDescriptor &window) |
| static bool | ShouldOmitWindowInSidebar (const std::string &window_id, bool dungeon_workbench_mode) |
| static bool | HasRenderableContext (const EditorContextSnapshot &snapshot) |
Private Member Functions | |
| void | DrawEditorContext (size_t session_id, const std::string &category, const EditorContextSnapshot &snapshot) |
| void | DrawEditorContextDetails (size_t session_id, const EditorContextSnapshot &snapshot) |
| void | DispatchContextAction (size_t session_id, const EditorContextAction &action) |
Private Attributes | |
| WorkspaceWindowManager & | window_manager_ |
| std::function< bool()> | is_dungeon_workbench_mode_ |
| std::function< void(bool)> | set_dungeon_workflow_mode_ |
| std::function< float()> | get_bottom_reserved_height_ |
| std::function< EditorContextSnapshot(const std::string &) | context_provider_ ) |
| UserSettings * | user_settings_ = nullptr |
| char | sidebar_search_ [256] = {} |
| std::string | context_details_category_ |
Friends | |
| class | WindowSidebarTestPeer |
Definition at line 16 of file window_sidebar.h.
|
explicit |
Definition at line 59 of file window_sidebar.cc.
|
inline |
Definition at line 26 of file window_sidebar.h.
References user_settings_.
Referenced by yaze::editor::ActivityBar::SetUserSettings().
|
static |
Definition at line 247 of file window_sidebar.cc.
Referenced by Draw(), and yaze::editor::anonymous_namespace{window_sidebar.cc}::MatchesWindowSearch().
|
static |
Definition at line 261 of file window_sidebar.cc.
Referenced by yaze::editor::anonymous_namespace{window_sidebar.cc}::IsDungeonPanelModeWindow(), and ShouldOmitWindowInSidebar().
|
static |
Definition at line 269 of file window_sidebar.cc.
Referenced by Draw(), and SidebarSectionFor().
|
static |
Definition at line 277 of file window_sidebar.cc.
References yaze::editor::WindowDescriptor::card_id, SidebarSectionFor(), and yaze::editor::WindowDescriptor::workflow_group.

|
static |
Definition at line 288 of file window_sidebar.cc.
References IsDungeonWindowModeTarget().
Referenced by Draw().

|
static |
Definition at line 71 of file window_sidebar.cc.
References yaze::editor::EditorContextSnapshot::actions, yaze::editor::EditorContextSnapshot::counts, yaze::editor::EditorContextSnapshot::diagnostics, yaze::editor::EditorContextSnapshot::experiment, yaze::editor::EditorExperimentContext::experimental, yaze::editor::EditorContextSnapshot::has_pending_changes, yaze::editor::EditorContextSnapshot::metadata, and yaze::editor::EditorContextSnapshot::subtitle.
Referenced by DrawContextDetailsWindow(), and DrawEditorContext().
| void yaze::editor::WindowSidebar::DrawContextDetailsWindow | ( | size_t | session_id | ) |
Definition at line 133 of file window_sidebar.cc.
References context_details_category_, context_provider_, DrawEditorContextDetails(), and HasRenderableContext().
Referenced by yaze::editor::ActivityBar::Render().

| void yaze::editor::WindowSidebar::Draw | ( | size_t | session_id, |
| const std::string & | category, | ||
| std::function< bool()> | has_rom ) |
Definition at line 293 of file window_sidebar.cc.
References yaze::editor::WorkspaceWindowManager::CloseWindow(), yaze::gui::ConvertColorToImVec4(), yaze::editor::WindowDescriptor::display_name, yaze::gui::ThemeManager::Get(), get_bottom_reserved_height_, yaze::editor::WorkspaceWindowManager::GetActiveSidePanelWidth(), yaze::gui::ThemeManager::GetCurrentTheme(), yaze::gui::GetOnSurfaceVec4(), yaze::editor::WorkspaceWindowManager::GetPinnedWindows(), yaze::gui::GetPrimaryVec4(), yaze::gui::LayoutHelpers::GetSafeAreaInsets(), yaze::editor::WorkspaceWindowManager::GetSidebarWidth(), yaze::gui::LayoutHelpers::GetStandardSpacing(), yaze::gui::LayoutHelpers::GetStandardWidgetHeight(), yaze::gui::GetSurfaceContainerHighestVec4(), yaze::gui::GetSurfaceContainerHighVec4(), yaze::gui::GetTextSecondaryVec4(), yaze::gui::LayoutHelpers::GetTopInset(), yaze::editor::WorkspaceWindowManager::GetWindowDescriptor(), yaze::editor::WorkspaceWindowManager::GetWindowsInCategory(), yaze::editor::WorkspaceWindowManager::GetWindowsSortedByMRU(), yaze::editor::WorkspaceWindowManager::GetWorkspaceWindowName(), yaze::editor::WorkspaceWindowManager::HideAllWindowsInCategory(), ICON_MD_APPS, ICON_MD_CHEVRON_LEFT, ICON_MD_CLEAR, ICON_MD_FOLDER_OPEN, ICON_MD_MORE_HORIZ, ICON_MD_PUSH_PIN, ICON_MD_SEARCH, ICON_MD_VIEW_QUILT, ICON_MD_VISIBILITY, ICON_MD_VISIBILITY_OFF, ICON_MD_WORKSPACES, is_dungeon_workbench_mode_, yaze::editor::WorkspaceWindowManager::IsWindowOpen(), yaze::editor::WorkspaceWindowManager::IsWindowPinned(), MatchesWindowSearch(), yaze::editor::WorkspaceWindowManager::OpenWindow(), yaze::gui::ScaledSize(), set_dungeon_workflow_mode_, yaze::editor::WorkspaceWindowManager::SetSidebarExpanded(), yaze::editor::WorkspaceWindowManager::SetWindowPinned(), ShouldOmitWindowInSidebar(), yaze::editor::WorkspaceWindowManager::ShowAllWindowsInCategory(), sidebar_search_, SidebarSectionFor(), yaze::gui::IconSize::Small(), yaze::editor::WorkspaceWindowManager::ToggleWindow(), yaze::gui::TransparentIconButton(), yaze::editor::WorkspaceWindowManager::TriggerShowWindowBrowser(), yaze::editor::WorkspaceWindowManager::TriggerWindowClicked(), yaze::editor::WindowDescriptor::visibility_flag, and window_manager_.
Referenced by yaze::editor::ActivityBar::DrawSidePanel().
|
private |
Definition at line 102 of file window_sidebar.cc.
References yaze::gui::ColoredText(), context_details_category_, yaze::editor::EditorContextSnapshot::diagnostics, yaze::editor::EditorContextSnapshot::experiment, yaze::editor::EditorExperimentContext::experimental, yaze::gui::GetWarningVec4(), yaze::editor::EditorContextSnapshot::has_pending_changes, HasRenderableContext(), yaze::editor::kInfo, yaze::editor::EditorContextSnapshot::pending_label, yaze::editor::EditorExperimentContext::save_posture, and yaze::editor::EditorContextSnapshot::title.

|
private |
Definition at line 154 of file window_sidebar.cc.
References yaze::editor::EditorExperimentContext::acknowledged, yaze::editor::EditorContextSnapshot::actions, yaze::gui::ColoredText(), yaze::gui::ColoredTextF(), yaze::editor::EditorContextSnapshot::counts, yaze::editor::EditorContextSnapshot::diagnostics, DispatchContextAction(), yaze::editor::EditorContextSnapshot::experiment, yaze::editor::EditorExperimentContext::experimental, yaze::gui::GetErrorVec4(), yaze::gui::GetTextSecondaryVec4(), yaze::gui::GetWarningVec4(), yaze::editor::EditorContextSnapshot::has_pending_changes, ICON_MD_EDIT, ICON_MD_ERROR, ICON_MD_INFO, ICON_MD_WARNING, yaze::editor::kError, yaze::editor::kInfo, yaze::editor::kWarning, yaze::editor::EditorContextSnapshot::metadata, yaze::editor::EditorContextSnapshot::pending_label, yaze::editor::EditorExperimentContext::save_posture, yaze::editor::EditorContextSnapshot::subtitle, and yaze::editor::EditorContextSnapshot::title.
Referenced by DrawContextDetailsWindow().
|
private |
Definition at line 79 of file window_sidebar.cc.
References yaze::editor::EditorContextAction::enabled, yaze::editor::WorkspaceWindowManager::GetWindowDescriptor(), yaze::editor::WorkspaceWindowManager::GetWorkspaceWindowName(), yaze::editor::EditorContextAction::kind, yaze::editor::kOpenWindow, yaze::editor::WorkspaceWindowManager::MarkWindowRecentlyUsed(), yaze::editor::WorkspaceWindowManager::OpenWindow(), yaze::editor::EditorContextAction::target, yaze::editor::WorkspaceWindowManager::TriggerWindowClicked(), and window_manager_.
Referenced by DrawEditorContextDetails().
|
friend |
Definition at line 52 of file window_sidebar.h.
|
private |
Definition at line 61 of file window_sidebar.h.
Referenced by DispatchContextAction(), and Draw().
|
private |
Definition at line 62 of file window_sidebar.h.
Referenced by Draw().
|
private |
Definition at line 63 of file window_sidebar.h.
Referenced by Draw().
|
private |
Definition at line 64 of file window_sidebar.h.
Referenced by Draw().
|
private |
Definition at line 65 of file window_sidebar.h.
Referenced by DrawContextDetailsWindow().
|
private |
Definition at line 66 of file window_sidebar.h.
Referenced by SetUserSettings().
|
private |
Definition at line 67 of file window_sidebar.h.
Referenced by Draw().
|
private |
Definition at line 68 of file window_sidebar.h.
Referenced by DrawContextDetailsWindow(), and DrawEditorContext().