#include <toast_manager.h>
Public Member Functions | |
| void | Show (const std::string &message, ToastType type=ToastType::kInfo, float ttl_seconds=3.0f) |
| size_t | dedup_suppressed_count () const |
| Number of toasts suppressed by dedup since last reset. | |
| void | reset_dedup_stats () |
| void | Draw () |
| size_t | GetUnreadCount () const |
| const std::deque< NotificationEntry > & | GetHistory () const |
| void | MarkAllRead () |
| void | ClearHistory () |
Static Public Attributes | |
| static constexpr size_t | kMaxHistorySize = 50 |
| static constexpr float | kDedupCooldownSeconds = 1.0f |
Private Attributes | |
| std::deque< Toast > | toasts_ |
| std::deque< NotificationEntry > | notification_history_ |
| std::string | last_shown_message_ |
| ToastType | last_shown_type_ = ToastType::kInfo |
| std::chrono::steady_clock::time_point | last_shown_time_ {} |
| size_t | dedup_suppressed_count_ = 0 |
Definition at line 39 of file toast_manager.h.
|
inline |
Definition at line 45 of file toast_manager.h.
References dedup_suppressed_count_, kDedupCooldownSeconds, kMaxHistorySize, last_shown_message_, last_shown_time_, last_shown_type_, yaze::editor::NotificationEntry::message, notification_history_, yaze::editor::NotificationEntry::read, yaze::editor::NotificationEntry::timestamp, toasts_, and yaze::editor::NotificationEntry::type.
Referenced by yaze::editor::AgentProposalsPanel::AcceptProposal(), yaze::editor::AgentEditor::ApplyConfig(), yaze::editor::LayoutCoordinator::ApplyLayoutPreset(), yaze::editor::EditorManager::ApplyLayoutProfile(), yaze::editor::ProjectManager::ApplyZsoPreset(), yaze::editor::ProjectManager::CancelPendingProject(), yaze::editor::EditorManager::CaptureTemporaryLayoutSnapshot(), yaze::editor::RomLifecycleManager::CheckOracleRomSafetyPreSave(), yaze::editor::RomLifecycleManager::CheckRomWritePolicy(), yaze::editor::AgentChat::ClearHistory(), yaze::editor::EditorManager::ClearTemporaryLayoutSnapshot(), yaze::editor::WorkspaceManager::CloseAllFloatingWindows(), yaze::editor::SessionCoordinator::CloseSession(), yaze::editor::RomFileManager::CreateBackup(), yaze::editor::ProjectManager::CreateFromTemplate(), yaze::editor::ProjectManager::CreateNewProject(), yaze::editor::AgentProposalsPanel::DeleteProposal(), yaze::editor::ProjectFileEditor::Draw(), yaze::editor::AgentRomSyncPanel::Draw(), yaze::editor::AgentZ3EDCommandPanel::Draw(), yaze::editor::AgentEditor::DrawAgentBuilderPanel(), yaze::editor::AssemblyEditor::DrawAssembleMenu(), yaze::editor::AgentEditor::DrawBotProfilesPanel(), yaze::editor::AssemblyEditor::DrawBuildOutput(), yaze::editor::AgentEditor::DrawCommonTilesEditor(), yaze::editor::PaletteEditor::DrawControlPanel(), yaze::editor::UICoordinator::DrawGlobalSearch(), yaze::editor::AgentEditor::DrawNewPromptCreator(), yaze::editor::ProjectManagementPanel::DrawProjectOverview(), yaze::editor::AgentEditor::DrawPromptEditorPanel(), yaze::editor::DungeonEditorV2::DrawRoomTab(), yaze::editor::ProjectManagementPanel::DrawStorageLocations(), yaze::editor::PaletteGroupPanel::DrawToolbar(), yaze::editor::ProjectManagementPanel::DrawVersionControl(), yaze::editor::UICoordinator::DrawWorkspacePresetDialogs(), yaze::editor::WorkspaceManager::ExecuteWorkspaceCommand(), yaze::editor::ProjectManager::ExportProject(), yaze::editor::ProjectManager::FinalizeProjectCreation(), yaze::editor::AgentChat::HandleAgentResponse(), yaze::editor::DungeonEditorV2::HandleObjectPlaced(), yaze::editor::EditorManager::HandleUIActionRequest(), yaze::editor::WorkspaceManager::HideAllWindows(), yaze::editor::AgentEditor::HostSession(), yaze::editor::ProjectManager::ImportProject(), yaze::editor::DungeonEditorV2::Initialize(), yaze::editor::UICoordinator::InitializeCommandPalette(), yaze::editor::EditorManager::InitializeSubsystems(), yaze::editor::AgentEditor::JoinSession(), yaze::editor::EditorActivator::JumpToAssemblySymbol(), yaze::editor::EditorActivator::JumpToDungeonRoom(), yaze::editor::EditorActivator::JumpToMessage(), yaze::editor::EditorActivator::JumpToOverworldMap(), yaze::editor::AgentEditor::LeaveSession(), yaze::editor::DungeonEditorV2::Load(), yaze::editor::WorkspaceManager::LoadDesignerLayout(), yaze::editor::WorkspaceManager::LoadDeveloperLayout(), yaze::editor::WorkspaceManager::LoadModderLayout(), yaze::editor::ProjectManager::LoadProjectFromFile(), yaze::editor::EditorManager::LoadProjectWithRom(), yaze::editor::EditorManager::LoadRom(), yaze::editor::RomFileManager::LoadRomFromFile(), yaze::editor::WorkspaceManager::LoadWorkspaceLayout(), yaze::editor::WorkspaceManager::LoadWorkspacePreset(), yaze::editor::WorkspaceManager::MaximizeCurrentWindow(), yaze::editor::MenuOrchestrator::OnCheckRomVersion(), yaze::editor::MenuOrchestrator::OnCopy(), yaze::editor::MenuOrchestrator::OnCreateBackup(), yaze::editor::MenuOrchestrator::OnCreateProject(), yaze::editor::MenuOrchestrator::OnCut(), yaze::editor::MenuOrchestrator::OnFind(), yaze::editor::MenuOrchestrator::OnLoadAsmFile(), yaze::editor::MenuOrchestrator::OnOpenProject(), yaze::editor::MenuOrchestrator::OnOpenRom(), yaze::editor::MenuOrchestrator::OnPaste(), yaze::editor::MenuOrchestrator::OnRedo(), yaze::editor::MenuOrchestrator::OnResetWorkspaceLayout(), yaze::editor::MenuOrchestrator::OnRunDataIntegrityCheck(), yaze::editor::MenuOrchestrator::OnSaveProject(), yaze::editor::MenuOrchestrator::OnSaveProjectAs(), yaze::editor::MenuOrchestrator::OnSaveRom(), yaze::editor::MenuOrchestrator::OnTestSaveLoad(), yaze::editor::MenuOrchestrator::OnToggleAsarPatch(), yaze::editor::MenuOrchestrator::OnToggleCustomLoading(), yaze::editor::MenuOrchestrator::OnUndo(), yaze::editor::MenuOrchestrator::OnUpgradeRom(), yaze::editor::MenuOrchestrator::OnValidateRom(), yaze::editor::EditorManager::OpenProject(), yaze::editor::AgentEditor::RefreshModelCache(), yaze::editor::AgentProposalsPanel::RejectProposal(), yaze::editor::AgentConfigPanel::RenderModelConfigControls(), yaze::editor::AgentConfigPanel::RenderModelDeck(), yaze::editor::EditorManager::RepairCurrentProject(), yaze::editor::ProjectManager::RepairCurrentProject(), yaze::editor::EditorManager::ResetCurrentEditorLayout(), yaze::editor::LayoutCoordinator::ResetCurrentEditorLayout(), yaze::editor::WorkspaceManager::ResetWorkspaceLayout(), yaze::editor::EditorManager::ResolvePotItemSaveConfirmation(), yaze::editor::WorkspaceManager::RestoreAllWindows(), yaze::editor::EditorManager::RestoreTemporaryLayoutSnapshot(), yaze::editor::OverworldEditor::Save(), yaze::editor::DungeonEditorV2::SaveAllRooms(), yaze::editor::EditorManager::SaveProjectAs(), yaze::editor::ProjectManager::SaveProjectToFile(), yaze::editor::EditorManager::SaveRom(), yaze::editor::RomFileManager::SaveRom(), yaze::editor::RomFileManager::SaveRomAs(), yaze::editor::DungeonEditorV2::SaveRoomData(), yaze::editor::WorkspaceManager::SaveWorkspaceLayout(), yaze::editor::WorkspaceManager::SaveWorkspacePreset(), yaze::editor::AgentEditor::SendToGemini(), yaze::editor::PaletteGroupPanel::SetColor(), yaze::editor::ProjectManager::SetProjectRom(), yaze::editor::EditorManager::SetupDialogCallbacks(), yaze::editor::EditorManager::SetupWelcomeScreenCallbacks(), yaze::editor::DungeonEditorV2::SetWorkbenchWorkflowMode(), yaze::editor::WorkspaceManager::ShowAllWindows(), yaze::editor::EditorManager::ShowProjectFileEditor(), yaze::editor::SessionCoordinator::ShowSessionLimitWarning(), yaze::editor::SessionCoordinator::ShowSessionOperationResult(), yaze::editor::EditorManager::SwitchToEditor(), yaze::editor::UICoordinator::UICoordinator(), yaze::editor::EditorManager::UpdateEditorState(), yaze::editor::SessionCoordinator::UpdateSessions(), yaze::editor::ProjectManager::ValidateProject(), and yaze::editor::RomFileManager::ValidateRom().
|
inline |
Number of toasts suppressed by dedup since last reset.
Definition at line 78 of file toast_manager.h.
References dedup_suppressed_count_.
|
inline |
Definition at line 79 of file toast_manager.h.
References dedup_suppressed_count_.
|
inline |
Definition at line 81 of file toast_manager.h.
References yaze::gui::ConvertColorToImVec4(), yaze::gui::ThemeManager::Get(), yaze::gui::ThemeManager::GetCurrentTheme(), yaze::gui::GetSurfaceContainerHighVec4(), yaze::editor::kError, yaze::editor::kInfo, yaze::editor::kSuccess, yaze::editor::kWarning, yaze::editor::Toast::message, toasts_, yaze::editor::Toast::ttl_seconds, and yaze::editor::Toast::type.
Referenced by yaze::editor::UICoordinator::DrawAllUI().

