ColumnLayout {
id: rootLayout
- spacing: 0
+ spacing: Style.standardSpacing * 2
property NC.UserStatusSelectorModel userStatusSelectorModel
- Label {
- Layout.topMargin: Style.standardSpacing * 2
- Layout.leftMargin: Style.standardSpacing
- Layout.rightMargin: Style.standardSpacing
- Layout.bottomMargin: Style.standardSpacing
- Layout.alignment: Qt.AlignTop | Qt.AlignHCenter
- font.bold: true
- text: qsTr("Online status")
- color: Style.ncTextColor
- }
-
- GridLayout {
- id: topButtonsLayout
-
- Layout.margins: Style.standardSpacing
- Layout.alignment: Qt.AlignTop
- columns: 2
- rows: 2
- columnSpacing: Style.standardSpacing
- rowSpacing: Style.standardSpacing
-
- property int maxButtonHeight: 0
- function updateMaxButtonHeight(newHeight) {
- maxButtonHeight = Math.max(maxButtonHeight, newHeight)
- }
+ Column {
+ // We use a normal column here because layouts often don't adjust to any custom
+ // alignments for each other. If Item 2 is below Item 1, Item 2 will always set
+ // its alignment in relation to Item 1 being in default alignment of vertically
+ // centered. So when we set Item 2 to align top, even if Item 1 is aligned top,
+ // Item 2 will align itself as if Item 1 were vertically centered.
+ //
+ // Since in this case we want to set everything to align top, we use the Column
+ // which does this well, have it fill the height of the parent ColumnLayout,
+ // pushing the bottom button box down.
- UserStatusSelectorButton {
- checked: NC.UserStatus.Online === userStatusSelectorModel.onlineStatus
- checkable: true
- icon.source: userStatusSelectorModel.onlineIcon
- icon.color: "transparent"
- text: qsTr("Online")
- onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Online
+ id: mainContentsLayout
+ spacing: rootLayout.spacing
- Layout.fillWidth: true
- implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
- Layout.preferredHeight: topButtonsLayout.maxButtonHeight
- onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- }
- UserStatusSelectorButton {
- checked: NC.UserStatus.Away === userStatusSelectorModel.onlineStatus
- checkable: true
- icon.source: userStatusSelectorModel.awayIcon
- icon.color: "transparent"
- text: qsTr("Away")
- onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Away
-
- Layout.fillWidth: true
- implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
- Layout.preferredHeight: topButtonsLayout.maxButtonHeight
- onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
-
- }
- UserStatusSelectorButton {
- checked: NC.UserStatus.DoNotDisturb === userStatusSelectorModel.onlineStatus
- checkable: true
- icon.source: userStatusSelectorModel.dndIcon
- icon.color: "transparent"
- text: qsTr("Do not disturb")
- secondaryText: qsTr("Mute all notifications")
- onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.DoNotDisturb
+ Layout.fillWidth: true
+ Layout.fillHeight: true
+ Layout.alignment: Qt.AlignTop
- Layout.fillWidth: true
- implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
- Layout.preferredHeight: topButtonsLayout.maxButtonHeight
- onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- }
- UserStatusSelectorButton {
- checked: NC.UserStatus.Invisible === userStatusSelectorModel.onlineStatus
- checkable: true
- icon.source: userStatusSelectorModel.invisibleIcon
- icon.color: "transparent"
- text: qsTr("Invisible")
- secondaryText: qsTr("Appear offline")
- onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Invisible
+ ColumnLayout {
+ id: statusButtonsLayout
+ width: parent.width
+ spacing: Style.smallSpacing
+
+ Label {
+ Layout.fillWidth: true
+ Layout.bottomMargin: Style.smallSpacing
+ horizontalAlignment: Text.AlignHCenter
+ font.bold: true
+ text: qsTr("Online status")
+ color: Style.ncTextColor
+ }
- Layout.fillWidth: true
- implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
- Layout.preferredHeight: topButtonsLayout.maxButtonHeight
- onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
- }
- }
+ GridLayout {
+ id: topButtonsLayout
+ columns: 2
+ rows: 2
+ columnSpacing: statusButtonsLayout.spacing
+ rowSpacing: statusButtonsLayout.spacing
- Label {
- Layout.topMargin: Style.standardSpacing * 2
- Layout.leftMargin: Style.standardSpacing
- Layout.rightMargin: Style.standardSpacing
- Layout.bottomMargin: Style.standardSpacing
- Layout.alignment: Qt.AlignTop | Qt.AlignHCenter
- font.bold: true
- text: qsTr("Status message")
- color: Style.ncTextColor
- }
+ property int maxButtonHeight: 0
+ function updateMaxButtonHeight(newHeight) {
+ maxButtonHeight = Math.max(maxButtonHeight, newHeight)
+ }
- RowLayout {
- Layout.topMargin: Style.standardSpacing
- Layout.leftMargin: Style.standardSpacing
- Layout.rightMargin: Style.standardSpacing
- Layout.bottomMargin: Style.standardSpacing * 2
- Layout.alignment: Qt.AlignTop
- Layout.fillWidth: true
+ UserStatusSelectorButton {
+ checked: userStatusSelectorModel.onlineStatus === NC.UserStatus.Online
+ checkable: true
+ icon.source: userStatusSelectorModel.onlineIcon
+ icon.color: "transparent"
+ text: qsTr("Online")
+ onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Online
- spacing: 0
+ Layout.fillWidth: true
+ implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
+ }
+ UserStatusSelectorButton {
+ checked: userStatusSelectorModel.onlineStatus === NC.UserStatus.Away
+ checkable: true
+ icon.source: userStatusSelectorModel.awayIcon
+ icon.color: "transparent"
+ text: qsTr("Away")
+ onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Away
- UserStatusSelectorButton {
- id: fieldButton
+ Layout.fillWidth: true
+ implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
- Layout.preferredWidth: userStatusMessageTextField.height
- Layout.preferredHeight: userStatusMessageTextField.height
+ }
+ UserStatusSelectorButton {
+ checked: userStatusSelectorModel.onlineStatus === NC.UserStatus.DoNotDisturb
+ checkable: true
+ icon.source: userStatusSelectorModel.dndIcon
+ icon.color: "transparent"
+ text: qsTr("Do not disturb")
+ secondaryText: qsTr("Mute all notifications")
+ onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.DoNotDisturb
+
+ Layout.fillWidth: true
+ implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
+ Layout.preferredHeight: topButtonsLayout.maxButtonHeight
+ onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
+ Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
+ }
+ UserStatusSelectorButton {
+ checked: userStatusSelectorModel.onlineStatus === NC.UserStatus.Invisible
+ checkable: true
+ icon.source: userStatusSelectorModel.invisibleIcon
+ icon.color: "transparent"
+ text: qsTr("Invisible")
+ secondaryText: qsTr("Appear offline")
+ onClicked: userStatusSelectorModel.onlineStatus = NC.UserStatus.Invisible
+
+ Layout.fillWidth: true
+ implicitWidth: 200 // Pretty much a hack to ensure all the buttons are equal in width
+ Layout.preferredHeight: topButtonsLayout.maxButtonHeight
+ onImplicitHeightChanged: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
+ Component.onCompleted: topButtonsLayout.updateMaxButtonHeight(implicitHeight)
+ }
+ }
+ }
- text: userStatusSelectorModel.userStatusEmoji
+ ColumnLayout {
+ id: userStatusMessageLayout
+ width: parent.width
+ spacing: Style.smallSpacing
+
+ Label {
+ Layout.fillWidth: true
+ Layout.bottomMargin: Style.smallSpacing
+ horizontalAlignment: Text.AlignHCenter
+ font.bold: true
+ text: qsTr("Status message")
+ color: Style.ncTextColor
+ }
- onClicked: emojiDialog.open()
- onHeightChanged: topButtonsLayout.maxButtonHeight = Math.max(topButtonsLayout.maxButtonHeight, height)
+ RowLayout {
+ Layout.fillWidth: true
+ spacing: 0
+
+ UserStatusSelectorButton {
+ id: fieldButton
+
+ Layout.preferredWidth: userStatusMessageTextField.height
+ Layout.preferredHeight: userStatusMessageTextField.height
+
+ text: userStatusSelectorModel.userStatusEmoji
+
+ onClicked: emojiDialog.open()
+ onHeightChanged: topButtonsLayout.maxButtonHeight = Math.max(topButtonsLayout.maxButtonHeight, height)
+
+ primary: true
+ padding: 0
+ z: hovered ? 2 : 0 // Make sure highlight is seen on top of text field
+
+ property color borderColor: showBorder ? Style.ncBlue : Style.menuBorder
+
+ // We create the square with only the top-left and bottom-left rounded corners
+ // by overlaying different rectangles on top of each other
+ background: Rectangle {
+ radius: Style.slightlyRoundedButtonRadius
+ color: Style.buttonBackgroundColor
+ border.color: fieldButton.borderColor
+ border.width: Style.normalBorderWidth
+
+ Rectangle {
+ anchors.fill: parent
+ anchors.leftMargin: parent.width / 2
+ anchors.rightMargin: -1
+ z: 1
+ color: Style.buttonBackgroundColor
+ border.color: fieldButton.borderColor
+ border.width: Style.normalBorderWidth
+ }
+
+ Rectangle { // We need to cover the blue border of the non-radiused rectangle
+ anchors.fill: parent
+ anchors.leftMargin: parent.width / 4
+ anchors.rightMargin: parent.width / 4
+ anchors.topMargin: Style.normalBorderWidth
+ anchors.bottomMargin: Style.normalBorderWidth
+ z: 2
+ color: Style.buttonBackgroundColor
+ }
+ }
+ }
- primary: true
- padding: 0
- z: hovered ? 2 : 0 // Make sure highlight is seen on top of text field
-
- property color borderColor: showBorder ? Style.ncBlue : Style.menuBorder
-
- // We create the square with only the top-left and bottom-left rounded corners
- // by overlaying different rectangles on top of each other
- background: Rectangle {
- radius: Style.slightlyRoundedButtonRadius
- color: Style.buttonBackgroundColor
- border.color: fieldButton.borderColor
- border.width: Style.normalBorderWidth
-
- Rectangle {
- anchors.fill: parent
- anchors.leftMargin: parent.width / 2
- anchors.rightMargin: -1
- z: 1
- color: Style.buttonBackgroundColor
- border.color: fieldButton.borderColor
- border.width: Style.normalBorderWidth
+ Popup {
+ id: emojiDialog
+ padding: 0
+ margins: 0
+ clip: true
+
+ anchors.centerIn: Overlay.overlay
+
+ background: Rectangle {
+ color: Style.backgroundColor
+ border.width: Style.normalBorderWidth
+ border.color: Style.menuBorder
+ radius: Style.slightlyRoundedButtonRadius
+ }
+
+ EmojiPicker {
+ id: emojiPicker
+
+ onChosen: {
+ userStatusSelectorModel.userStatusEmoji = emoji
+ emojiDialog.close()
+ }
+ }
}
- Rectangle { // We need to cover the blue border of the non-radiused rectangle
- anchors.fill: parent
- anchors.leftMargin: parent.width / 4
- anchors.rightMargin: parent.width / 4
- anchors.topMargin: Style.normalBorderWidth
- anchors.bottomMargin: Style.normalBorderWidth
- z: 2
- color: Style.buttonBackgroundColor
+ TextField {
+ id: userStatusMessageTextField
+ Layout.fillWidth: true
+ placeholderText: qsTr("What is your status?")
+ placeholderTextColor: Style.ncSecondaryTextColor
+ text: userStatusSelectorModel.userStatusMessage
+ color: Style.ncTextColor
+ selectByMouse: true
+ onEditingFinished: userStatusSelectorModel.userStatusMessage = text
+
+ property color borderColor: activeFocus ? Style.ncBlue : Style.menuBorder
+
+ background: Rectangle {
+ radius: Style.slightlyRoundedButtonRadius
+ color: Style.backgroundColor
+ border.color: userStatusMessageTextField.borderColor
+ border.width: Style.normalBorderWidth
+
+ Rectangle {
+ anchors.fill: parent
+ anchors.rightMargin: parent.width / 2
+ z: 1
+ color: Style.backgroundColor
+ border.color: userStatusMessageTextField.borderColor
+ border.width: Style.normalBorderWidth
+ }
+
+ Rectangle { // We need to cover the blue border of the non-radiused rectangle
+ anchors.fill: parent
+ anchors.leftMargin: parent.width / 4
+ anchors.rightMargin: parent.width / 4
+ anchors.topMargin: Style.normalBorderWidth
+ anchors.bottomMargin: Style.normalBorderWidth
+ z: 2
+ color: Style.backgroundColor
+ }
+ }
}
}
- }
- Popup {
- id: emojiDialog
- padding: 0
- margins: 0
- clip: true
+ ColumnLayout {
+ Layout.fillWidth: true
+ spacing: 0
- anchors.centerIn: Overlay.overlay
+ Repeater {
+ model: userStatusSelectorModel.predefinedStatuses
- background: Rectangle {
- color: Style.backgroundColor
- border.width: Style.normalBorderWidth
- border.color: Style.menuBorder
- radius: Style.slightlyRoundedButtonRadius
- }
-
- EmojiPicker {
- id: emojiPicker
+ PredefinedStatusButton {
+ id: control
+ Layout.fillWidth: true
+ internalSpacing: Style.standardSpacing + fieldButton.padding + userStatusMessageTextField.padding
- onChosen: {
- userStatusSelectorModel.userStatusEmoji = emoji
- emojiDialog.close()
+ emoji: modelData.icon
+ text: "<b>%1</b> – %2".arg(modelData.message).arg(userStatusSelectorModel.clearAtReadable(modelData))
+ onClicked: userStatusSelectorModel.setPredefinedStatus(modelData)
+ }
}
}
- }
- TextField {
- id: userStatusMessageTextField
- Layout.fillWidth: true
- placeholderText: qsTr("What is your status?")
- placeholderTextColor: Style.ncSecondaryTextColor
- text: userStatusSelectorModel.userStatusMessage
- color: Style.ncTextColor
- selectByMouse: true
- onEditingFinished: userStatusSelectorModel.userStatusMessage = text
-
- property color borderColor: activeFocus ? Style.ncBlue : Style.menuBorder
-
- background: Rectangle {
- radius: Style.slightlyRoundedButtonRadius
- color: Style.backgroundColor
- border.color: userStatusMessageTextField.borderColor
- border.width: Style.normalBorderWidth
-
- Rectangle {
- anchors.fill: parent
- anchors.rightMargin: parent.width / 2
- z: 1
- color: Style.backgroundColor
- border.color: userStatusMessageTextField.borderColor
- border.width: Style.normalBorderWidth
+ RowLayout {
+ Layout.fillWidth: true
+ spacing: Style.standardSpacing
+
+ Label {
+ text: qsTr("Clear status message after")
+ color: Style.ncTextColor
}
- Rectangle { // We need to cover the blue border of the non-radiused rectangle
- anchors.fill: parent
- anchors.leftMargin: parent.width / 4
- anchors.rightMargin: parent.width / 4
- anchors.topMargin: Style.normalBorderWidth
- anchors.bottomMargin: Style.normalBorderWidth
- z: 2
- color: Style.backgroundColor
+ BasicComboBox {
+ id: clearComboBox
+ Layout.fillWidth: true
+ model: userStatusSelectorModel.clearStageTypes
+ textRole: "display"
+ valueRole: "clearStageType"
+ displayText: userStatusSelectorModel.clearAtDisplayString
+ onActivated: userStatusSelectorModel.setClearAt(currentValue)
}
}
}
- }
-
- Repeater {
- model: userStatusSelectorModel.predefinedStatuses
- PredefinedStatusButton {
- id: control
- Layout.fillWidth: true
- Layout.leftMargin: Style.standardSpacing
- Layout.rightMargin: Style.standardSpacing
- internalSpacing: Style.standardSpacing + fieldButton.padding + userStatusMessageTextField.padding
+ ErrorBox {
+ width: parent.width
- emoji: modelData.icon
- text: "<b>%1</b> – %2".arg(modelData.message).arg(userStatusSelectorModel.clearAtReadable(modelData))
- onClicked: userStatusSelectorModel.setPredefinedStatus(modelData)
+ visible: userStatusSelectorModel.errorMessage != ""
+ text: "<b>Error:</b> " + userStatusSelectorModel.errorMessage
}
}
- RowLayout {
- Layout.topMargin: Style.standardSpacing * 2
- Layout.leftMargin: Style.standardSpacing
- Layout.rightMargin: Style.standardSpacing
- Layout.bottomMargin: Style.standardSpacing
- Layout.alignment: Qt.AlignTop
- spacing: Style.standardSpacing
-
- Label {
- text: qsTr("Clear status message after")
- color: Style.ncTextColor
- }
-
- BasicComboBox {
- id: clearComboBox
-
- Layout.fillWidth: true
- model: userStatusSelectorModel.clearStageTypes
- textRole: "display"
- valueRole: "clearStageType"
- displayText: userStatusSelectorModel.clearAtDisplayString
- onActivated: userStatusSelectorModel.setClearAt(currentValue)
- }
- }
-
RowLayout {
- Layout.margins: Style.standardSpacing
- Layout.alignment: Qt.AlignTop
-
+ Layout.fillWidth: true
+ Layout.alignment: Qt.AlignBottom
+
+ UserStatusSelectorButton {
+ Layout.fillWidth: true
+ primary: true
+ text: qsTr("Cancel")
+ onClicked: finished()
+ }
UserStatusSelectorButton {
Layout.fillWidth: true
primary: true
onClicked: userStatusSelectorModel.clearUserStatus()
}
UserStatusSelectorButton {
+ Layout.fillWidth: true
primary: true
colored: true
- Layout.fillWidth: true
text: qsTr("Set status message")
onClicked: userStatusSelectorModel.setUserStatus()
}
}
-
- ErrorBox {
- Layout.margins: Style.standardSpacing
- Layout.fillWidth: true
-
- visible: userStatusSelectorModel.errorMessage != ""
- text: "<b>Error:</b> " + userStatusSelectorModel.errorMessage
- }
}
-import QtQml 2.12\r
-import QtQml.Models 2.1\r
import QtQuick 2.15\r
import QtQuick.Window 2.3\r
import QtQuick.Controls 2.3\r
\r
import com.nextcloud.desktopclient 1.0\r
\r
-Window {\r
+ApplicationWindow {\r
id: trayWindow\r
\r
title: Systray.windowTitle\r
syncStatus.model.load();\r
}\r
\r
+ background: Rectangle {\r
+ radius: Systray.useNormalWindow ? 0.0 : Style.trayWindowRadius\r
+ border.width: Style.trayWindowBorderWidth\r
+ border.color: Style.menuBorder\r
+ color: Style.backgroundColor\r
+ }\r
+\r
Connections {\r
target: UserModel\r
function onCurrentUserChanged() {\r
target: Systray\r
\r
function onIsOpenChanged() {\r
+ userStatusDrawer.close()\r
+\r
if(Systray.isOpen) {\r
accountMenu.close();\r
appsMenu.close();\r
OpacityMask {\r
anchors.fill: parent\r
source: ShaderEffectSource {\r
- sourceItem: trayWindowBackground\r
+ sourceItem: trayWindowMainItem\r
hideSource: true\r
}\r
maskSource: Rectangle {\r
- width: trayWindowBackground.width\r
- height: trayWindowBackground.height\r
+ width: trayWindow.width\r
+ height: trayWindow.height\r
radius: Systray.useNormalWindow ? 0.0 : Style.trayWindowRadius\r
}\r
}\r
\r
- Rectangle {\r
- id: trayWindowBackground\r
+ Drawer {\r
+ id: userStatusDrawer\r
+ width: parent.width\r
+ height: parent.height\r
+ padding: 0\r
+ edge: Qt.BottomEdge\r
+ modal: false\r
+ visible: false\r
+\r
+ background: Rectangle {\r
+ radius: Systray.useNormalWindow ? 0.0 : Style.trayWindowRadius\r
+ border.width: Style.trayWindowBorderWidth\r
+ border.color: Style.menuBorder\r
+ color: Style.backgroundColor\r
+ }\r
+\r
+ property int userIndex: 0\r
+\r
+ function openUserStatusDrawer(index) {\r
+ console.log(`About to show dialog for user with index ${index}`);\r
+ userIndex = index;\r
+ open();\r
+ }\r
+\r
+ Loader {\r
+ id: userStatusContents\r
+ anchors.fill: parent\r
+ active: userStatusDrawer.visible\r
+ sourceComponent: UserStatusSelectorPage {\r
+ anchors.fill: parent\r
+ userIndex: userStatusDrawer.userIndex\r
+ onFinished: userStatusDrawer.close()\r
+ }\r
+ }\r
+ }\r
+\r
+ Item {\r
+ id: trayWindowMainItem\r
\r
property bool isUnifiedSearchActive: unifiedSearchResultsListViewSkeletonLoader.active\r
|| unifiedSearchResultNothingFound.visible\r
|| unifiedSearchResultsListView.visible\r
\r
anchors.fill: parent\r
- radius: Systray.useNormalWindow ? 0.0 : Style.trayWindowRadius\r
- border.width: Style.trayWindowBorderWidth\r
- border.color: Style.menuBorder\r
- color: Style.backgroundColor\r
+ clip: true\r
\r
Accessible.role: Accessible.Grouping\r
Accessible.name: qsTr("Nextcloud desktop main dialog")\r
Rectangle {\r
id: trayWindowHeaderBackground\r
\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
- anchors.top: trayWindowBackground.top\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
+ anchors.top: trayWindowMainItem.top\r
height: Style.trayWindowHeaderHeight\r
color: UserModel.currentUser.headerColor\r
\r
userLineInstantiator.active = true;\r
}\r
\r
- Loader {\r
- id: userStatusSelectorDialogLoader\r
-\r
- property int userIndex\r
-\r
- function openDialog(newUserIndex) {\r
- console.log(`About to show dialog for user with index ${newUserIndex}`);\r
- userIndex = newUserIndex;\r
- active = true;\r
- item.show();\r
- }\r
-\r
- active: false\r
- sourceComponent: UserStatusSelectorDialog {\r
- userIndex: userStatusSelectorDialogLoader.userIndex\r
- }\r
-\r
- onLoaded: {\r
- item.model.load(userIndex);\r
- item.show();\r
- }\r
- }\r
-\r
Instantiator {\r
id: userLineInstantiator\r
model: UserModel\r
delegate: UserLine {\r
- onShowUserStatusSelectorDialog: {\r
- userStatusSelectorDialogLoader.openDialog(model.index);\r
+ onShowUserStatusSelector: {\r
+ userStatusDrawer.openUserStatusDrawer(model.index);\r
accountMenu.close();\r
}\r
}\r
\r
anchors {\r
top: trayWindowHeaderBackground.bottom\r
- left: trayWindowBackground.left\r
- right: trayWindowBackground.right\r
+ left: trayWindowMainItem.left\r
+ right: trayWindowMainItem.right\r
\r
topMargin: Style.trayHorizontalMargin + controlRoot.padding\r
leftMargin: Style.trayHorizontalMargin + controlRoot.padding\r
visible: UserModel.currentUser.unifiedSearchResultsListModel.errorString && !unifiedSearchResultsListView.visible && ! UserModel.currentUser.unifiedSearchResultsListModel.isSearchInProgress && ! UserModel.currentUser.unifiedSearchResultsListModel.currentFetchMoreInProgressProviderId\r
text: UserModel.currentUser.unifiedSearchResultsListModel.errorString\r
anchors.top: trayWindowUnifiedSearchInputContainer.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
anchors.margins: Style.trayHorizontalMargin\r
}\r
\r
id: unifiedSearchResultNothingFound\r
visible: false\r
anchors.top: trayWindowUnifiedSearchInputContainer.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
anchors.topMargin: Style.trayHorizontalMargin\r
\r
text: UserModel.currentUser.unifiedSearchResultsListModel.searchTerm\r
Loader {\r
id: unifiedSearchResultsListViewSkeletonLoader\r
anchors.top: trayWindowUnifiedSearchInputContainer.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
- anchors.bottom: trayWindowBackground.bottom\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
+ anchors.bottom: trayWindowMainItem.bottom\r
\r
active: !unifiedSearchResultNothingFound.visible &&\r
!unifiedSearchResultsListView.visible &&\r
visible: unifiedSearchResultsListView.count > 0\r
\r
anchors.top: trayWindowUnifiedSearchInputContainer.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
- anchors.bottom: trayWindowBackground.bottom\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
+ anchors.bottom: trayWindowMainItem.bottom\r
\r
ListView {\r
id: unifiedSearchResultsListView\r
SyncStatus {\r
id: syncStatus\r
\r
- visible: !trayWindowBackground.isUnifiedSearchActive\r
+ visible: !trayWindowMainItem.isUnifiedSearchActive\r
\r
anchors.top: trayWindowUnifiedSearchInputContainer.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
}\r
\r
ActivityList {\r
- visible: !trayWindowBackground.isUnifiedSearchActive\r
+ visible: !trayWindowMainItem.isUnifiedSearchActive\r
anchors.top: syncStatus.bottom\r
- anchors.left: trayWindowBackground.left\r
- anchors.right: trayWindowBackground.right\r
- anchors.bottom: trayWindowBackground.bottom\r
+ anchors.left: trayWindowMainItem.left\r
+ anchors.right: trayWindowMainItem.right\r
+ anchors.bottom: trayWindowMainItem.bottom\r
\r
activeFocusOnTab: true\r
model: activityModel\r
\r
onLoaded: refresh()\r
}\r
- } // Rectangle trayWindowBackground\r
+ } // Item trayWindowMainItem\r
}\r