Add clearRoomFilterOnEnter setting, default true

This commit is contained in:
miruka 2019-09-07 16:39:14 -04:00
parent a731013a8c
commit a15fba92cb
2 changed files with 5 additions and 0 deletions

View File

@ -105,6 +105,7 @@ class UISettings(JSONConfigFile):
async def default_data(self) -> JsonData: async def default_data(self) -> JsonData:
return { return {
"alertOnMessageForMsec": 4000, "alertOnMessageForMsec": 4000,
"clearRoomFilterOnEnter": True,
"theme": "Default.qpl", "theme": "Default.qpl",
"writeAliases": {}, "writeAliases": {},
"keys": { "keys": {

View File

@ -89,6 +89,10 @@ Rectangle {
Keys.onReturnPressed: if (event.modifiers & Qt.ShiftModifier) { Keys.onReturnPressed: if (event.modifiers & Qt.ShiftModifier) {
sidePaneList.toggleCollapseAccount() sidePaneList.toggleCollapseAccount()
} else { } else {
if (window.settings.clearRoomFilterOnEnter) {
mainUI.sidePane.toolBar.roomFilter = ""
}
sidePaneList.activate() sidePaneList.activate()
} }