yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::editor::palette_internal::PaletteEditorHistory Class Reference

#include <palette_editor.h>

Public Member Functions

void RecordChange (const std::string &group_name, size_t palette_index, size_t color_index, const gfx::SnesColor &original_color, const gfx::SnesColor &new_color)
 
gfx::SnesColor RestoreOriginalColor (const std::string &group_name, size_t palette_index, size_t color_index) const
 
auto size () const
 
gfx::SnesColorGetModifiedColor (size_t index)
 
gfx::SnesColorGetOriginalColor (size_t index)
 
const std::deque< PaletteChange > & GetRecentChanges () const
 

Private Attributes

std::deque< PaletteChangerecent_changes_
 

Static Private Attributes

static const size_t kMaxHistorySize = 50
 

Detailed Description

Definition at line 30 of file palette_editor.h.

Member Function Documentation

◆ RecordChange()

void yaze::editor::palette_internal::PaletteEditorHistory::RecordChange ( const std::string &  group_name,
size_t  palette_index,
size_t  color_index,
const gfx::SnesColor original_color,
const gfx::SnesColor new_color 
)
inline

Definition at line 32 of file palette_editor.h.

References kMaxHistorySize, and recent_changes_.

Referenced by yaze::editor::PaletteEditor::HandleColorPopup().

◆ RestoreOriginalColor()

gfx::SnesColor yaze::editor::palette_internal::PaletteEditorHistory::RestoreOriginalColor ( const std::string &  group_name,
size_t  palette_index,
size_t  color_index 
) const
inline

Definition at line 43 of file palette_editor.h.

References recent_changes_.

◆ size()

auto yaze::editor::palette_internal::PaletteEditorHistory::size ( ) const
inline

Definition at line 56 of file palette_editor.h.

References recent_changes_.

◆ GetModifiedColor()

gfx::SnesColor & yaze::editor::palette_internal::PaletteEditorHistory::GetModifiedColor ( size_t  index)
inline

Definition at line 58 of file palette_editor.h.

References recent_changes_.

◆ GetOriginalColor()

gfx::SnesColor & yaze::editor::palette_internal::PaletteEditorHistory::GetOriginalColor ( size_t  index)
inline

Definition at line 61 of file palette_editor.h.

References recent_changes_.

◆ GetRecentChanges()

const std::deque< PaletteChange > & yaze::editor::palette_internal::PaletteEditorHistory::GetRecentChanges ( ) const
inline

Definition at line 65 of file palette_editor.h.

References recent_changes_.

Member Data Documentation

◆ recent_changes_

std::deque<PaletteChange> yaze::editor::palette_internal::PaletteEditorHistory::recent_changes_
private

◆ kMaxHistorySize

const size_t yaze::editor::palette_internal::PaletteEditorHistory::kMaxHistorySize = 50
staticprivate

Definition at line 71 of file palette_editor.h.

Referenced by RecordChange().


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