From 79c0e7a73db89269d2f939e7bce438e184ebca16 Mon Sep 17 00:00:00 2001 From: Marco Martin Date: Fri, 1 Feb 2013 11:50:29 +0100 Subject: [PATCH] pput the sample qml file in a package --- shell/CMakeLists.txt | 5 +++-- shell/qmlpackages/CMakeLists.txt | 2 ++ shell/qmlpackages/desktop/CMakeLists.txt | 5 +++++ shell/qmlpackages/desktop/Messages.sh | 3 +++ .../desktop/contents/ui}/main.qml | 0 shell/qmlpackages/desktop/metadata.desktop | 17 +++++++++++++++++ 6 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 shell/qmlpackages/CMakeLists.txt create mode 100644 shell/qmlpackages/desktop/CMakeLists.txt create mode 100644 shell/qmlpackages/desktop/Messages.sh rename shell/{ => qmlpackages/desktop/contents/ui}/main.qml (100%) create mode 100644 shell/qmlpackages/desktop/metadata.desktop diff --git a/shell/CMakeLists.txt b/shell/CMakeLists.txt index 0dd5846b4..e5363df14 100644 --- a/shell/CMakeLists.txt +++ b/shell/CMakeLists.txt @@ -1,7 +1,6 @@ project(testplasma2) - # Tell CMake to run moc when necessary: set(CMAKE_AUTOMOC ON) # As moc files are generated in the binary dir, tell CMake @@ -49,4 +48,6 @@ target_link_libraries(testplasma2 #plasma ) -install(TARGETS testplasma2 ${INSTALL_TARGETS_DEFAULT_ARGS}) \ No newline at end of file +install(TARGETS testplasma2 ${INSTALL_TARGETS_DEFAULT_ARGS}) + +add_subdirectory(qmlpackages) diff --git a/shell/qmlpackages/CMakeLists.txt b/shell/qmlpackages/CMakeLists.txt new file mode 100644 index 000000000..d3d3e1f2d --- /dev/null +++ b/shell/qmlpackages/CMakeLists.txt @@ -0,0 +1,2 @@ + +add_subdirectory(desktop) diff --git a/shell/qmlpackages/desktop/CMakeLists.txt b/shell/qmlpackages/desktop/CMakeLists.txt new file mode 100644 index 000000000..3f48fb212 --- /dev/null +++ b/shell/qmlpackages/desktop/CMakeLists.txt @@ -0,0 +1,5 @@ +project(desktop_homescreen) + +install(DIRECTORY . DESTINATION ${DATA_INSTALL_DIR}/plasma/packages/org.kde.homescreen.desktop PATTERN .svn EXCLUDE PATTERN CMakeLists.txt EXCLUDE PATTERN Messages.sh EXCLUDE) + + diff --git a/shell/qmlpackages/desktop/Messages.sh b/shell/qmlpackages/desktop/Messages.sh new file mode 100644 index 000000000..da18c7d3a --- /dev/null +++ b/shell/qmlpackages/desktop/Messages.sh @@ -0,0 +1,3 @@ +#! /usr/bin/env bash +$XGETTEXT `find . -name \*.qml` -L Java -o $podir/plasma_package_org.kde.active.contour-tablet-homescreen.pot +rm -f rc.cpp diff --git a/shell/main.qml b/shell/qmlpackages/desktop/contents/ui/main.qml similarity index 100% rename from shell/main.qml rename to shell/qmlpackages/desktop/contents/ui/main.qml diff --git a/shell/qmlpackages/desktop/metadata.desktop b/shell/qmlpackages/desktop/metadata.desktop new file mode 100644 index 000000000..850f24046 --- /dev/null +++ b/shell/qmlpackages/desktop/metadata.desktop @@ -0,0 +1,17 @@ +[Desktop Entry] +Comment=Desktop view furniture +Encoding=UTF-8 +Keywords= +Name=Desktop +Type=Service + +X-KDE-ServiceTypes=Plasma/GenericPackage +X-KDE-ParentApp= +X-KDE-PluginInfo-Author=Marco Martin +X-KDE-PluginInfo-Category= +X-KDE-PluginInfo-Email=mart@kde.org +X-KDE-PluginInfo-License=GPLv2+ +X-KDE-PluginInfo-Name=org.kde.homescreen.desktop +X-KDE-PluginInfo-Version= +X-KDE-PluginInfo-Website= +X-Plasma-MainScript=ui/main.qml