mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 18:32:50 +00:00
khotkeys: do not rely on QString operator
aside from fixing the build against Katie it removes the need to convert the QUuid to QString multiple times by storing it as QString. that also saves a conversion when _uuid it overriden from the object name but that's just a bonus. Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
c1e6ba7aca
commit
274568b838
3 changed files with 4 additions and 4 deletions
|
@ -70,7 +70,7 @@ KAction *ShortcutsHandler::addAction(
|
|||
if (_actions->action(id))
|
||||
{
|
||||
qDebug() << id << " already present. Using new id!";
|
||||
realId = QUuid::createUuid();
|
||||
realId = QUuid::createUuid().toString();
|
||||
}
|
||||
|
||||
// Create the action
|
||||
|
|
|
@ -38,7 +38,7 @@ ShortcutTrigger::ShortcutTrigger(
|
|||
const KShortcut& shortcut,
|
||||
const QUuid &uuid )
|
||||
: Trigger( data_P ),
|
||||
_uuid(uuid),
|
||||
_uuid(uuid.toString()),
|
||||
_active(false),
|
||||
_shortcut(shortcut)
|
||||
{
|
||||
|
@ -122,7 +122,7 @@ void ShortcutTrigger::cfg_write( KConfigGroup& cfg_P ) const
|
|||
base::cfg_write( cfg_P );
|
||||
cfg_P.writeEntry( "Key", shortcut().toString());
|
||||
cfg_P.writeEntry( "Type", "SHORTCUT" ); // overwrites value set in base::cfg_write()
|
||||
cfg_P.writeEntry( "Uuid", _uuid.toString() );
|
||||
cfg_P.writeEntry( "Uuid", _uuid );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -196,7 +196,7 @@ class KDE_EXPORT ShortcutTrigger
|
|||
private:
|
||||
|
||||
//! A persistent identifier for this shortcut
|
||||
QUuid _uuid;
|
||||
QString _uuid;
|
||||
|
||||
//! Are the conditions met?
|
||||
bool _active;
|
||||
|
|
Loading…
Add table
Reference in a new issue