2023-04-23 11:05:43 +00:00
|
|
|
import QtCore
|
|
|
|
import QtQuick
|
|
|
|
import QtQuick.Controls
|
|
|
|
import QtQuick.Layouts
|
|
|
|
|
|
|
|
Dialog {
|
2023-04-23 11:35:38 +00:00
|
|
|
id: popupDialog
|
2023-04-23 11:05:43 +00:00
|
|
|
anchors.centerIn: parent
|
|
|
|
modal: false
|
|
|
|
opacity: 0.9
|
|
|
|
padding: 20
|
|
|
|
property alias text: textField.text
|
2023-04-23 13:42:35 +00:00
|
|
|
|
|
|
|
Theme {
|
|
|
|
id: theme
|
|
|
|
}
|
|
|
|
|
2023-04-23 11:05:43 +00:00
|
|
|
Text {
|
|
|
|
id: textField
|
|
|
|
horizontalAlignment: Text.AlignJustify
|
2023-04-23 13:42:35 +00:00
|
|
|
color: theme.textColor
|
2023-04-23 11:05:43 +00:00
|
|
|
Accessible.role: Accessible.HelpBalloon
|
|
|
|
Accessible.name: text
|
|
|
|
Accessible.description: qsTr("Reveals a shortlived help balloon")
|
|
|
|
}
|
|
|
|
background: Rectangle {
|
|
|
|
anchors.fill: parent
|
2023-04-23 13:42:35 +00:00
|
|
|
color: theme.backgroundDarkest
|
2023-04-23 11:05:43 +00:00
|
|
|
border.width: 1
|
2023-04-23 13:42:35 +00:00
|
|
|
border.color: theme.dialogBorder
|
2023-04-23 11:05:43 +00:00
|
|
|
radius: 10
|
|
|
|
}
|
|
|
|
|
|
|
|
exit: Transition {
|
|
|
|
NumberAnimation { duration: 500; property: "opacity"; from: 1.0; to: 0.0 }
|
|
|
|
}
|
2023-04-23 11:35:38 +00:00
|
|
|
|
|
|
|
onOpened: {
|
|
|
|
timer.start()
|
|
|
|
}
|
|
|
|
|
|
|
|
Timer {
|
|
|
|
id: timer
|
|
|
|
interval: 500; running: false; repeat: false
|
|
|
|
onTriggered: popupDialog.close()
|
|
|
|
}
|
2023-04-23 11:05:43 +00:00
|
|
|
}
|