aboutsummaryrefslogtreecommitdiffstats
path: root/src/quickcontrols/basic/qtquickcontrols2basicstyleplugin.cpp
blob: e2d726082b49b15ffc90b0012934dd45dfcfa00a (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
45
46
// Copyright (C) 2020 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only

#include "qquickbasicstyle_p.h"
#include "qquickbasictheme_p.h"

#include <QtQuickControls2/private/qquickstyleplugin_p.h>

QT_BEGIN_NAMESPACE

extern void qml_register_types_QtQuick_Controls_Basic();
Q_GHS_KEEP_REFERENCE(qml_register_types_QtQuick_Controls_Basic);

class QtQuickControls2BasicStylePlugin: public QQuickStylePlugin
{
    Q_OBJECT
    Q_PLUGIN_METADATA(IID QQmlExtensionInterface_iid)

public:
    QtQuickControls2BasicStylePlugin(QObject *parent = nullptr);

    QString name() const override;
    void initializeTheme(QQuickTheme *theme) override;

    QQuickBasicTheme theme;
};

QtQuickControls2BasicStylePlugin::QtQuickControls2BasicStylePlugin(QObject *parent) : QQuickStylePlugin(parent)
{
    volatile auto registration = &qml_register_types_QtQuick_Controls_Basic;
    Q_UNUSED(registration);
}

QString QtQuickControls2BasicStylePlugin::name() const
{
    return QStringLiteral("Basic");
}

void QtQuickControls2BasicStylePlugin::initializeTheme(QQuickTheme *theme)
{
    this->theme.initialize(theme);
}

QT_END_NAMESPACE

#include "qtquickcontrols2basicstyleplugin.moc"