diff --git a/src/python/config_files.py b/src/python/config_files.py index 4e40296c..97b214ca 100644 --- a/src/python/config_files.py +++ b/src/python/config_files.py @@ -115,20 +115,22 @@ class UISettings(JSONConfigFile): "theme": "Default.qpl", "writeAliases": {}, "keys": { + "startDebugger": ["Alt+Shift+D"], "reloadConfig": "Alt+Shift+R", + "scrollUp": ["Alt+Up", "Alt+K"], "scrollDown": ["Alt+Down", "Alt+J"], + "focusSidePane": ["Alt+S", "Ctrl+S"], "clearRoomFilter": ["Alt+Shift+S", "Ctrl+Shift+S"], - "goToPreviousRoom": ["Alt+Shift+Up", "Alt+Shift+K"], - "goToNextRoom": ["Alt+Shift+Down", "Alt+Shift+J"], + "addNewAccount": ["Alt+N"], + "goToPreviousRoom": ["Alt+Shift+Up", "Alt+Shift+K"], + "goToNextRoom": ["Alt+Shift+Down", "Alt+Shift+J"], "toggleCollapseAccount": [ "Alt+Shift+Left", "Alt+Shift+Right", "Alt+Shift+H", "Alt+Shift+L", ], - - "startDebugger": ["Alt+Shift+D"], }, } diff --git a/src/qml/Shortcuts.qml b/src/qml/Shortcuts.qml index 32a3a48d..b5acfc1a 100644 --- a/src/qml/Shortcuts.qml +++ b/src/qml/Shortcuts.qml @@ -44,6 +44,11 @@ HShortcutHandler { onPressed: mainUI.sidePane.paneToolBar.roomFilter = "" } + HShortcut { + sequences: settings.keys.addNewAccount + onPressed: mainUI.sidePane.paneToolBar.addAccountButton.clicked() + } + HShortcut { sequences: settings.keys.goToPreviousRoom onPressed: mainUI.sidePane.accountRoomList.previous() diff --git a/src/qml/SidePane/PaneToolBar.qml b/src/qml/SidePane/PaneToolBar.qml index 6b9a4923..d58dfdd8 100644 --- a/src/qml/SidePane/PaneToolBar.qml +++ b/src/qml/SidePane/PaneToolBar.qml @@ -5,7 +5,8 @@ import "../Base" HRowLayout { id: toolBar - property alias filterField: filterField + readonly property alias addAccountButton: addAccountButton + readonly property alias filterField: filterField property alias roomFilter: filterField.text Layout.fillWidth: true @@ -13,6 +14,7 @@ HRowLayout { Layout.maximumHeight: Layout.minimumHeight HButton { + id: addAccountButton icon.name: "add-account" toolTip.text: qsTr("Add another account") backgroundColor: theme.sidePane.settingsButton.background