mirror of
https://github.com/Qsgs-Fans/FreeKill.git
synced 2024-11-16 19:58:13 +08:00
48f3ae3ecd
做了个Mod制作器的壳 修手气卡bug 修旁观/重连看不到标记 优化Card元表实现
51 lines
870 B
QML
51 lines
870 B
QML
import QtQuick
|
|
import QtQuick.Controls
|
|
import QtQuick.Layouts
|
|
|
|
ColumnLayout {
|
|
id: root
|
|
anchors.fill: parent
|
|
anchors.margins: 16
|
|
signal finished()
|
|
signal accepted(string result)
|
|
|
|
property string head
|
|
property string hint
|
|
|
|
Text {
|
|
text: qsTr(head)
|
|
font.pixelSize: 20
|
|
font.bold: true
|
|
Layout.fillWidth: true
|
|
wrapMode: Text.WrapAnywhere
|
|
}
|
|
|
|
Text {
|
|
text: qsTr(hint)
|
|
Layout.fillWidth: true
|
|
wrapMode: Text.WrapAnywhere
|
|
}
|
|
|
|
Text {
|
|
text: qsTr("validator_hint")
|
|
Layout.fillWidth: true
|
|
wrapMode: Text.WrapAnywhere
|
|
}
|
|
|
|
TextField {
|
|
id: edit
|
|
font.pixelSize: 18
|
|
Layout.fillWidth: true
|
|
validator: RegularExpressionValidator { regularExpression: /[0-9A-Za-z_]+/ }
|
|
}
|
|
|
|
Button {
|
|
text: "OK"
|
|
enabled: edit.text.length >= 4
|
|
onClicked: {
|
|
accepted(edit.text);
|
|
finished();
|
|
}
|
|
}
|
|
}
|