Add setting controlling when panes should collapse

This commit is contained in:
miruka 2020-03-17 15:37:55 -04:00
parent 84734599e3
commit 5392016dab
2 changed files with 3 additions and 1 deletions

View File

@ -196,6 +196,7 @@ class UISettings(JSONDataFile):
"alertOnMessageForMsec": 4000,
"clearRoomFilterOnEnter": True,
"clearRoomFilterOnEscape": True,
"collapseSidePanesUnderWindowWidth": 400,
"theme": "Midnight.qpl",
"writeAliases": {},
"media": {

View File

@ -54,7 +54,8 @@ Drawer {
property Item referenceSizeParent: parent
property bool collapse:
(horizontal ? window.width : window.height) < 400 * theme.uiScale
(horizontal ? window.width : window.height) <
window.settings.collapseSidePanesUnderWindowWidth * theme.uiScale
property int peekSizeWhileCollapsed:
horizontal ? referenceSizeParent.width : referenceSizeParent.height