From 85735ce130a91e5f7ffcee454873a26576a9718f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20K=C3=BCgler?= Date: Thu, 15 Mar 2012 20:47:25 +0100 Subject: [PATCH] Cleanup, add docs, copyright --- .../plasmaextracomponents/CMakeLists.txt | 4 +--- .../plasmaextracomponentsplugin.cpp | 15 +++++-------- .../plasmaextracomponents/qml/Title.qml | 22 +++++++++---------- 3 files changed, 18 insertions(+), 23 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/CMakeLists.txt b/declarativeimports/plasmaextracomponents/CMakeLists.txt index 525993e4a..3d6f384e5 100644 --- a/declarativeimports/plasmaextracomponents/CMakeLists.txt +++ b/declarativeimports/plasmaextracomponents/CMakeLists.txt @@ -1,7 +1,6 @@ project(plasmaextracomponents) set(plasmaextracomponents_SRCS - #../core/declarativeitemcontainer.cpp plasmaextracomponentsplugin.cpp ) @@ -15,14 +14,13 @@ qt4_automoc(${plasmaextracomponents_SRCS}) add_library(plasmaextracomponentsplugin SHARED ${plasmaextracomponents_SRCS}) -target_link_libraries(plasmaextracomponentsplugin ${QT_QTCORE_LIBRARY} ${QT_QTDECLARATIVE_LIBRARY} ${QT_QTGUI_LIBRARY} ${KDE4_KDEUI_LIBRARY} ${KDE4_PLASMA_LIBS}) +target_link_libraries(plasmaextracomponentsplugin ${QT_QTCORE_LIBRARY} ${QT_QTDECLARATIVE_LIBRARY} ${QT_QTGUI_LIBRARY} ${KDE4_PLASMA_LIBS}) install(TARGETS plasmaextracomponentsplugin DESTINATION ${IMPORTS_INSTALL_DIR}/org/kde/plasma/extras) install(DIRECTORY qml/ DESTINATION ${IMPORTS_INSTALL_DIR}/org/kde/plasma/extras) - # The platform specific stuff, overwrites a copy of the desktop one # it does install some files on top of the old ones, has to be done # file by file since if some component from the generic set is more diff --git a/declarativeimports/plasmaextracomponents/plasmaextracomponentsplugin.cpp b/declarativeimports/plasmaextracomponents/plasmaextracomponentsplugin.cpp index eaf90f605..026ec4a4a 100644 --- a/declarativeimports/plasmaextracomponents/plasmaextracomponentsplugin.cpp +++ b/declarativeimports/plasmaextracomponents/plasmaextracomponentsplugin.cpp @@ -1,5 +1,4 @@ /* - * Copyright 2011 by Marco Martin * Copyright 2012 by Sebastian Kügler * This program is free software; you can redistribute it and/or modify @@ -21,26 +20,24 @@ #include "plasmaextracomponentsplugin.h" #include -#include -#include -#include -#include -#include -#include +// #include +// #include void PlasmaExtraComponentsPlugin::registerTypes(const char *uri) { Q_ASSERT(uri == QLatin1String("org.kde.plasma.extras")); - + /* + // Enable when adding touch-specific components QString componentsPlatform = getenv("KDE_PLASMA_COMPONENTS_PLATFORM"); if (componentsPlatform.isEmpty()) { KConfigGroup cg(KSharedConfig::openConfig("kdeclarativerc"), "Components-platform"); componentsPlatform = cg.readEntry("name", "desktop"); } - // Register types... + */ + // Register additional types here... } diff --git a/declarativeimports/plasmaextracomponents/qml/Title.qml b/declarativeimports/plasmaextracomponents/qml/Title.qml index cd52113d9..f74c70985 100644 --- a/declarativeimports/plasmaextracomponents/qml/Title.qml +++ b/declarativeimports/plasmaextracomponents/qml/Title.qml @@ -1,5 +1,5 @@ /* -* Copyright (C) 2011 by Marco Martin +* Copyright 2012 by Sebastian Kügler * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -19,28 +19,28 @@ /**Documented API Inherits: - Text + Label Imports: QtQuick 1.1 - org.kde.plasma.core + org.kde.plasma.components Description: - This is a label which uses the plasma theme. - The characteristics of the text will be automatically seted - according to the plasma theme. If you need a more customized - text,then you can use the Text component from QtQuick. + This is a title label which uses the plasma theme. + The characteristics of the text will be automatically set + according to the plasma theme. Use this components for titles + in your UI, for example page or section titles. Properties: string text: - The most important property is "text". - For the other ones see the primitive QML Text element + The most important property is "text", which applies to the text property of Label + For the other ones see Plasma Component's Label or QML primitive Text element Methods: - See the primitive QML Text element + See Plasma Component's Label and primitive QML Text element Signals: - See the primitive QML Text element + See Plasma Component's Label and primitive QML Text element **/ import QtQuick 1.1