diff options
Diffstat (limited to 'tests/auto/qml/qml/data/resizeItem.qml')
-rw-r--r-- | tests/auto/qml/qml/data/resizeItem.qml | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/auto/qml/qml/data/resizeItem.qml b/tests/auto/qml/qml/data/resizeItem.qml new file mode 100644 index 0000000000..c416451ccc --- /dev/null +++ b/tests/auto/qml/qml/data/resizeItem.qml @@ -0,0 +1,28 @@ +import QtQuick + +Rectangle { + id: rect + color: "green" + + Timer { + id: exitTimer + running: false + onTriggered: Qt.quit() + } + + Timer { + id: resizeTimer + running: false + onTriggered: { + rect.width = 100 + rect.height = 50 + exitTimer.start() + } + } + + Window.onHeightChanged: { + if (rect.Window.width > 0) + console.info("window", rect.Window.width, rect.Window.height, "content", rect.width, rect.height) + resizeTimer.start() + } +} |