Changeset View
Changeset View
Standalone View
Standalone View
src/kontactplugin/korganizer/todoplugin.cpp
Show All 35 Lines | |||||
36 | #include <KCalUtils/ICalDrag> | 36 | #include <KCalUtils/ICalDrag> | ||
37 | 37 | | |||
38 | #include <KontactInterface/Core> | 38 | #include <KontactInterface/Core> | ||
39 | 39 | | |||
40 | #include <QAction> | 40 | #include <QAction> | ||
41 | #include <KActionCollection> | 41 | #include <KActionCollection> | ||
42 | #include "korganizerplugin_debug.h" | 42 | #include "korganizerplugin_debug.h" | ||
43 | #include <QIcon> | 43 | #include <QIcon> | ||
44 | #include <KIconLoader> | | |||
45 | #include <KLocalizedString> | 44 | #include <KLocalizedString> | ||
46 | #include <KMessageBox> | 45 | #include <KMessageBox> | ||
47 | #include <QTemporaryFile> | 46 | #include <QTemporaryFile> | ||
48 | 47 | | |||
49 | #include <QDropEvent> | 48 | #include <QDropEvent> | ||
50 | 49 | | |||
51 | EXPORT_KONTACT_PLUGIN(TodoPlugin, todo) | 50 | EXPORT_KONTACT_PLUGIN(TodoPlugin, todo) | ||
52 | 51 | | |||
53 | TodoPlugin::TodoPlugin(KontactInterface::Core *core, const QVariantList &) | 52 | TodoPlugin::TodoPlugin(KontactInterface::Core *core, const QVariantList &) | ||
54 | : KontactInterface::Plugin(core, core, "korganizer", "todo") | 53 | : KontactInterface::Plugin(core, core, "korganizer", "todo") | ||
55 | , mIface(nullptr) | 54 | , mIface(nullptr) | ||
56 | { | 55 | { | ||
57 | setComponentName(QStringLiteral("korganizer"), i18n("KOrganizer")); | 56 | setComponentName(QStringLiteral("korganizer"), i18n("KOrganizer")); | ||
58 | KIconLoader::global()->addAppDir(QStringLiteral("korganizer")); | | |||
59 | 57 | | |||
60 | QAction *action | 58 | QAction *action | ||
61 | = new QAction(QIcon::fromTheme(QStringLiteral("task-new")), | 59 | = new QAction(QIcon::fromTheme(QStringLiteral("task-new")), | ||
62 | i18nc("@action:inmenu", "New To-do..."), this); | 60 | i18nc("@action:inmenu", "New To-do..."), this); | ||
63 | actionCollection()->addAction(QStringLiteral("new_todo"), action); | 61 | actionCollection()->addAction(QStringLiteral("new_todo"), action); | ||
64 | actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_T)); | 62 | actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_T)); | ||
65 | QString str = i18nc("@info:status", "Create a new to-do"); | 63 | QString str = i18nc("@info:status", "Create a new to-do"); | ||
66 | action->setStatusTip(str); | 64 | action->setStatusTip(str); | ||
▲ Show 20 Lines • Show All 174 Lines • Show Last 20 Lines |