aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@theqtcompany.com>2015-06-18 14:35:54 +0200
committerJ-P Nurmi <jpnurmi@theqtcompany.com>2015-06-18 12:37:31 +0000
commitc803830c02fb573582cd848185460ba65b4529e5 (patch)
treebc0e00a8c82b4242661d3d6f7beb77e3c5691623 /examples
parent9b67ed1dde437448b927ef839ca60a2820f021dc (diff)
Frame, GroupBox, ToolBar: restore contentWidth & contentHeight
Change-Id: I79a974c64f6ec57ebfa83cea0857b2a1590af61f Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/quick/controls/mirroring/main.qml117
1 files changed, 67 insertions, 50 deletions
diff --git a/examples/quick/controls/mirroring/main.qml b/examples/quick/controls/mirroring/main.qml
index 5a351993..cf691486 100644
--- a/examples/quick/controls/mirroring/main.qml
+++ b/examples/quick/controls/mirroring/main.qml
@@ -106,43 +106,49 @@ ApplicationWindow {
GroupBox {
title: "CheckBox"
readonly property real preferredWidth: (flow.width - 12) / 2
- width: window.width > window.height || implicitWidth > preferredWidth ? flow.width : preferredWidth
- CheckBox {
+ width: window.width > window.height || contentWidth > preferredWidth ? flow.width : preferredWidth
+ ColumnLayout {
width: parent.width
- text: "E-mail"
- checked: true
- }
- CheckBox {
- width: parent.width
- text: "Calendar"
- checked: true
- }
- CheckBox {
- width: parent.width
- text: "Contacts"
+ CheckBox {
+ width: parent.width
+ text: "E-mail"
+ checked: true
+ }
+ CheckBox {
+ width: parent.width
+ text: "Calendar"
+ checked: true
+ }
+ CheckBox {
+ width: parent.width
+ text: "Contacts"
+ }
}
}
GroupBox {
title: "RadioButton"
readonly property real preferredWidth: (flow.width - 12) / 2
- width: window.width > window.height || implicitWidth > preferredWidth ? flow.width : preferredWidth
+ width: window.width > window.height || contentWidth > preferredWidth ? flow.width : preferredWidth
ExclusiveGroup { id: eg }
- RadioButton {
+ ColumnLayout {
width: parent.width
- text: "Portrait"
- Exclusive.group: eg
- }
- RadioButton {
- width: parent.width
- text: "Landscape"
- Exclusive.group: eg
- }
- RadioButton {
- width: parent.width
- text: "Automatic"
- checked: true
- Exclusive.group: eg
+ RadioButton {
+ width: parent.width
+ text: "Portrait"
+ Exclusive.group: eg
+ }
+ RadioButton {
+ width: parent.width
+ text: "Landscape"
+ Exclusive.group: eg
+ }
+ RadioButton {
+ width: parent.width
+ text: "Automatic"
+ checked: true
+ Exclusive.group: eg
+ }
}
}
@@ -171,43 +177,54 @@ ApplicationWindow {
GroupBox {
title: "Switch"
width: flow.width
- Switch {
+ Column {
width: parent.width
- text: "Wifi"
- checked: true
- }
- Switch {
- width: parent.width
- text: "Bluetooth"
+ Switch {
+ width: parent.width
+ text: "Wifi"
+ checked: true
+ }
+ Switch {
+ width: parent.width
+ text: "Bluetooth"
+ }
}
}
GroupBox {
title: "ProgressBar"
width: flow.width
- ProgressBar {
+ Column {
width: parent.width
- indeterminate: true
- }
- ProgressBar {
- width: parent.width
- value: slider.position
+ spacing: Theme.spacing
+ ProgressBar {
+ width: parent.width
+ indeterminate: true
+ }
+ ProgressBar {
+ width: parent.width
+ value: slider.position
+ }
}
}
GroupBox {
title: "Slider"
width: flow.width
- Slider {
- id: slider
- value: 0.4
- width: parent.width
- }
- Slider {
+ Column {
width: parent.width
- snapMode: AbstractSlider.SnapAlways
- stepSize: 0.2
- value: 0.8
+ spacing: Theme.spacing
+ Slider {
+ id: slider
+ value: 0.4
+ width: parent.width
+ }
+ Slider {
+ width: parent.width
+ snapMode: AbstractSlider.SnapAlways
+ stepSize: 0.2
+ value: 0.8
+ }
}
}
}