aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@qt.io>2018-01-18 12:16:48 +0100
committerJ-P Nurmi <jpnurmi@qt.io>2018-01-18 11:29:43 +0000
commit8244e2e36af2f6923c5be586da37c0facf7152a8 (patch)
tree1c5d61c024981424e6f360c850dfc06a2b0d4760
parent81ff2b14c317545e6f7b44b722cf057badd1e322 (diff)
Imagine/DelayButton: cleanup internal IDs for deferred execution
Task-number: QTBUG-50992 Change-Id: I5f2708bc0e9f37232b10e2cd6f1c61ab779156e3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
-rw-r--r--src/imports/controls/imagine/DelayButton.qml21
-rw-r--r--tests/auto/sanity/BLACKLIST2
2 files changed, 10 insertions, 13 deletions
diff --git a/src/imports/controls/imagine/DelayButton.qml b/src/imports/controls/imagine/DelayButton.qml
index 3b2eb8bb..157285f6 100644
--- a/src/imports/controls/imagine/DelayButton.qml
+++ b/src/imports/controls/imagine/DelayButton.qml
@@ -86,8 +86,8 @@ T.DelayButton {
]
}
- NinePatchImage {
- id: progress
+ readonly property NinePatchImage progress: NinePatchImage {
+ parent: control.background
width: control.progress * parent.width
height: parent.height
visible: false
@@ -105,10 +105,9 @@ T.DelayButton {
}
}
- NinePatchImage {
- id: mask
- width: parent.width
- height: parent.height
+ readonly property NinePatchImage mask: NinePatchImage {
+ width: control.background.width
+ height: control.background.height
visible: false
source: Imagine.url + "delaybutton-mask"
@@ -124,15 +123,15 @@ T.DelayButton {
}
}
- OpacityMask {
- id: effect
+ readonly property OpacityMask effect: OpacityMask {
+ parent: control.background
width: source.width
height: source.height
- source: progress
+ source: control.background.progress
maskSource: ShaderEffectSource {
- sourceItem: mask
- sourceRect: Qt.rect(0, 0, effect.width, effect.height)
+ sourceItem: control.background.mask
+ sourceRect: Qt.rect(0, 0, control.background.effect.width, control.background.effect.height)
}
}
}
diff --git a/tests/auto/sanity/BLACKLIST b/tests/auto/sanity/BLACKLIST
index 53b27412..a595d354 100644
--- a/tests/auto/sanity/BLACKLIST
+++ b/tests/auto/sanity/BLACKLIST
@@ -2,8 +2,6 @@
*
[attachedObjects:material/SwitchDelegate.qml]
*
-[ids:imagine/DelayButton.qml]
-*
[ids:imagine/Switch.qml]
*
[ids:imagine/SwitchDelegate.qml]