Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
QML 0.97 KB | None | 0 0
  1. import QtQuick 2.12
  2. import QtQuick.Controls 2.12
  3.  
  4. ApplicationWindow {
  5.     visible: true
  6.     width: 640
  7.     height: 480
  8.     title: qsTr("Hello World")
  9.  
  10.     header: ToolBar {
  11.         Row {
  12.             ToolButton {
  13.                 text: qsTr("popup1")
  14.                 onClicked: popup1.open()
  15.             }
  16.         }
  17.     }
  18.  
  19.     Page {
  20.         width: parent.width/2
  21.         height: parent.height
  22.         Rectangle {
  23.             anchors.fill: parent
  24.             color: "green"
  25.         }
  26.  
  27.         MyPopup {
  28.             id: popup1
  29.         }
  30.  
  31.     }
  32.  
  33.     Page {
  34.         width: parent.width/2
  35.         height: parent.height
  36.         x: parent.width/2
  37.         Rectangle {
  38.             anchors.fill: parent
  39.             color: "blue"
  40.         }
  41.         header: ToolBar {
  42.             ToolButton {
  43.                 text: qsTr("popup2")
  44.                 onClicked: popup2.open()
  45.             }
  46.         }
  47.         MyPopup {
  48.             id: popup2
  49.         }
  50.     }
  51. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement