diff --git a/src/scripts/CMakeLists.txt b/src/scripts/CMakeLists.txt index 66b6c3ccd2..68250cad6d 100644 --- a/src/scripts/CMakeLists.txt +++ b/src/scripts/CMakeLists.txt @@ -1,12 +1,12 @@ -function(add_kwin_script name) - kpackage_install_package(${name} ${name} scripts kwin) +function(kwin_add_script name source) + kpackage_install_package(${source} ${name} scripts kwin) # Copy the script to the build directory so one can run tests without prior # make install. FIXME: use add_custom_command. - file(COPY ${name} DESTINATION ${CMAKE_BINARY_DIR}/bin/kwin/scripts/) + file(COPY ${source}/contents ${source}/metadata.json DESTINATION ${CMAKE_BINARY_DIR}/bin/kwin/scripts/${name}) endfunction() -add_kwin_script(videowall) -add_kwin_script(synchronizeskipswitcher) -add_kwin_script(desktopchangeosd) -add_kwin_script(minimizeall) +add_subdirectory(desktopchangeosd) +add_subdirectory(minimizeall) +add_subdirectory(synchronizeskipswitcher) +add_subdirectory(videowall) diff --git a/src/scripts/desktopchangeosd/CMakeLists.txt b/src/scripts/desktopchangeosd/CMakeLists.txt new file mode 100644 index 0000000000..32a6233649 --- /dev/null +++ b/src/scripts/desktopchangeosd/CMakeLists.txt @@ -0,0 +1 @@ +kwin_add_script(desktopchangeosd package) diff --git a/src/scripts/desktopchangeosd/contents/ui/main.qml b/src/scripts/desktopchangeosd/package/contents/ui/main.qml similarity index 100% rename from src/scripts/desktopchangeosd/contents/ui/main.qml rename to src/scripts/desktopchangeosd/package/contents/ui/main.qml diff --git a/src/scripts/desktopchangeosd/contents/ui/osd.qml b/src/scripts/desktopchangeosd/package/contents/ui/osd.qml similarity index 100% rename from src/scripts/desktopchangeosd/contents/ui/osd.qml rename to src/scripts/desktopchangeosd/package/contents/ui/osd.qml diff --git a/src/scripts/desktopchangeosd/metadata.json b/src/scripts/desktopchangeosd/package/metadata.json similarity index 100% rename from src/scripts/desktopchangeosd/metadata.json rename to src/scripts/desktopchangeosd/package/metadata.json diff --git a/src/scripts/minimizeall/CMakeLists.txt b/src/scripts/minimizeall/CMakeLists.txt new file mode 100644 index 0000000000..8d7f9a2de3 --- /dev/null +++ b/src/scripts/minimizeall/CMakeLists.txt @@ -0,0 +1 @@ +kwin_add_script(minimizeall package) diff --git a/src/scripts/minimizeall/contents/code/main.js b/src/scripts/minimizeall/package/contents/code/main.js similarity index 100% rename from src/scripts/minimizeall/contents/code/main.js rename to src/scripts/minimizeall/package/contents/code/main.js diff --git a/src/scripts/minimizeall/metadata.json b/src/scripts/minimizeall/package/metadata.json similarity index 100% rename from src/scripts/minimizeall/metadata.json rename to src/scripts/minimizeall/package/metadata.json diff --git a/src/scripts/synchronizeskipswitcher/CMakeLists.txt b/src/scripts/synchronizeskipswitcher/CMakeLists.txt new file mode 100644 index 0000000000..a5d280a6d8 --- /dev/null +++ b/src/scripts/synchronizeskipswitcher/CMakeLists.txt @@ -0,0 +1 @@ +kwin_add_script(synchronizeskipswitcher package) diff --git a/src/scripts/synchronizeskipswitcher/contents/code/main.js b/src/scripts/synchronizeskipswitcher/package/contents/code/main.js similarity index 100% rename from src/scripts/synchronizeskipswitcher/contents/code/main.js rename to src/scripts/synchronizeskipswitcher/package/contents/code/main.js diff --git a/src/scripts/synchronizeskipswitcher/metadata.json b/src/scripts/synchronizeskipswitcher/package/metadata.json similarity index 100% rename from src/scripts/synchronizeskipswitcher/metadata.json rename to src/scripts/synchronizeskipswitcher/package/metadata.json diff --git a/src/scripts/videowall/CMakeLists.txt b/src/scripts/videowall/CMakeLists.txt new file mode 100644 index 0000000000..83c9855008 --- /dev/null +++ b/src/scripts/videowall/CMakeLists.txt @@ -0,0 +1 @@ +kwin_add_script(videowall package) diff --git a/src/scripts/videowall/contents/code/main.js b/src/scripts/videowall/package/contents/code/main.js similarity index 100% rename from src/scripts/videowall/contents/code/main.js rename to src/scripts/videowall/package/contents/code/main.js diff --git a/src/scripts/videowall/contents/config/main.xml b/src/scripts/videowall/package/contents/config/main.xml similarity index 100% rename from src/scripts/videowall/contents/config/main.xml rename to src/scripts/videowall/package/contents/config/main.xml diff --git a/src/scripts/videowall/contents/ui/config.ui b/src/scripts/videowall/package/contents/ui/config.ui similarity index 100% rename from src/scripts/videowall/contents/ui/config.ui rename to src/scripts/videowall/package/contents/ui/config.ui diff --git a/src/scripts/videowall/metadata.json b/src/scripts/videowall/package/metadata.json similarity index 100% rename from src/scripts/videowall/metadata.json rename to src/scripts/videowall/package/metadata.json