Olympe Engine 2.0
2D Game Engine with ECS Architecture
Loading...
Searching...
No Matches
Classes | Namespaces
SwitchCaseEditorModal.h File Reference

Dedicated modal dialog for editing a Switch node's case definitions (Phase 26). More...

#include <string>
#include <vector>
#include "../../TaskSystem/TaskGraphTypes.h"
+ Include dependency graph for SwitchCaseEditorModal.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Olympe::SwitchCaseEditorModal
 Modal dialog for adding, removing, and reordering switch cases on a node. More...
 

Namespaces

namespace  Olympe
 < Provides AssetID and INVALID_ASSET_ID
 

Detailed Description

Dedicated modal dialog for editing a Switch node's case definitions (Phase 26).

Author
Olympe Engine
Date
2026-03-20

SwitchCaseEditorModal provides a modal overlay to add, remove, reorder, and configure the case definitions on a Switch node. Each case maps a value to a pin. It is separate from the properties panel so that edits are confirmed in one atomic Apply step.

Usage:

SwitchCaseEditorModal modal;
// When user clicks "Edit Switch Cases" in the Properties panel:
modal.Open(node.switchCases);
// In render loop:
modal.Render();
if (modal.IsConfirmed()) {
node.switchCases = modal.GetSwitchCases();
modal.Close();
}
ComponentTypeID GetComponentTypeID_Static()
Definition ECS_Entity.h:56

The modal works on a COPY of the node's switch cases. On "Apply" it marks itself as confirmed; on "Cancel" the copy is discarded.

C++14 compliant — no std::optional, structured bindings, std::filesystem.

Definition in file SwitchCaseEditorModal.h.