1
/***************************************************************************
2
* Copyright (C) 2010 by Anton Kreuzkamp <akreuzkamp@web.de> *
4
* This program is free software; you can redistribute it and/or modify *
5
* it under the terms of the GNU General Public License as published by *
6
* the Free Software Foundation; either version 2 of the License, or *
7
* (at your option) any later version. *
9
* This program is distributed in the hope that it will be useful, *
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12
* GNU General Public License for more details. *
14
* You should have received a copy of the GNU General Public License *
15
* along with this program; if not, write to the *
16
* Free Software Foundation, Inc., *
17
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . *
18
***************************************************************************/
21
#ifndef APPLAUNCHERITEM_H
22
#define APPLAUNCHERITEM_H
24
#include "abstracttaskitem.h"
26
#include <taskmanager/taskmanager.h>
27
#include <taskmanager/launcheritem.h>
30
* A launcheritem to quickly launch applications.
32
class AppLauncherItem : public AbstractTaskItem
37
/** Constructs a new representation for a launcher. */
38
AppLauncherItem(QGraphicsWidget *parent, Tasks *applet, TaskManager::LauncherItem *launcher);
40
TaskManager::LauncherItem* launcher() { return m_launcher; }
42
virtual bool isWindowItem() const { return false; }
43
virtual bool isActive() const { return false; }
44
virtual void setAdditionalMimeData(QMimeData* mimeData);
45
virtual void close() {}
46
virtual void updateTask(TaskManager::TaskChanges) {}
49
virtual void activate() {}
52
void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
53
void keyPressEvent(QKeyEvent *event);
54
void contextMenuEvent(QGraphicsSceneContextMenuEvent *event);
59
TaskManager::LauncherItem *m_launcher;