diff --git a/src/blackgui/components/settingshotkeycomponent.cpp b/src/blackgui/components/settingshotkeycomponent.cpp index b65613100..923a0dec6 100644 --- a/src/blackgui/components/settingshotkeycomponent.cpp +++ b/src/blackgui/components/settingshotkeycomponent.cpp @@ -131,9 +131,13 @@ namespace BlackGui void CSettingsHotkeyComponent::updateHotkeyInSettings(const CActionHotkey &oldValue, const CActionHotkey &newValue) { - CActionHotkeyList actionHotkeyList(m_actionHotkeys.getThreadLocal()); - actionHotkeyList.replace(oldValue, newValue); - m_actionHotkeys.set(actionHotkeyList); + //! \todo KB 2020-06 since there are many users reporting issues with replacing hotkey we use remove/add + this->removeHotkeyFromSettings(oldValue); + this->addHotkeyToSettings(newValue); + + // CActionHotkeyList actionHotkeyList(m_actionHotkeys.getThreadLocal()); + // actionHotkeyList.replace(oldValue, newValue); + // m_actionHotkeys.set(actionHotkeyList); } void CSettingsHotkeyComponent::removeHotkeyFromSettings(const CActionHotkey &actionHotkey) diff --git a/src/blackmisc/identifier.cpp b/src/blackmisc/identifier.cpp index 62b78c373..c9a2b078f 100644 --- a/src/blackmisc/identifier.cpp +++ b/src/blackmisc/identifier.cpp @@ -196,14 +196,14 @@ namespace BlackMisc void CIdentifier::updateToCurrentMachine() { - m_machineIdBase64 = cachedMachineUniqueId().toBase64(); - m_machineName = cachedLocalHostName(); + m_machineIdBase64 = cachedMachineUniqueId().toBase64(); + m_machineName = cachedLocalHostName(); } void CIdentifier::updateToCurrentProcess() { m_processName = QCoreApplication::applicationName(); - m_processId = QCoreApplication::applicationPid(); + m_processId = QCoreApplication::applicationPid(); } QString CIdentifier::convertToQString(bool i18n) const diff --git a/src/blackmisc/input/actionhotkeylist.cpp b/src/blackmisc/input/actionhotkeylist.cpp index f24bdcebc..c01fb40e3 100644 --- a/src/blackmisc/input/actionhotkeylist.cpp +++ b/src/blackmisc/input/actionhotkeylist.cpp @@ -66,8 +66,11 @@ namespace BlackMisc const CIdentifier comparison("comparison for local machine"); for (CActionHotkey &actionHotkey : *this) { - const bool sameMachine = actionHotkey.getIdentifier().hasSameMachineNameOrId(comparison); - if (sameMachine) { actionHotkey.updateToCurrentMachine(); } + // to avoid issue we always update + actionHotkey.updateToCurrentMachine(); + + // const bool sameMachine = actionHotkey.getIdentifier().hasSameMachineNameOrId(comparison); + // if (sameMachine) { actionHotkey.updateToCurrentMachine(); } } } } // ns