diff options
Diffstat (limited to 'tests/manual/quickcontrols/gifs/data/qtquickcontrols2-swipedelegate-leading-trailing.qml')
-rw-r--r-- | tests/manual/quickcontrols/gifs/data/qtquickcontrols2-swipedelegate-leading-trailing.qml | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/tests/manual/quickcontrols/gifs/data/qtquickcontrols2-swipedelegate-leading-trailing.qml b/tests/manual/quickcontrols/gifs/data/qtquickcontrols2-swipedelegate-leading-trailing.qml new file mode 100644 index 0000000000..7e09e7bcc6 --- /dev/null +++ b/tests/manual/quickcontrols/gifs/data/qtquickcontrols2-swipedelegate-leading-trailing.qml @@ -0,0 +1,46 @@ +// Copyright (C) 2017 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause + +import QtQuick +import QtQuick.Window +import QtQuick.Controls + +Window { + width: swipeDelegate.implicitWidth + height: swipeDelegate.implicitHeight + visible: true + + property alias swipeDelegate: swipeDelegate + + SwipeDelegate { + id: swipeDelegate + text: "SwipeDelegate" + anchors.centerIn: parent + + swipe.left: Rectangle { + width: swipeDelegate.width + height: swipeDelegate.height + color: swipeDelegate.pressed ? "#333" : "#444" + anchors.right: parent.left + + Label { + text: "Left Action" + color: "#fff" + anchors.centerIn: parent + } + } + + swipe.right: Rectangle { + width: swipeDelegate.width + height: swipeDelegate.height + color: swipeDelegate.pressed ? "#333" : "#444" + anchors.left: parent.right + + Label { + text: "Right Action" + color: "#fff" + anchors.centerIn: parent + } + } + } +} |