File indexing completed on 2025-01-26 04:57:29
0001 // SPDX-FileCopyrightText: 2022 Carl Schwan <carl@carlschwan.eu> 0002 // SPDX-License-Identifier: LGPL-2.0-or-later 0003 0004 #include "mimetreeparserplugin.h" 0005 0006 #include <MimeTreeParserCore/AttachmentModel> 0007 #include <MimeTreeParserCore/MessageParser> 0008 #include <MimeTreeParserCore/PartModel> 0009 #include <QQmlEngine> 0010 0011 void MimeTreeParserPlugin::registerTypes(const char *uri) 0012 { 0013 Q_ASSERT(uri == QByteArray("org.kde.pim.mimetreeparser")); 0014 0015 qmlRegisterModule(uri, 1, 0); 0016 qmlRegisterType<MessageParser>(uri, 1, 0, "MessageParser"); 0017 qRegisterMetaType<PartModel::Types>("PartModel::Types"); 0018 qmlRegisterUncreatableType<PartModel>(uri, 1, 0, "PartModel", QStringLiteral("not instanciated")); 0019 qmlRegisterUncreatableType<AttachmentModel>(uri, 1, 0, "AttachmentModel", QStringLiteral("not instanciated")); 0020 } 0021 0022 #include "moc_mimetreeparserplugin.cpp"