import QtQuick import QtQuick.Controls Popup{ id: control property alias text: textItem.text property alias icon: image.source property alias color: back.color property string borderColor x: (parent.width-200)/2 y: 40 width: 200 height: 32 font.pixelSize: 16 contentItem: Row{ leftPadding: 4 spacing: 9.6 Image { id: image anchors.verticalCenter: parent.verticalCenter } Text { id: textItem anchors.verticalCenter: parent.verticalCenter text: control.text font: control.font color: "#666666" } } background: Rectangle { id:back anchors.fill: parent color: "#EBF8ED" radius: 3.2 border.width: 1 border.color: control.borderColor layer.enabled: true } Timer { id: timer repeat: false onTriggered: control.visible=false } function show(text,timeout){ control.text = text timer.interval = timeout timer.restart(); control.visible=true } }