yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::editor::RomSession Struct Reference

Represents a single session, containing a ROM and its associated editors. More...

#include <session_types.h>

Public Member Functions

void CaptureRomIdentity (bool preserve_editing_source=false)
 
void ReloadGraphicsDisplay ()
 
void ActivateGraphicsDisplay ()
 
void ResetGraphicsDisplay ()
 
bool HasPendingGfxGroupChanges () const
 
 RomSession ()=default
 
 RomSession (UserSettings *user_settings, size_t session_id, EditorRegistry *editor_registry=nullptr)
 
 RomSession (Rom &&r, UserSettings *user_settings=nullptr, size_t session_id=0, EditorRegistry *editor_registry=nullptr)
 
 ~RomSession ()
 
size_t session_id () const
 
std::string GetDisplayName () const
 

Public Attributes

Rom rom
 
std::optional< RomBaselineIdentity > rom_baseline
 
zelda3::GameData game_data
 
EditorSet editors
 
std::string custom_name
 
std::string filepath
 
core::FeatureFlags::Flags feature_flags
 
std::optional< project::YazeProject > project_context
 
bool project_dirty = false
 
bool backup_restore_pending = false
 
ProjectFileEditorState project_file_editor_state
 
std::unique_ptr< core::VersionManager > version_manager
 
bool game_data_loaded = false
 
std::array< bool, kEditorTypeCount > editor_initialized {}
 
std::array< bool, kEditorTypeCount > editor_assets_loaded {}
 

Private Attributes

std::unique_ptr< std::array< gfx::Bitmap, zelda3::kNumGfxSheets > > graphics_display_
 

Detailed Description

Represents a single session, containing a ROM and its associated editors.

Definition at line 178 of file session_types.h.

Constructor & Destructor Documentation

◆ RomSession() [1/3]

yaze::editor::RomSession::RomSession ( )
default

◆ RomSession() [2/3]

yaze::editor::RomSession::RomSession ( UserSettings * user_settings,
size_t session_id,
EditorRegistry * editor_registry = nullptr )

Definition at line 401 of file session_types.cc.

◆ RomSession() [3/3]

yaze::editor::RomSession::RomSession ( Rom && r,
UserSettings * user_settings = nullptr,
size_t session_id = 0,
EditorRegistry * editor_registry = nullptr )
explicit

Definition at line 406 of file session_types.cc.

References CaptureRomIdentity(), feature_flags, yaze::Rom::filename(), filepath, and rom.

Here is the call graph for this function:

◆ ~RomSession()

yaze::editor::RomSession::~RomSession ( )

Definition at line 463 of file session_types.cc.

References game_data, yaze::gfx::PaletteManager::Get(), yaze::gfx::PaletteManager::ReleaseSession(), and ResetGraphicsDisplay().

Here is the call graph for this function:

Member Function Documentation

◆ CaptureRomIdentity()

void yaze::editor::RomSession::CaptureRomIdentity ( bool preserve_editing_source = false)

◆ ReloadGraphicsDisplay()

◆ ActivateGraphicsDisplay()

void yaze::editor::RomSession::ActivateGraphicsDisplay ( )

◆ ResetGraphicsDisplay()

void yaze::editor::RomSession::ResetGraphicsDisplay ( )

Definition at line 451 of file session_types.cc.

References game_data, yaze::gfx::Arena::Get(), and graphics_display_.

Referenced by ReloadGraphicsDisplay(), yaze::editor::EditorManager::ResetAssetState(), and ~RomSession().

Here is the call graph for this function:

◆ HasPendingGfxGroupChanges()

bool yaze::editor::RomSession::HasPendingGfxGroupChanges ( ) const

Definition at line 311 of file session_types.cc.

References yaze::zelda3::DiffGfxGroups(), game_data, game_data_loaded, yaze::Rom::is_loaded(), and rom.

Here is the call graph for this function:

◆ session_id()

◆ GetDisplayName()

std::string yaze::editor::RomSession::GetDisplayName ( ) const

Definition at line 468 of file session_types.cc.

References custom_name, rom, and yaze::Rom::title().

Here is the call graph for this function:

Member Data Documentation

◆ rom

◆ rom_baseline

std::optional<RomBaselineIdentity> yaze::editor::RomSession::rom_baseline

◆ game_data

◆ editors

◆ custom_name

std::string yaze::editor::RomSession::custom_name

Definition at line 194 of file session_types.h.

Referenced by GetDisplayName().

◆ filepath

std::string yaze::editor::RomSession::filepath

◆ feature_flags

◆ project_context

◆ project_dirty

bool yaze::editor::RomSession::project_dirty = false

◆ backup_restore_pending

bool yaze::editor::RomSession::backup_restore_pending = false

Definition at line 208 of file session_types.h.

◆ project_file_editor_state

ProjectFileEditorState yaze::editor::RomSession::project_file_editor_state

◆ version_manager

std::unique_ptr<core::VersionManager> yaze::editor::RomSession::version_manager

◆ game_data_loaded

bool yaze::editor::RomSession::game_data_loaded = false

◆ editor_initialized

◆ editor_assets_loaded

std::array<bool, kEditorTypeCount> yaze::editor::RomSession::editor_assets_loaded {}

◆ graphics_display_

std::unique_ptr<std::array<gfx::Bitmap, zelda3::kNumGfxSheets> > yaze::editor::RomSession::graphics_display_
private

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