mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-02 15:15:39 +08:00
refs #881, minor formatting/improvements
This commit is contained in:
committed by
Mathew Sutcliffe
parent
f581a40b75
commit
8741b66578
@@ -63,7 +63,7 @@ namespace BlackGui
|
|||||||
m_oldIndex = index;
|
m_oldIndex = index;
|
||||||
}
|
}
|
||||||
|
|
||||||
CHotkeyDialog::CHotkeyDialog(const BlackMisc::Input::CActionHotkey &actionHotkey, QWidget *parent) :
|
CHotkeyDialog::CHotkeyDialog(const CActionHotkey &actionHotkey, QWidget *parent) :
|
||||||
QDialog(parent),
|
QDialog(parent),
|
||||||
ui(new Ui::CHotkeyDialog),
|
ui(new Ui::CHotkeyDialog),
|
||||||
m_actionHotkey(actionHotkey),
|
m_actionHotkey(actionHotkey),
|
||||||
@@ -92,8 +92,7 @@ namespace BlackGui
|
|||||||
}
|
}
|
||||||
|
|
||||||
CHotkeyDialog::~CHotkeyDialog()
|
CHotkeyDialog::~CHotkeyDialog()
|
||||||
{
|
{ }
|
||||||
}
|
|
||||||
|
|
||||||
void CHotkeyDialog::setRegisteredApplications(const BlackMisc::CIdentifierList &applications)
|
void CHotkeyDialog::setRegisteredApplications(const BlackMisc::CIdentifierList &applications)
|
||||||
{
|
{
|
||||||
@@ -211,10 +210,10 @@ namespace BlackGui
|
|||||||
clearAdvancedFrame();
|
clearAdvancedFrame();
|
||||||
auto allSupportedKeys = CKeyboardKeyList::allSupportedKeys();
|
auto allSupportedKeys = CKeyboardKeyList::allSupportedKeys();
|
||||||
|
|
||||||
QStringList splittedKeys = m_actionHotkey.getCombination().toQString().split('+', QString::SkipEmptyParts);
|
const QStringList splitKeys = m_actionHotkey.getCombination().toQString().split('+', QString::SkipEmptyParts);
|
||||||
for (const auto &splittedKey : splittedKeys)
|
for (const auto &splitKey : splitKeys)
|
||||||
{
|
{
|
||||||
if (splittedKey == "+") continue;
|
if (splitKey == "+") continue;
|
||||||
|
|
||||||
int currentIndex = -1;
|
int currentIndex = -1;
|
||||||
CKeySelectionBox *ksb = new CKeySelectionBox(ui->qf_Advanced);
|
CKeySelectionBox *ksb = new CKeySelectionBox(ui->qf_Advanced);
|
||||||
@@ -222,7 +221,7 @@ namespace BlackGui
|
|||||||
{
|
{
|
||||||
QString supportedKeyAsString = supportedKey.toQString();
|
QString supportedKeyAsString = supportedKey.toQString();
|
||||||
ksb->addItem(supportedKeyAsString, QVariant::fromValue(supportedKey));
|
ksb->addItem(supportedKeyAsString, QVariant::fromValue(supportedKey));
|
||||||
if (supportedKeyAsString == splittedKey)
|
if (supportedKeyAsString == splitKey)
|
||||||
{
|
{
|
||||||
currentIndex = ksb->count() - 1;
|
currentIndex = ksb->count() - 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user