2019-12-19 22:46:16 +11:00
|
|
|
// SPDX-License-Identifier: LGPL-3.0-or-later
|
|
|
|
|
2019-07-13 19:39:01 +10:00
|
|
|
import QtQuick 2.12
|
2019-12-18 19:53:08 +11:00
|
|
|
import "../../../Base"
|
2020-03-06 23:40:48 +11:00
|
|
|
import "../../.."
|
2019-05-13 03:17:42 +10:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
MultiviewPane {
|
2019-12-11 05:57:54 +11:00
|
|
|
id: roomPane
|
2019-12-11 07:29:49 +11:00
|
|
|
saveName: "roomPane"
|
2019-12-09 20:25:31 +11:00
|
|
|
edge: Qt.RightEdge
|
2019-12-22 03:46:47 +11:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
buttonsBackgroundColor: theme.chat.roomPaneButtons.background
|
|
|
|
backgroundColor: theme.chat.roomPane.background
|
2019-12-22 03:46:47 +11:00
|
|
|
|
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
buttonRepeater.model: [
|
|
|
|
"members", "files", "notifications", "history", "settings"
|
|
|
|
]
|
2019-07-13 08:15:06 +10:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
buttonRepeater.delegate: HButton {
|
|
|
|
height: theme.baseElementsHeight
|
|
|
|
backgroundColor: "transparent"
|
|
|
|
icon.name: "room-view-" + modelData
|
|
|
|
toolTip.text: qsTr(
|
|
|
|
modelData.charAt(0).toUpperCase() + modelData.slice(1)
|
|
|
|
)
|
2019-12-16 04:04:51 +11:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
autoExclusive: true
|
|
|
|
checked: swipeView.currentIndex === 0 && index === 0 ||
|
|
|
|
swipeView.currentIndex === 1 && index === 4
|
2019-07-13 08:15:06 +10:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
enabled: ["members", "settings"].includes(modelData)
|
2019-12-09 20:25:31 +11:00
|
|
|
|
2020-03-06 23:40:48 +11:00
|
|
|
onClicked: swipeView.currentIndex = Math.min(index, 1)
|
2019-05-13 03:17:42 +10:00
|
|
|
}
|
2020-03-06 23:40:48 +11:00
|
|
|
|
|
|
|
MemberView {}
|
|
|
|
SettingsView { fillAvailableHeight: true }
|
2019-05-13 03:17:42 +10:00
|
|
|
}
|