Changeset View
Changeset View
Standalone View
Standalone View
runners/mediawiki/mediawikirunner.h
Show All 14 Lines | |||||
15 | * License along with this program; if not, write to the | 15 | * License along with this program; if not, write to the | ||
16 | * Free Software Foundation, Inc., | 16 | * Free Software Foundation, Inc., | ||
17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | 17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
18 | */ | 18 | */ | ||
19 | 19 | | |||
20 | #ifndef MEDIAWIKIRUNNER_H | 20 | #ifndef MEDIAWIKIRUNNER_H | ||
21 | #define MEDIAWIKIRUNNER_H | 21 | #define MEDIAWIKIRUNNER_H | ||
22 | 22 | | |||
23 | #include <plasma/abstractrunner.h> | 23 | // KF | ||
24 | #include <KRunner/AbstractRunner> | ||||
25 | // Qt | ||||
26 | #include <QNetworkConfigurationManager> | ||||
24 | 27 | | |||
25 | class KIcon; | | |||
26 | 28 | | |||
27 | #include <KIcon> | 29 | class MediaWikiRunner : public Plasma::AbstractRunner | ||
28 | #include <QWaitCondition> | 30 | { | ||
29 | | ||||
30 | class QWaitCondition; | | |||
31 | | ||||
32 | #include "mediawiki.h" | | |||
33 | | ||||
34 | class MediaWikiRunner : public Plasma::AbstractRunner { | | |||
35 | Q_OBJECT | 31 | Q_OBJECT | ||
36 | 32 | | |||
37 | public: | 33 | public: | ||
38 | MediaWikiRunner( QObject *parent, const QVariantList& args ); | 34 | MediaWikiRunner(QObject *parent, const QVariantList &args); | ||
39 | ~MediaWikiRunner(); | 35 | ~MediaWikiRunner() override; | ||
40 | 36 | | |||
41 | void match(Plasma::RunnerContext &context); | 37 | void match(Plasma::RunnerContext &context) override; | ||
42 | void run(const Plasma::RunnerContext &context, const Plasma::QueryMatch &match); | 38 | void run(const Plasma::RunnerContext &context, const Plasma::QueryMatch &match) override; | ||
43 | | ||||
44 | signals: | | |||
45 | void done(); | | |||
46 | 39 | | |||
47 | private: | 40 | private: | ||
48 | KIcon m_icon; | 41 | QString m_iconName; | ||
49 | QString m_name; | 42 | QString m_name; | ||
50 | QString m_comment; | 43 | QString m_comment; | ||
51 | QUrl m_apiUrl; | 44 | QUrl m_apiUrl; | ||
52 | }; | | |||
53 | 45 | | |||
54 | K_EXPORT_PLASMA_RUNNER(mediawiki, MediaWikiRunner) | 46 | QNetworkConfigurationManager m_networkConfigurationManager; | ||
47 | }; | ||||
55 | 48 | | |||
56 | #endif | 49 | #endif |