Hymn to Beauty
C++ 3D Engine
GUI::ResourceView Class Reference

Displays all the hymn's resources. More...

#include <ResourceView.hpp>

Public Member Functions

 ResourceView (Utility::Window *window, Video::LowLevelRenderer *lowLevelRenderer)
 Create new resource view. More...
 
void Show ()
 Show the resource list. More...
 
bool HasMadeChanges () const
 Checks if any changes has been made to the current scene. More...
 
bool IsVisible () const
 Get whether the resource list is visible. More...
 
void SetVisible (bool visible)
 Set whether the resource list should be visible. More...
 
void HideEditors ()
 Hide all editors. More...
 
void SaveScene () const
 Save the currently active scene. More...
 
Json::Value GetSceneJson (std::string *filename) const
 Get a json representing the scene. More...
 
void ResetScene ()
 Reset which scene is open. More...
 
SceneEditorGetScene ()
 Return Scene Editor. More...
 
int GetEditorWidth () const
 Get the width of the right-side editor (entity, script, etc.). More...
 

Detailed Description

Displays all the hymn's resources.

Constructor & Destructor Documentation

◆ ResourceView()

ResourceView::ResourceView ( Utility::Window window,
Video::LowLevelRenderer lowLevelRenderer 
)

Create new resource view.

Parameters
windowThe window the display the resource view in.
lowLevelRendererThe low-level renderer to use.

Member Function Documentation

◆ GetEditorWidth()

int ResourceView::GetEditorWidth ( ) const

Get the width of the right-side editor (entity, script, etc.).

Returns
The width of the editor.

◆ GetScene()

SceneEditor & ResourceView::GetScene ( )

Return Scene Editor.

Returns
The scene editor

◆ GetSceneJson()

Json::Value ResourceView::GetSceneJson ( std::string *  filename) const

Get a json representing the scene.

Parameters
filenameThe json file representing the scene.

◆ HasMadeChanges()

bool ResourceView::HasMadeChanges ( ) const

Checks if any changes has been made to the current scene.

Returns
Has any changes been made.

◆ HideEditors()

void ResourceView::HideEditors ( )

Hide all editors.

Needs to be called before playing the game or old editors with stale pointers could be shown when returning to the editor.

◆ IsVisible()

bool ResourceView::IsVisible ( ) const

Get whether the resource list is visible.

Returns
Whether the resource list is visible.

◆ ResetScene()

void ResourceView::ResetScene ( )

Reset which scene is open.

◆ SaveScene()

void ResourceView::SaveScene ( ) const

Save the currently active scene.

◆ SetVisible()

void ResourceView::SetVisible ( bool  visible)

Set whether the resource list should be visible.

Parameters
visibleWhether the resource list should be visible.

◆ Show()

void ResourceView::Show ( )

Show the resource list.


The documentation for this class was generated from the following files: