Main editor application singleton (facade).
More...
#include <EditorApplication.h>
|
| static EditorApplication & | Get () |
| | Get singleton instance.
|
Main editor application singleton (facade).
Provides Unity-like static access for EditorWindow and CustomEditor implementations: auto& app = EditorApplication::Get(); const char* projectPath = app.GetProjectPath(); DekiObject* selected = app.GetActiveObject();
The main editor (EditorApp) populates this facade via SetProjectPaths() and SetActiveObject(). Engine editors only need to call the getters.
◆ Get()
| EditorApplication & DekiEditor::EditorApplication::Get |
( |
| ) |
|
|
static |
◆ GetProjectPath()
| const std::string & DekiEditor::EditorApplication::GetProjectPath |
( |
| ) |
const |
|
inline |
Get project root directory path.
- Returns
- Path string, or empty if no project is open
◆ GetAssetsPath()
| const std::string & DekiEditor::EditorApplication::GetAssetsPath |
( |
| ) |
const |
|
inline |
Get assets directory path.
- Returns
- Path string, or empty if no project is open
◆ GetCachePath()
| const std::string & DekiEditor::EditorApplication::GetCachePath |
( |
| ) |
const |
|
inline |
Get cache directory path.
- Returns
- Path string, or empty if no project is open
◆ HasProject()
| bool DekiEditor::EditorApplication::HasProject |
( |
| ) |
const |
|
inline |
Check if a project is currently open.
◆ GetDeltaTime()
| float DekiEditor::EditorApplication::GetDeltaTime |
( |
| ) |
const |
|
inline |
Get delta time since last frame.
◆ GetActiveObject()
| DekiObject * DekiEditor::EditorApplication::GetActiveObject |
( |
| ) |
const |
|
inline |
Get currently selected object.
- Returns
- Selected object or nullptr
◆ GetActiveScene()
| Scene * DekiEditor::EditorApplication::GetActiveScene |
( |
| ) |
const |
|
inline |
Get currently active scene.
- Returns
- Active scene or nullptr
◆ SetProjectPaths()
| void DekiEditor::EditorApplication::SetProjectPaths |
( |
const std::string & | projectPath, |
|
|
const std::string & | assetsPath, |
|
|
const std::string & | cachePath ) |
Set project paths (called when project is opened).
◆ ClearProjectPaths()
| void DekiEditor::EditorApplication::ClearProjectPaths |
( |
| ) |
|
Clear project paths (called when project is closed).
◆ SetActiveObject()
| void DekiEditor::EditorApplication::SetActiveObject |
( |
DekiObject * | obj | ) |
|
|
inline |
Set active object (called when selection changes).
◆ SetActiveScene()
| void DekiEditor::EditorApplication::SetActiveScene |
( |
Scene * | scene | ) |
|
|
inline |
Set active scene (called when scene changes).
◆ SetDeltaTime()
| void DekiEditor::EditorApplication::SetDeltaTime |
( |
float | dt | ) |
|
|
inline |
Set delta time (called each frame).
◆ RequestAssetRefresh()
| void DekiEditor::EditorApplication::RequestAssetRefresh |
( |
| ) |
|
|
inline |
◆ PopAssetRefreshRequest()
| bool DekiEditor::EditorApplication::PopAssetRefreshRequest |
( |
| ) |
|
|
inline |
◆ RequestAssetInvalidation()
| void DekiEditor::EditorApplication::RequestAssetInvalidation |
( |
| ) |
|
|
inline |
◆ PopAssetInvalidationRequest()
| bool DekiEditor::EditorApplication::PopAssetInvalidationRequest |
( |
| ) |
|
|
inline |
◆ RequestOpenTool()
| void DekiEditor::EditorApplication::RequestOpenTool |
( |
const std::string & | filePath, |
|
|
const std::string & | cachePath ) |
|
inline |
◆ PopOpenToolRequest()
| bool DekiEditor::EditorApplication::PopOpenToolRequest |
( |
std::string & | outFilePath, |
|
|
std::string & | outCachePath ) |
|
inline |
◆ RequestSceneTool()
| void DekiEditor::EditorApplication::RequestSceneTool |
( |
SceneEditTool | tool | ) |
|
|
inline |
◆ PopSceneToolRequest()
| bool DekiEditor::EditorApplication::PopSceneToolRequest |
( |
SceneEditTool & | outTool | ) |
|
|
inline |
The documentation for this class was generated from the following file: