mirror of
https://github.com/mumble-voip/mumble.git
synced 2025-10-26 11:19:16 +00:00
FIX(client): Clear shortcut data also for user-types
Up to now the logic for clearing shortcut data upon a change in the shortcut config window was to see if the type() of the current data matches that of the shortcut's default data. However, for user-defined types QVariant::type() always returns QVariant::UserType and thus different user-defined types could not be distinguished. If we instead use QVariant::userType(), this problem does no longer exist.
This commit is contained in:
parent
7c08eaba1e
commit
a8b98487d4
@ -665,7 +665,7 @@ void GlobalShortcutConfig::on_qtwShortcuts_itemChanged(QTreeWidgetItem *item, in
|
||||
sc.bSuppress = item->checkState(3) == Qt::Checked;
|
||||
|
||||
const ::GlobalShortcut *gs = GlobalShortcutEngine::engine->qmShortcuts.value(sc.iIndex);
|
||||
if (gs && sc.qvData.type() != gs->qvDefault.type()) {
|
||||
if (gs && sc.qvData.userType() != gs->qvDefault.userType()) {
|
||||
item->setData(1, Qt::DisplayRole, gs->qvDefault);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user