aboutsummaryrefslogtreecommitdiffstats
path: root/examples/quickcontrols/ios
diff options
context:
space:
mode:
Diffstat (limited to 'examples/quickcontrols/ios')
-rw-r--r--examples/quickcontrols/ios/todolist/AppSettings.qml2
-rw-r--r--examples/quickcontrols/ios/todolist/CMakeLists.txt21
-rw-r--r--examples/quickcontrols/ios/todolist/Database.qml2
-rw-r--r--examples/quickcontrols/ios/todolist/FontSizePage.qml2
-rw-r--r--examples/quickcontrols/ios/todolist/HomePage.qml5
-rw-r--r--examples/quickcontrols/ios/todolist/MaxTasksPage.qml3
-rw-r--r--examples/quickcontrols/ios/todolist/NavBar.qml2
-rw-r--r--examples/quickcontrols/ios/todolist/ProjectPage.qml5
-rw-r--r--examples/quickcontrols/ios/todolist/SettingsPage.qml4
-rw-r--r--examples/quickcontrols/ios/todolist/ToggleCompletedTasksPage.qml3
-rw-r--r--examples/quickcontrols/ios/todolist/main.qml2
-rw-r--r--examples/quickcontrols/ios/todolist/src/main.cpp2
12 files changed, 30 insertions, 23 deletions
diff --git a/examples/quickcontrols/ios/todolist/AppSettings.qml b/examples/quickcontrols/ios/todolist/AppSettings.qml
index 764ba8b8fc..37a9fe33e9 100644
--- a/examples/quickcontrols/ios/todolist/AppSettings.qml
+++ b/examples/quickcontrols/ios/todolist/AppSettings.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
pragma Singleton
diff --git a/examples/quickcontrols/ios/todolist/CMakeLists.txt b/examples/quickcontrols/ios/todolist/CMakeLists.txt
index ea96d606c7..64d7624679 100644
--- a/examples/quickcontrols/ios/todolist/CMakeLists.txt
+++ b/examples/quickcontrols/ios/todolist/CMakeLists.txt
@@ -3,12 +3,6 @@ project(todolist LANGUAGES CXX)
set(CMAKE_AUTOMOC ON)
-if(NOT DEFINED INSTALL_EXAMPLESDIR)
- set(INSTALL_EXAMPLESDIR "examples")
-endif()
-
-set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/todolist")
-
find_package(Qt6 COMPONENTS Gui Qml Quick QuickControls2)
qt_add_executable(todolist
@@ -77,7 +71,16 @@ qt_add_qml_module(todolist
set_property(GLOBAL PROPERTY XCODE_EMIT_EFFECTIVE_PLATFORM_NAME ON)
install(TARGETS todolist
- RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
- BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
- LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION .
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
+)
+
+qt_generate_deploy_qml_app_script(
+ TARGET todolist
+ OUTPUT_SCRIPT deploy_script
+ MACOS_BUNDLE_POST_BUILD
+ NO_UNSUPPORTED_PLATFORM_ERROR
+ DEPLOY_USER_QML_MODULES_ON_UNSUPPORTED_PLATFORM
)
+install(SCRIPT ${deploy_script})
diff --git a/examples/quickcontrols/ios/todolist/Database.qml b/examples/quickcontrols/ios/todolist/Database.qml
index 31bbd8c1e7..eb85402b26 100644
--- a/examples/quickcontrols/ios/todolist/Database.qml
+++ b/examples/quickcontrols/ios/todolist/Database.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
pragma Singleton
diff --git a/examples/quickcontrols/ios/todolist/FontSizePage.qml b/examples/quickcontrols/ios/todolist/FontSizePage.qml
index 2b0e5b16db..89c8bd4518 100644
--- a/examples/quickcontrols/ios/todolist/FontSizePage.qml
+++ b/examples/quickcontrols/ios/todolist/FontSizePage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
diff --git a/examples/quickcontrols/ios/todolist/HomePage.qml b/examples/quickcontrols/ios/todolist/HomePage.qml
index 94221146e2..39753e0be7 100644
--- a/examples/quickcontrols/ios/todolist/HomePage.qml
+++ b/examples/quickcontrols/ios/todolist/HomePage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
@@ -56,7 +56,7 @@ Page {
}
Image {
- source: Qt.styleHints.appearance === Qt.Dark ? "images/close-white.png"
+ source: Qt.styleHints.colorScheme === Qt.Dark ? "images/close-white.png"
: "images/close.png"
width: 20
height: 20
@@ -141,6 +141,7 @@ Page {
enabled: newProjectTextField.length > 0
Layout.alignment: Qt.AlignHCenter
+ Layout.fillWidth: false
onClicked: {
let results = Database.newProject(newProjectTextField.text)
diff --git a/examples/quickcontrols/ios/todolist/MaxTasksPage.qml b/examples/quickcontrols/ios/todolist/MaxTasksPage.qml
index 509a460357..5b1a854617 100644
--- a/examples/quickcontrols/ios/todolist/MaxTasksPage.qml
+++ b/examples/quickcontrols/ios/todolist/MaxTasksPage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
@@ -29,6 +29,7 @@ Page {
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: 10
+ Layout.fillWidth: false
onValueModified: AppSettings.maxTasks = maxTasksSpinbox.value
}
diff --git a/examples/quickcontrols/ios/todolist/NavBar.qml b/examples/quickcontrols/ios/todolist/NavBar.qml
index 4f57353dca..717993dfda 100644
--- a/examples/quickcontrols/ios/todolist/NavBar.qml
+++ b/examples/quickcontrols/ios/todolist/NavBar.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
diff --git a/examples/quickcontrols/ios/todolist/ProjectPage.qml b/examples/quickcontrols/ios/todolist/ProjectPage.qml
index a38ad04554..8319206fe9 100644
--- a/examples/quickcontrols/ios/todolist/ProjectPage.qml
+++ b/examples/quickcontrols/ios/todolist/ProjectPage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
@@ -53,6 +53,7 @@ Page {
value: root.completedTasks
to: root.totalTasks
Layout.leftMargin: 20
+ Layout.fillWidth: false
}
}
@@ -159,7 +160,7 @@ Page {
anchors.leftMargin: 10
anchors.verticalCenter: parent.verticalCenter
icon.source: "images/close.png"
- icon.color: Qt.styleHints.appearance === Qt.Dark ? "white" : "black"
+ icon.color: Qt.styleHints.colorScheme === Qt.Dark ? "white" : "black"
onClicked: {
Database.deleteTask(taskList.taskId)
diff --git a/examples/quickcontrols/ios/todolist/SettingsPage.qml b/examples/quickcontrols/ios/todolist/SettingsPage.qml
index 4d2d7bef9f..0f6f708974 100644
--- a/examples/quickcontrols/ios/todolist/SettingsPage.qml
+++ b/examples/quickcontrols/ios/todolist/SettingsPage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
@@ -52,7 +52,7 @@ Page {
required property string page
Image {
- source: Qt.styleHints.appearance === Qt.Dark ? "images/back-white.png"
+ source: Qt.styleHints.colorScheme === Qt.Dark ? "images/back-white.png"
: "images/back.png"
width: 20
height: 20
diff --git a/examples/quickcontrols/ios/todolist/ToggleCompletedTasksPage.qml b/examples/quickcontrols/ios/todolist/ToggleCompletedTasksPage.qml
index df2145866a..7e42eaf8f3 100644
--- a/examples/quickcontrols/ios/todolist/ToggleCompletedTasksPage.qml
+++ b/examples/quickcontrols/ios/todolist/ToggleCompletedTasksPage.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Controls
@@ -27,6 +27,7 @@ Page {
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: 10
+ Layout.fillWidth: false
onClicked: AppSettings.showDoneTasks = checked
}
diff --git a/examples/quickcontrols/ios/todolist/main.qml b/examples/quickcontrols/ios/todolist/main.qml
index a0067643f1..d4318dfd69 100644
--- a/examples/quickcontrols/ios/todolist/main.qml
+++ b/examples/quickcontrols/ios/todolist/main.qml
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
import QtQuick
import QtQuick.Window
diff --git a/examples/quickcontrols/ios/todolist/src/main.cpp b/examples/quickcontrols/ios/todolist/src/main.cpp
index 4f158402a2..f0b0e194fb 100644
--- a/examples/quickcontrols/ios/todolist/src/main.cpp
+++ b/examples/quickcontrols/ios/todolist/src/main.cpp
@@ -1,5 +1,5 @@
// Copyright (C) 2022 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
#include <QGuiApplication>
#include <QQmlApplicationEngine>