aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/todo/todoplugin.cpp
blob: 99bc6afacdce53033ec54571b666a4a50d990230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
// Copyright (C) 2016 Dmitry Savchenko
// Copyright (C) 2016 Vasiliy Sorokin
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0

#include "todooutputpane.h"
#include "todoitemsprovider.h"
#include "todoprojectpanel.h"
#include "todotr.h"

#include <coreplugin/dialogs/ioptionspage.h>
#include <extensionsystem/iplugin.h>

namespace Todo::Internal {

class TodoPlugin final : public ExtensionSystem::IPlugin
{
    Q_OBJECT
    Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QtCreatorPlugin" FILE "Todo.json")

public:
    TodoPlugin()
    {
        qRegisterMetaType<TodoItem>("TodoItem");
    }

    void initialize() final
    {
        Core::IOptionsPage::registerCategory(
            "To-Do", Tr::tr("To-Do"), ":/todoplugin/images/settingscategory_todo.png");

        todoSettings().load();

        setupTodoItemsProvider(this);
        setupTodoOutputPane(this);

        setupTodoSettingsPage();

        setupTodoProjectPanel();
    }
};

} // Todo::Internal

#include "todoplugin.moc"