1
/***************************************************************************
2
* Copyright (C) 2007-2009 by Shawn Starr <shawn.starr@rogers.com> *
3
* Copyright (C) 2012 by Luís Gabriel Lima <lampih@gmail.com> *
4
* Copyright (C) 2012 by Daniel Nicoletti <dantti12@gmail.com> *
6
* This program is free software; you can redistribute it and/or modify *
7
* it under the terms of the GNU General Public License as published by *
8
* the Free Software Foundation; either version 2 of the License, or *
9
* (at your option) any later version. *
11
* This program is distributed in the hope that it will be useful, *
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14
* GNU General Public License for more details. *
16
* You should have received a copy of the GNU General Public License *
17
* along with this program; if not, write to the *
18
* Free Software Foundation, Inc., *
19
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . *
20
***************************************************************************/
22
#ifndef UPDATERAPPLET_H
23
#define UPDATERAPPLET_H
25
#include <Plasma/PopupApplet>
29
class DeclarativeWidget;
33
class DBusUpdaterInterface;
34
class UpdaterApplet : public Plasma::PopupApplet
38
UpdaterApplet(QObject *parent, const QVariantList &args);
42
virtual QList<QAction*> contextualActions();
43
QGraphicsWidget *graphicsWidget();
47
void checkForNewUpdates();
49
void installUpdates();
53
void toolTipAboutToShow();
54
void setActive(bool active = true);
55
uint getTimeSinceLastRefresh();
58
void constraintsEvent(Plasma::Constraints constraints);
59
virtual void popupEvent(bool show);
62
QTimer *m_getUpdatesTimer;
63
QList<QAction*> m_actions;
64
Plasma::DeclarativeWidget *m_declarativeWidget;
65
PackageModel *m_updatesModel;
66
DBusUpdaterInterface *m_interface;
70
K_EXPORT_PLASMA_APPLET(updater, UpdaterApplet)
72
#endif // UPDATERAPPLET_H