aboutsummaryrefslogtreecommitdiffstats
path: root/tests/manual/quickcontrols2/buttons
diff options
context:
space:
mode:
Diffstat (limited to 'tests/manual/quickcontrols2/buttons')
-rw-r--r--tests/manual/quickcontrols2/buttons/ButtonLoader.qml101
-rw-r--r--tests/manual/quickcontrols2/buttons/CMakeLists.txt42
-rw-r--r--tests/manual/quickcontrols2/buttons/buttons.cpp61
-rw-r--r--tests/manual/quickcontrols2/buttons/buttons.pro6
-rw-r--r--tests/manual/quickcontrols2/buttons/buttons.qml150
5 files changed, 0 insertions, 360 deletions
diff --git a/tests/manual/quickcontrols2/buttons/ButtonLoader.qml b/tests/manual/quickcontrols2/buttons/ButtonLoader.qml
deleted file mode 100644
index ecbf637b..00000000
--- a/tests/manual/quickcontrols2/buttons/ButtonLoader.qml
+++ /dev/null
@@ -1,101 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2017 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of the test suite of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** BSD License Usage
-** Alternatively, you may use this file under the terms of the BSD license
-** as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-** * Redistributions of source code must retain the above copyright
-** notice, this list of conditions and the following disclaimer.
-** * Redistributions in binary form must reproduce the above copyright
-** notice, this list of conditions and the following disclaimer in
-** the documentation and/or other materials provided with the
-** distribution.
-** * Neither the name of The Qt Company Ltd nor the names of its
-** contributors may be used to endorse or promote products derived
-** from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-import QtQuick
-import QtQuick.Controls
-
-Item {
- id: root
- implicitWidth: activeButton.implicitWidth
- implicitHeight: activeButton.implicitHeight
-
- property bool round: false
-
- property string text
- property bool flat
- property bool hoverEnabled
- property bool highlighted
- property bool checked
- property var down: undefined
-
- property AbstractButton activeButton: round ? roundButton : button
-
- Button {
- id: button
- visible: !round
- text: root.text
- flat: root.flat
- hoverEnabled: root.hoverEnabled
- highlighted: root.highlighted
- checked: root.checked
- down: root.down
- enabled: root.enabled
- }
-
- RoundButton {
- id: roundButton
- visible: round
- text: "\u2713"
- flat: root.flat
- hoverEnabled: root.hoverEnabled
- highlighted: root.highlighted
- checked: root.checked
- down: root.down
- enabled: root.enabled
-
- Label {
- text: root.text
- font.pixelSize: roundButton.font.pixelSize * 0.5
- anchors.top: parent.bottom
- anchors.topMargin: 2
- anchors.horizontalCenter: parent.horizontalCenter
- }
- }
-}
diff --git a/tests/manual/quickcontrols2/buttons/CMakeLists.txt b/tests/manual/quickcontrols2/buttons/CMakeLists.txt
deleted file mode 100644
index 57f80c88..00000000
--- a/tests/manual/quickcontrols2/buttons/CMakeLists.txt
+++ /dev/null
@@ -1,42 +0,0 @@
-# Generated from buttons.pro.
-
-if (NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
- cmake_minimum_required(VERSION 3.16)
- project(buttons LANGUAGES C CXX ASM)
- find_package(Qt6BuildInternals COMPONENTS STANDALONE_TEST)
-endif()
-
-#####################################################################
-## buttons Binary:
-#####################################################################
-
-qt_internal_add_manual_test(buttons
- GUI
- SOURCES
- buttons.cpp
- PUBLIC_LIBRARIES
- Qt::Gui
- Qt::Qml
- Qt::QuickControls2
-)
-
-file(GLOB resource_glob_0 RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "*.qml")
-foreach(file IN LISTS resource_glob_0)
- set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/${file}" PROPERTIES QT_RESOURCE_ALIAS "${file}")
-endforeach()
-
-# Resources:
-set(qmake_immediate_resource_files
- ${resource_glob_0}
-)
-
-qt_internal_add_resource(buttons "qmake_immediate"
- PREFIX
- "/"
- FILES
- ${qmake_immediate_resource_files}
-)
-
-
-#### Keys ignored in scope 1:.:.:buttons.pro:<TRUE>:
-# TEMPLATE = "app"
diff --git a/tests/manual/quickcontrols2/buttons/buttons.cpp b/tests/manual/quickcontrols2/buttons/buttons.cpp
deleted file mode 100644
index 0272522a..00000000
--- a/tests/manual/quickcontrols2/buttons/buttons.cpp
+++ /dev/null
@@ -1,61 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2017 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of the test suite of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** BSD License Usage
-** Alternatively, you may use this file under the terms of the BSD license
-** as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-** * Redistributions of source code must retain the above copyright
-** notice, this list of conditions and the following disclaimer.
-** * Redistributions in binary form must reproduce the above copyright
-** notice, this list of conditions and the following disclaimer in
-** the documentation and/or other materials provided with the
-** distribution.
-** * Neither the name of The Qt Company Ltd nor the names of its
-** contributors may be used to endorse or promote products derived
-** from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-#include <QGuiApplication>
-#include <QQmlApplicationEngine>
-
-int main(int argc, char *argv[])
-{
- QGuiApplication app(argc, argv);
-
- QQmlApplicationEngine engine;
- engine.load(QUrl("qrc:/buttons.qml"));
-
- return app.exec();
-}
diff --git a/tests/manual/quickcontrols2/buttons/buttons.pro b/tests/manual/quickcontrols2/buttons/buttons.pro
deleted file mode 100644
index 2cb1c14c..00000000
--- a/tests/manual/quickcontrols2/buttons/buttons.pro
+++ /dev/null
@@ -1,6 +0,0 @@
-TEMPLATE = app
-TARGET = buttons
-QT += qml quickcontrols2
-
-SOURCES += buttons.cpp
-RESOURCES += $$files(*.qml)
diff --git a/tests/manual/quickcontrols2/buttons/buttons.qml b/tests/manual/quickcontrols2/buttons/buttons.qml
deleted file mode 100644
index 26969440..00000000
--- a/tests/manual/quickcontrols2/buttons/buttons.qml
+++ /dev/null
@@ -1,150 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2017 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of the test suite of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** BSD License Usage
-** Alternatively, you may use this file under the terms of the BSD license
-** as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-** * Redistributions of source code must retain the above copyright
-** notice, this list of conditions and the following disclaimer.
-** * Redistributions in binary form must reproduce the above copyright
-** notice, this list of conditions and the following disclaimer in
-** the documentation and/or other materials provided with the
-** distribution.
-** * Neither the name of The Qt Company Ltd nor the names of its
-** contributors may be used to endorse or promote products derived
-** from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Controls.Material
-import QtQuick.Controls.Universal
-
-ApplicationWindow {
- id: window
- visible: true
- title: "Buttons"
-
- Component.onCompleted: {
- var pane = repeater.itemAt(0)
- width = pane.implicitWidth * 2 + flickable.leftMargin + flickable.rightMargin + flow.spacing
- height = header.height + pane.implicitHeight * 2 + flickable.topMargin + flickable.bottomMargin + flow.spacing
- }
-
- header: ToolBar {
- Row {
- spacing: 20
- anchors.right: parent.right
- CheckBox {
- id: hoverBox
- text: "Hover"
- checked: true
- }
- CheckBox {
- id: roundBox
- text: "Round"
- checked: false
- }
- }
- }
-
- Flickable {
- id: flickable
- anchors.fill: parent
-
- topMargin: 40
- leftMargin: 40
- rightMargin: 40
- bottomMargin: 40
-
- contentHeight: flow.implicitHeight
-
- Flow {
- id: flow
- spacing: 40
- width: flickable.width - flickable.leftMargin - flickable.rightMargin
-
- Repeater {
- id: repeater
-
- model: [
- { title: "Normal", theme: Material.Light, flat: false },
- { title: "Flat", theme: Material.Light, flat: true },
- { title: "Normal", theme: Material.Dark, flat: false },
- { title: "Flat", theme: Material.Dark, flat: true }
- ]
-
- Pane {
- Material.elevation: 8
- Material.theme: modelData.theme
- Universal.theme: modelData.theme
-
- GroupBox {
- title: modelData.title
- background.visible: false
-
- Grid {
- columns: 4
- spacing: 20
- padding: 20
-
- ButtonLoader { text: "Normal"; flat: modelData.flat; hoverEnabled: hoverBox.checked; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; enabled: false; round: roundBox.checked }
- ButtonLoader { text: "Down"; flat: modelData.flat; hoverEnabled: hoverBox.checked; down: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; down: true; enabled: false; round: roundBox.checked }
-
- ButtonLoader { text: "Checked"; flat: modelData.flat; hoverEnabled: hoverBox.checked; checked: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; checked: true; enabled: false; round: roundBox.checked }
- ButtonLoader { text: "Down"; flat: modelData.flat; hoverEnabled: hoverBox.checked; checked: true; down: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; checked: true; down: true; enabled: false; round: roundBox.checked }
-
- ButtonLoader { text: "Highlighted"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; enabled: false; round: roundBox.checked }
- ButtonLoader { text: "Down"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; down: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; down: true; enabled: false; round: roundBox.checked }
-
- ButtonLoader { text: "Hi-checked"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; checked: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; checked: true; enabled: false; round: roundBox.checked }
- ButtonLoader { text: "Down"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; checked: true; down: true; round: roundBox.checked }
- ButtonLoader { text: "Disabled"; flat: modelData.flat; hoverEnabled: hoverBox.checked; highlighted: true; checked: true; down: true; enabled: false; round: roundBox.checked }
- }
- }
- }
- }
- }
-
- ScrollIndicator.vertical: ScrollIndicator { }
- }
-}