FreeKill/Fk/RoomElement/GameOverBox.qml
notify 2acec5f20a
Qmldir (#155)
重组qml文件,使用qmldir文件实现模块化
2023-05-19 10:08:36 +08:00

35 lines
714 B
QML

// SPDX-License-Identifier: GPL-3.0-or-later
import QtQuick
import Fk.Pages
GraphicsBox {
property string winner: ""
id: root
title.text: Backend.translate("$GameOver")
width: Math.max(140, body.width + 20)
height: body.height + title.height + 20
Column {
id: body
x: 10
y: title.height + 5
spacing: 10
Text {
text: winner !== "" ? Backend.translate("$Winner").arg(Backend.translate(winner)) : Backend.translate("$NoWinner")
color: "#E4D5A0"
}
MetroButton {
text: Backend.translate("Back To Lobby")
anchors.horizontalCenter: parent.horizontalCenter
onClicked: {
ClientInstance.notifyServer("QuitRoom", "[]");
}
}
}
}