Change server list to joinmatrix.org's
This commit is contained in:
@@ -115,7 +115,6 @@ HBox {
|
||||
model: [
|
||||
qsTr("Ping"),
|
||||
qsTr("Name & location"),
|
||||
qsTr("Stability"),
|
||||
qsTr("Site"),
|
||||
]
|
||||
|
||||
|
@@ -66,44 +66,10 @@ HTile {
|
||||
}
|
||||
}
|
||||
|
||||
TitleRightInfoLabel {
|
||||
tile: root
|
||||
font.pixelSize: theme.fontSize.normal
|
||||
|
||||
text:
|
||||
model.stability === -1 ?
|
||||
"" :
|
||||
qsTr("%1%").arg(Math.max(0, parseInt(model.stability, 10)))
|
||||
|
||||
color:
|
||||
model.stability >= 95 ? theme.colors.positiveText :
|
||||
model.stability >= 85 ? theme.colors.warningText :
|
||||
theme.colors.errorText
|
||||
|
||||
HoverHandler { id: rightInfoHover }
|
||||
|
||||
HToolTip {
|
||||
readonly property var times: JSON.parse(model.downtimes_ms)
|
||||
readonly property real total: utils.sum(times)
|
||||
|
||||
visible: model.stability !== -1 && rightInfoHover.hovered
|
||||
text:
|
||||
total === 0 ?
|
||||
qsTr("No downtimes in the last 30 days") :
|
||||
qsTr(
|
||||
"Last 30 days downtimes: %1, average: %2, " +
|
||||
"longest: %3, total: %4"
|
||||
).arg(times.length)
|
||||
.arg(utils.formatRelativeTime(total / times.length))
|
||||
.arg(utils.formatRelativeTime(Math.max.apply(Math,times)))
|
||||
.arg(utils.formatRelativeTime(total))
|
||||
}
|
||||
}
|
||||
|
||||
HButton {
|
||||
icon.name: "server-visit-website"
|
||||
backgroundColor: "transparent"
|
||||
onClicked: Qt.openUrlExternally(model.site_url)
|
||||
onClicked: Qt.openUrlExternally("https://"+model.site_url)
|
||||
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
|
Reference in New Issue
Block a user