[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: [kde-workspace/plasma/sreich/tasks-qml] plasma/desktop/applets/tasks: remove dataengine usage from t
From: Shaun Reich <shaun.reich () kdemail ! net>
Date: 2012-02-11 0:58:06
Message-ID: 20120211005806.B0435A60BE () git ! kde ! org
[Download RAW message or body]
Git commit 7e5270134880130c3e5b7ef7afb3cc7438e14805 by Shaun Reich.
Committed on 11/02/2012 at 01:53.
Pushed by sreich into branch 'plasma/sreich/tasks-qml'.
remove dataengine usage from the qml applet
currenlty it's getting a symbol look up error. i guess it's not linking
to it or something
M +14 -14 plasma/desktop/applets/tasks/package/contents/ui/main.qml
M +4 -12 plasma/desktop/applets/tasks/tasks.cpp
http://commits.kde.org/kde-workspace/7e5270134880130c3e5b7ef7afb3cc7438e14805
diff --git a/plasma/desktop/applets/tasks/package/contents/ui/main.qml \
b/plasma/desktop/applets/tasks/package/contents/ui/main.qml index 426b0e5..fbba026 \
100644
--- a/plasma/desktop/applets/tasks/package/contents/ui/main.qml
+++ b/plasma/desktop/applets/tasks/package/contents/ui/main.qml
@@ -29,20 +29,20 @@ Item {
property int minimumWidth: 300
property int minimumHeight: 300
- PlasmaCore.DataSource {
- id: tasksSource
- engine: "tasks"
- onSourceAdded: connectSource(source)
- onSourceRemoved: disconnectSource(source)
-
- Component.onCompleted: connectedSources = sources
- }
-
- PlasmaCore.DataModel {
- id: tasksModel
- dataSource: tasksSource
- }
-
+// PlasmaCore.DataSource {
+// id: tasksSource
+// engine: "tasks"
+// onSourceAdded: connectSource(source)
+// onSourceRemoved: disconnectSource(source)
+//
+// Component.onCompleted: connectedSources = sources
+// }
+//
+// PlasmaCore.DataModel {
+// id: tasksModel
+// dataSource: tasksSource
+// }
+//
Component.onCompleted: {
// plasmoid.popupIcon = "utilities-terminal";
// plasmoid.aspectRatioMode = IgnoreAspectRatio;
diff --git a/plasma/desktop/applets/tasks/tasks.cpp \
b/plasma/desktop/applets/tasks/tasks.cpp index 06bf3fd..1a35767 100644
--- a/plasma/desktop/applets/tasks/tasks.cpp
+++ b/plasma/desktop/applets/tasks/tasks.cpp
@@ -49,7 +49,6 @@ Tasks::Tasks(QObject *parent, const QVariantList &args)
setAspectRatioMode(Plasma::IgnoreAspectRatio);
setHasConfigurationInterface(false);
-
}
Tasks::~Tasks()
@@ -59,12 +58,6 @@ Tasks::~Tasks()
void Tasks::init()
{
- QGraphicsLinearLayout *lay = new QGraphicsLinearLayout(this);
- m_declarativeWidget = new Plasma::DeclarativeWidget(this);
- lay->addItem(m_declarativeWidget);
-
-
-
m_groupManager = new TaskManager::GroupManager(this);
@@ -74,21 +67,20 @@ void Tasks::init()
m_groupManager->setScreen(c->screen());
}
-
-
-
-
+ QGraphicsLinearLayout *lay = new QGraphicsLinearLayout(this);
+ m_declarativeWidget = new Plasma::DeclarativeWidget(this);
+ lay->addItem(m_declarativeWidget);
qRegisterMetaType<TaskManager::TasksModel*>();
m_tasksModel = new TaskManager::TasksModel(m_groupManager, this);
+ Q_ASSERT(m_tasksModel);
Plasma::PackageStructure::Ptr structure = \
Plasma::PackageStructure::load("Plasma/Generic");
m_package = new Plasma::Package(QString(), "org.kde.tasks", structure);
m_declarativeWidget->setQmlPath(m_package->filePath("mainscript"));
m_declarativeWidget->engine()->rootContext()->setContextProperty("tasksModel", \
QVariant::fromValue(m_tasksModel));
-
}
void Tasks::configChanged()
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic