Sayonara Player
|
#include <ShortcutHandler.h>
A singleton class for retrieving shortcuts.
Public Member Functions | |
Shortcut | get_shortcut (const QString &identifier) const |
get a shortcut by its unique identifier More... | |
void | set_shortcut (const QString &identifier, const QStringList &shortcut) |
set the shortcut by its unique identifier More... | |
void | set_shortcut (const Shortcut &shortcut) |
Overwrite a shortcut. More... | |
Shortcut | add (const Shortcut &shortcut) |
add a new shortcut instance to the handler. This is usually done by the widget the shortcut is attached to. So you can use the same shortcut on multiple widgets More... | |
QList< Shortcut > | get_shortcuts () const |
get all shortcuts More... | |
Protected Attributes | |
Settings * | _settings =nullptr |
add a new shortcut instance to the handler. This is usually done by the widget the shortcut is attached to. So you can use the same shortcut on multiple widgets
shortcut | a shortcut instance |
Shortcut ShortcutHandler::get_shortcut | ( | const QString & | identifier | ) | const |
get a shortcut by its unique identifier
identifier | the identifier which is used in database |
void ShortcutHandler::set_shortcut | ( | const QString & | identifier, |
const QStringList & | shortcut | ||
) |
set the shortcut by its unique identifier
identifier | the identifier which is used in database |
shortcut | a shortcut instance |
void ShortcutHandler::set_shortcut | ( | const Shortcut & | shortcut | ) |
Overwrite a shortcut.
shortcut | a shortcut instance |