KCalendarCore

kcalendarcoreqmlplugin.cpp
1/*
2 SPDX-FileCopyrightText: 2024 Volker Krause <vkrause@kde.org>
3 SPDX-License-Identifier: LGPL-2.0-or-later
4*/
5
6#include <KCalendarCore/CalendarPluginLoader>
7
8#include <QQmlEngine>
9#include <QQmlExtensionPlugin>
10
11class KCalendarCoreQmlPlugin : public QQmlExtensionPlugin
12{
14 Q_PLUGIN_METADATA(IID QQmlExtensionInterface_iid)
15
16public:
17 void registerTypes(const char *uri) override;
18};
19
20void KCalendarCoreQmlPlugin::registerTypes(const char *uri)
21{
22 qmlRegisterSingletonType(uri, 1, 0, "CalendarPluginLoader", [](QQmlEngine *, QJSEngine *jsEngine) -> QJSValue {
24 });
25}
26
27#include "kcalendarcoreqmlplugin.moc"
Provides access to a KCalendarCore::CalendarPlugin instance, if available.
QJSValue toScriptValue(const T &value)
Q_OBJECTQ_OBJECT
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sun Nov 17 2024 19:28:08 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.