6 #include <QStringBuilder>
10 namespace swift::misc::input
15 const QString &action)
16 : m_identifier(identifier), m_combination(combination), m_action(action)
48 m_action = obj.m_action;
49 m_combination = obj.m_combination;
54 if (index.
isMyself()) {
return QVariant::fromValue(*
this); }
58 case IndexIdentifier:
return QVariant::fromValue(m_identifier);
59 case IndexIdentifierAsString:
return QVariant::fromValue(m_identifier.
getMachineName());
60 case IndexAction:
return QVariant::fromValue(m_action);
61 case IndexActionAsString:
return QVariant::fromValue(m_action);
62 case IndexCombination:
return QVariant::fromValue(m_combination);
63 case IndexCombinationAsString:
return QVariant::fromValue(QString(m_combination.
toQString()));
80 m_action = variant.value<QString>();
83 case IndexCombination:
84 case IndexCombinationAsString: m_combination = variant.value<
CHotkeyCombination>();
break;
Value object encapsulating information identifying a component of a modular distributed swift process...
bool hasSameMachineId(const CIdentifier &other) const
Check if other identifier is from the same machine id.
const QString & getMachineName() const
Machine name.
bool hasSameMachineName(const CIdentifier &other) const
Check if the other identifier has the same machine name.
void updateToCurrentMachine()
Update to current machine.
Non-owning reference to a CPropertyIndex with a subset of its features.
CastType frontCasted() const
First element casted to given type, usually the PropertIndex enum.
bool isMyself() const
Myself index, used with nesting.
void setPropertyByIndex(CPropertyIndexRef index, const QVariant &variant)
Set property by index.
QVariant propertyByIndex(CPropertyIndexRef index) const
Property by index.
QString toQString(bool i18n=false) const
Cast as QString.
#define SWIFT_DEFINE_VALUEOBJECT_MIXINS(Namespace, Class)
Explicit template definition of mixins for a CValueObject subclass.