summaryrefslogtreecommitdiffstats
path: root/examples/applicationmanager/application-features
diff options
context:
space:
mode:
authorDominik Holland <dominik.holland@qt.io>2021-06-21 16:25:49 +0200
committerDominik Holland <dominik.holland@qt.io>2021-06-28 15:32:27 +0200
commit37d87aa343f0367ab9e8456296f423031c21bb34 (patch)
tree54203785438b9e445107e73a784988a1cb82a102 /examples/applicationmanager/application-features
parent5784707989188dc9a60f7c6d4f76c20a59b3368d (diff)
Make all qml-only examples usable from within QtCreator
This adds a new qt6_am_add_systemui_wrapper cmake function which generates a wrapper script and makes sure this is callable from within QtCreator. Change-Id: I8270d31167ef5572514d294d634f55962af04355 Reviewed-by: Robert Griebl <robert.griebl@qt.io>
Diffstat (limited to 'examples/applicationmanager/application-features')
-rw-r--r--examples/applicationmanager/application-features/CMakeLists.txt16
-rw-r--r--examples/applicationmanager/application-features/apps/compositor/compositor.qml6
-rw-r--r--examples/applicationmanager/application-features/imports/terminator2/CMakeLists.txt12
-rw-r--r--examples/applicationmanager/application-features/native/widgets/CMakeLists.txt4
4 files changed, 19 insertions, 19 deletions
diff --git a/examples/applicationmanager/application-features/CMakeLists.txt b/examples/applicationmanager/application-features/CMakeLists.txt
index 4df08997..6594ddb6 100644
--- a/examples/applicationmanager/application-features/CMakeLists.txt
+++ b/examples/applicationmanager/application-features/CMakeLists.txt
@@ -1,7 +1,7 @@
# Generated from application-features.pro.
cmake_minimum_required(VERSION 3.14)
-project(ui LANGUAGES CXX)
+project(application-features LANGUAGES CXX)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
@@ -15,16 +15,12 @@ endif()
set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/applicationmanager/application-features")
-)
-set_target_properties(ui PROPERTIES
- WIN32_EXECUTABLE TRUE
- MACOSX_BUNDLE TRUE
-)
+find_package(Qt6 COMPONENTS AppManMainPrivate)
-install(TARGETS ui
- RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
- BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
- LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+qt6_am_add_systemui_wrapper(application-features
+ CONFIG_YAML am-config.yaml
+ EXTRA_FILES apps system-ui
)
+
add_subdirectory(imports)
add_subdirectory(native)
diff --git a/examples/applicationmanager/application-features/apps/compositor/compositor.qml b/examples/applicationmanager/application-features/apps/compositor/compositor.qml
index 9624d353..64028fd3 100644
--- a/examples/applicationmanager/application-features/apps/compositor/compositor.qml
+++ b/examples/applicationmanager/application-features/apps/compositor/compositor.qml
@@ -52,6 +52,8 @@
import QtQuick 2.11
import QtApplicationManager.Application 2.0
import QtWayland.Compositor 1.3
+import QtWayland.Compositor.XdgShell
+import QtWayland.Compositor.WlShell
ApplicationManagerWindow {
id: root
@@ -83,10 +85,6 @@ ApplicationManagerWindow {
onWlShellSurfaceCreated: shellSurfaces.append({shellSurface: shellSurface});
}
- XdgShellV6 {
- onToplevelCreated: shellSurfaces.append({shellSurface: xdgSurface});
- }
-
XdgShell {
onToplevelCreated: shellSurfaces.append({shellSurface: xdgSurface});
}
diff --git a/examples/applicationmanager/application-features/imports/terminator2/CMakeLists.txt b/examples/applicationmanager/application-features/imports/terminator2/CMakeLists.txt
index 945ad301..bd2a9371 100644
--- a/examples/applicationmanager/application-features/imports/terminator2/CMakeLists.txt
+++ b/examples/applicationmanager/application-features/imports/terminator2/CMakeLists.txt
@@ -21,15 +21,17 @@ find_package(Qt6 COMPONENTS Qml)
find_package(Qt6 COMPONENTS Quick)
qt6_add_qml_module(terminator2plugin
- OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CURRENT_BINARY_DIR}/../../apps/crash/Terminator"
- VERSION 1.0
+ OUTPUT_DIRECTORY "../../apps/crash/Terminator"
+ VERSION 2.0
URI "Terminator"
- INSTALL_LOCATION ${INSTALL_EXAMPLEDIR}
+ NO_GENERATE_PLUGIN_SOURCE
+ PLUGIN_TARGET terminator2plugin
)
target_sources(terminator2plugin PRIVATE
qmlterminator2.cpp qmlterminator2.h
)
+
set_target_properties(terminator2plugin PROPERTIES
WIN32_EXECUTABLE TRUE
MACOSX_BUNDLE TRUE
@@ -46,3 +48,7 @@ install(TARGETS terminator2plugin
BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
)
+
+install(FILES "${CMAKE_CURRENT_BINARY_DIR}/../../apps/crash/Terminator/qmldir"
+ DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/applicationmanager/application-features/native/widgets/CMakeLists.txt b/examples/applicationmanager/application-features/native/widgets/CMakeLists.txt
index 11f79f20..148cdb39 100644
--- a/examples/applicationmanager/application-features/native/widgets/CMakeLists.txt
+++ b/examples/applicationmanager/application-features/native/widgets/CMakeLists.txt
@@ -30,8 +30,8 @@ target_link_libraries(widgets PUBLIC
Qt::Core
Qt::Gui
Qt::Widgets
- appman_commonPrivate
- appman_launcherPrivate
+ Qt::AppManCommonPrivate
+ Qt::AppManLauncherPrivate
)
install(TARGETS widgets