Three types of Dialogs on DialogsPage

This commit is contained in:
Sebastian Kügler 2013-02-20 05:43:09 +01:00
parent 877b8f03df
commit a9092a7583

View File

@ -39,32 +39,6 @@ PlasmaComponents.Page {
width: parent.width
text: "Dialogs"
}
Row {
height: _h
spacing: _s
PlasmaComponents.Button {
text: "PlasmaCore.Dialog"
iconSource: "dialog-ok-apply"
checkable: true
onCheckedChanged: pcDialog.visible = checked
}
PlasmaComponents.Label {
text: pcDialog.visible ? "shown" : "hidden"
}
PlasmaCore.Dialog {
id: pcDialog
windowFlags: Qt.Popup
mainItem: dContent2
DialogContent {
id: dContent2
onCloseMe: {
pcDialog.close()
//pcDialog.visible = false
}
}
}
}
Row {
height: _h
spacing: _s
@ -80,21 +54,6 @@ PlasmaComponents.Page {
width: childrenRect.width
height: childrenRect.height
color: Qt.rgba(0,0,0,0)
// Column {
// width: dialogsPage.width/2
// PlasmaComponents.TextArea {
// //anchors { left: parent.left; right: parent.right; top: parent.top; }
// width: parent.width
// height: _h*2
// }
//
// PlasmaComponents.Button {
// id: thanks
// iconSource: "dialog-ok"
// text: "Thanks."
// onClicked: selectionDialog.visible = false;
// }
// }
DialogContent {
id: dContent
onCloseMe: {
@ -107,6 +66,53 @@ PlasmaComponents.Page {
text: qWindow.visible ? "shown" : "hidden"
}
}
Row {
height: _h
spacing: _s
PlasmaComponents.Button {
text: "PlasmaCore.Dialog"
iconSource: "dialog-ok-apply"
checkable: true
//onCheckedChanged: pcDialog.visible = checked
onCheckedChanged: pcompDialog.visible = checked
}
PlasmaComponents.Label {
text: pcDialog.visible ? "shown" : "hidden"
}
PlasmaCore.Dialog {
id: pcDialog
windowFlags: Qt.Popup
mainItem: dContent2
DialogContent {
id: dContent2
onCloseMe: pcDialog.visible = false
}
}
}
Row {
height: _h
spacing: _s
PlasmaComponents.Button {
text: "PlasmaComponents.Dialog"
iconSource: "dialog-ok-apply"
checkable: true
onCheckedChanged: pcompDialog.visible = checked
}
PlasmaComponents.Label {
text: pcompDialog.visible ? "shown" : "hidden"
}
PlasmaCore.Dialog {
id: pcompDialog
windowFlags: Qt.Popup
mainItem: dContent3
DialogContent {
id: dContent3
onCloseMe: pcompDialog.visible = false
}
}
}
}
}