mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Fix support / media shortcuts.
This commit is contained in:
parent
aae5024b28
commit
e823fe5891
1 changed files with 2 additions and 3 deletions
|
@ -427,7 +427,6 @@ void Manager::set(const QString &keys, Command command, bool replace) {
|
||||||
} else if (replace) {
|
} else if (replace) {
|
||||||
unregister(std::exchange(i->second, std::move(shortcut)));
|
unregister(std::exchange(i->second, std::move(shortcut)));
|
||||||
} else {
|
} else {
|
||||||
shortcut = nullptr;
|
|
||||||
id = i->second->id();
|
id = i->second->id();
|
||||||
}
|
}
|
||||||
if (!id) {
|
if (!id) {
|
||||||
|
@ -435,10 +434,10 @@ void Manager::set(const QString &keys, Command command, bool replace) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
_commandByShortcutId.emplace(id, command);
|
_commandByShortcutId.emplace(id, command);
|
||||||
if (shortcut && isMediaShortcut) {
|
if (!shortcut && isMediaShortcut) {
|
||||||
_mediaShortcuts.emplace(i->second.get());
|
_mediaShortcuts.emplace(i->second.get());
|
||||||
}
|
}
|
||||||
if (shortcut && isSupportShortcut) {
|
if (!shortcut && isSupportShortcut) {
|
||||||
_supportShortcuts.emplace(i->second.get());
|
_supportShortcuts.emplace(i->second.get());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue