openMSX
|
#include <Shortcuts.hh>
Classes | |
struct | Shortcut |
struct | ShortcutWithRepeat |
Public Types | |
enum class | ID { HEX_GOTO_ADDR , DEBUGGER_STEP_IN , DEBUGGER_STEP_OVER , DEBUGGER_STEP_OUT , DEBUGGER_STEP_BACK , DEBUGGER_BREAK_CONTINUE , DISASM_GOTO_ADDR , DISASM_RUN_TO_ADDR , DISASM_TOGGLE_BREAKPOINT , NUM , INVALID = NUM } |
enum class | Type { LOCAL , GLOBAL , ALWAYS_LOCAL , ALWAYS_GLOBAL } |
Public Member Functions | |
Shortcuts () | |
Shortcuts (const Shortcuts &)=delete | |
Shortcuts (Shortcuts &&)=delete | |
Shortcuts & | operator= (const Shortcuts &)=delete |
Shortcuts & | operator= (Shortcuts &&)=delete |
~Shortcuts ()=default | |
const Shortcut & | getShortcut (ID id) const |
void | setShortcut (ID id, const Shortcut &shortcut) |
void | setDefaultShortcuts () |
bool | checkShortcut (const ShortcutWithRepeat &shortcut) const |
bool | checkShortcut (ID id) const |
template<typename XmlStream > | |
void | saveShortcuts (XmlStream &xml) const |
Static Public Member Functions | |
static bool | getShortcutRepeat (ID id) |
static zstring_view | getShortcutName (ID id) |
static zstring_view | getShortcutDescription (ID id) |
static std::optional< ID > | parseShortcutName (std::string_view name) |
static std::optional< Type > | parseType (std::string_view name) |
static const Shortcut & | getDefaultShortcut (ID id) |
Definition at line 15 of file Shortcuts.hh.
|
strong |
Enumerator | |
---|---|
HEX_GOTO_ADDR | |
DEBUGGER_STEP_IN | |
DEBUGGER_STEP_OVER | |
DEBUGGER_STEP_OUT | |
DEBUGGER_STEP_BACK | |
DEBUGGER_BREAK_CONTINUE | |
DISASM_GOTO_ADDR | |
DISASM_RUN_TO_ADDR | |
DISASM_TOGGLE_BREAKPOINT | |
NUM | |
INVALID |
Definition at line 18 of file Shortcuts.hh.
|
strong |
Enumerator | |
---|---|
LOCAL | |
GLOBAL | |
ALWAYS_LOCAL | |
ALWAYS_GLOBAL |
Definition at line 32 of file Shortcuts.hh.
openmsx::Shortcuts::Shortcuts | ( | ) |
Definition at line 76 of file Shortcuts.cc.
References setDefaultShortcuts().
|
delete |
|
delete |
|
default |
bool openmsx::Shortcuts::checkShortcut | ( | const ShortcutWithRepeat & | shortcut | ) | const |
Definition at line 135 of file Shortcuts.cc.
References ALWAYS_GLOBAL, GLOBAL, openmsx::Shortcuts::ShortcutWithRepeat::keyChord, openmsx::Shortcuts::ShortcutWithRepeat::repeat, and openmsx::Shortcuts::ShortcutWithRepeat::type.
Referenced by checkShortcut().
bool openmsx::Shortcuts::checkShortcut | ( | ID | id | ) | const |
Definition at line 143 of file Shortcuts.cc.
References checkShortcut(), getShortcutRepeat(), and id.
|
static |
const Shortcuts::Shortcut & openmsx::Shortcuts::getShortcut | ( | Shortcuts::ID | id | ) | const |
Definition at line 91 of file Shortcuts.cc.
References id.
|
static |
Definition at line 130 of file Shortcuts.cc.
References id.
|
static |
|
static |
|
static |
Definition at line 116 of file Shortcuts.cc.
References ranges::find().
Referenced by openmsx::SettingsParser::text().
|
static |
Definition at line 123 of file Shortcuts.cc.
Referenced by openmsx::SettingsParser::attribute().
|
inline |
Definition at line 74 of file Shortcuts.hh.
References enumerate(), getDefaultShortcut(), openmsx::getKeyChordName(), getShortcutName(), and GLOBAL.
Referenced by openmsx::SettingsConfig::saveSetting().
void openmsx::Shortcuts::setDefaultShortcuts | ( | ) |
Definition at line 81 of file Shortcuts.cc.
Referenced by openmsx::SettingsConfig::loadSetting(), and Shortcuts().
Definition at line 96 of file Shortcuts.cc.
References ALWAYS_GLOBAL, ALWAYS_LOCAL, and id.
Referenced by openmsx::SettingsConfig::loadSetting().