25#include <QKeySequence>
41 : m_description(
std::move(description)),
42 m_keys(QKeySequence(keys).
toString().split(
", "))
54 return m_keys.contains(key);
70 if (key.isEmpty() ||
HasKey(key) ||
91 int idx =
m_keys.indexOf(oldkey);
Main header for the action class.
bool HasKey(const QString &key) const
Determine if the action already has a key.
static const unsigned int kMaximumNumberOfBindings
The maximum number of keys that can be bound to an action.
Action(QString description)
Create a new empty action.
bool AddKey(const QString &key)
Add a key sequence to this action.
bool ReplaceKey(const QString &newkey, const QString &oldkey)
Replace a key.
QStringList m_keys
The keys bound to the action.
QString toString(const QDateTime &raw_dt, uint format)
Returns formatted string representing the time.