|
inline |
Definition at line 155 of file toast_manager.h.
References notification_history_.
Referenced by yaze::editor::UICoordinator::DrawNotificationBell(), and yaze::editor::RightPanelManager::DrawNotificationsPanel().
|
inline |
Definition at line 163 of file toast_manager.h.
References notification_history_.
Referenced by yaze::editor::RightPanelManager::DrawNotificationsPanel().
|
inline |
Definition at line 167 of file toast_manager.h.
References notification_history_.
Referenced by yaze::editor::UICoordinator::DrawNotificationBell(), and yaze::editor::RightPanelManager::DrawNotificationsPanel().
|
inline |
Definition at line 173 of file toast_manager.h.
References notification_history_.
Referenced by yaze::editor::RightPanelManager::DrawNotificationsPanel().
|
staticconstexpr |
Definition at line 41 of file toast_manager.h.
Referenced by Show().
|
staticconstexpr |
Definition at line 43 of file toast_manager.h.
Referenced by Show().
|
private |
Definition at line 176 of file toast_manager.h.
|
private |
Definition at line 177 of file toast_manager.h.
Referenced by ClearHistory(), GetHistory(), GetUnreadCount(), MarkAllRead(), and Show().
|
private |
Definition at line 180 of file toast_manager.h.
Referenced by Show().
|
private |
Definition at line 181 of file toast_manager.h.
Referenced by Show().
|
private |
Definition at line 182 of file toast_manager.h.
Referenced by Show().
|
private |
Definition at line 183 of file toast_manager.h.
Referenced by dedup_suppressed_count(), reset_dedup_stats(), and Show().