diff --git a/src/gui/Pages/Chat/Chat.qml b/src/gui/Pages/Chat/Chat.qml index c614e4c4..0274122a 100644 --- a/src/gui/Pages/Chat/Chat.qml +++ b/src/gui/Pages/Chat/Chat.qml @@ -75,21 +75,24 @@ Item { HLoader { id: loader anchors.rightMargin: - ready && + ready && roomPane && ! ( roomPane.requireDefaultSize && - roomPane.minimumSize > roomPane.maximumSize + roomPane.minimumSize > roomPane.maximumSize && + ! roomPane.collapse ) ? roomPane.visibleSize : 0 anchors.fill: parent - visible: - ready ? ! roomPane.hidden || anchors.rightMargin < width : true + visible: ! (ready && roomPane && roomPane.visibleSize >= chat.width) + onLoaded: if (chat.focus) item.composer.takeFocus() source: ready ? "ChatPage.qml" : "" + Behavior on anchors.rightMargin { HNumberAnimation {} } + HLoader { anchors.centerIn: parent width: 96 * theme.uiScale diff --git a/src/gui/UI.qml b/src/gui/UI.qml index 3f1354c4..25906f5d 100644 --- a/src/gui/UI.qml +++ b/src/gui/UI.qml @@ -134,9 +134,9 @@ Item { anchors.leftMargin: mainPane.requireDefaultSize && mainPane.minimumSize > mainPane.maximumSize ? - theme.mainPane.minimumSize : + 0 : mainPane.visibleSize - visible: ! mainPane.hidden || anchors.leftMargin < width + visible: mainPane.visibleSize < mainUI.width } }