~ubuntu-branches/ubuntu/gutsy/kdebase-workspace/gutsy

« back to all changes in this revision

Viewing changes to plasma/engines/tasks/tasksengine.h

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2007-10-11 14:04:48 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20071011140448-v0eb7lxbb24zagca
Tags: 3.94.0-0ubuntu1
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *   Copyright (C) 2007 Robert Knight <robertknight@gmail.com> 
 
3
 *
 
4
 *   This program is free software; you can redistribute it and/or modify
 
5
 *   it under the terms of the GNU Library General Public License version 2 as
 
6
 *   published by the Free Software Foundation
 
7
 *
 
8
 *   This program is distributed in the hope that it will be useful,
 
9
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 
10
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
11
 *   GNU General Public License for more details
 
12
 *
 
13
 *   You should have received a copy of the GNU Library General Public
 
14
 *   License along with this program; if not, write to the
 
15
 *   Free Software Foundation, Inc.,
 
16
 *   51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
17
 */
 
18
 
 
19
#ifndef TASKSENGINE_H
 
20
#define TASKSENGINE_H
 
21
 
 
22
// Qt
 
23
#include <QObject>
 
24
#include <QString>
 
25
#include <QList>
 
26
 
 
27
// Plasma
 
28
#include <plasma/dataengine.h>
 
29
#include <taskmanager/taskmanager.h>
 
30
 
 
31
/**
 
32
 * This class evaluates the basic expressions given in the interface.
 
33
 */
 
34
class TasksEngine : public Plasma::DataEngine
 
35
{
 
36
    Q_OBJECT
 
37
 
 
38
    public:
 
39
                TasksEngine( QObject* parent, const QVariantList& args);
 
40
 
 
41
    protected:
 
42
        virtual void init();
 
43
 
 
44
    private slots:
 
45
        void taskChanged();
 
46
        void taskAdded(Task::TaskPtr task);
 
47
        void taskRemoved(Task::TaskPtr task);
 
48
 
 
49
    private:
 
50
        void connectTask(Task::TaskPtr task);
 
51
        void setDataForTask(Task::TaskPtr task);
 
52
};
 
53
 
 
54
K_EXPORT_PLASMA_DATAENGINE(tasks, TasksEngine)
 
55
 
 
56
#endif