/****************************************************************************
** Meta object code from reading C++ file 'sourcesmodel.h'
**
** Created by: The Qt Meta Object Compiler version 69 (Qt 6.11.1)
**
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#include "../../../../../plasma-workspace-6.7.1/kcms/notifications/sourcesmodel.h"
#include <QtCore/qmetatype.h>

#include <QtCore/qtmochelpers.h>

#include <memory>


#include <QtCore/qxptype_traits.h>
#if !defined(Q_MOC_OUTPUT_REVISION)
#error "The header file 'sourcesmodel.h' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 69
#error "This file was generated using the moc from 6.11.1. It"
#error "cannot be used with the include files from this version of Qt."
#error "(The moc has changed too much.)"
#endif

#ifndef Q_CONSTINIT
#define Q_CONSTINIT
#endif

QT_WARNING_PUSH
QT_WARNING_DISABLE_DEPRECATED
QT_WARNING_DISABLE_GCC("-Wuseless-cast")
namespace {
struct qt_meta_tag_ZN12SourcesModelE_t {};
} // unnamed namespace

template <> constexpr inline auto SourcesModel::qt_create_metaobjectdata<qt_meta_tag_ZN12SourcesModelE_t>()
{
    namespace QMC = QtMocConstants;
    QtMocHelpers::StringRefStorage qt_stringData {
        "SourcesModel",
        "makePersistentModelIndex",
        "QPersistentModelIndex",
        "",
        "QModelIndex",
        "idx",
        "persistentIndexForDesktopEntry",
        "desktopEntry",
        "persistentIndexForNotifyRcName",
        "notifyRcName",
        "indexOfEvent",
        "parent",
        "eventId",
        "load",
        "Roles",
        "SourceTypeRole",
        "NotifyRcNameRole",
        "DesktopEntryRole",
        "IsDefaultRole",
        "EventIdRole",
        "CommentRole",
        "ShowIconsRole",
        "ActionsRole",
        "SoundRole",
        "DefaultActionsRole",
        "DefaultSoundRole",
        "Type",
        "ApplicationType",
        "ServiceType"
    };

    QtMocHelpers::UintData qt_methods {
        // Method 'makePersistentModelIndex'
        QtMocHelpers::MethodData<QPersistentModelIndex(const QModelIndex &) const>(1, 3, QMC::AccessPublic, 0x80000000 | 2, {{
            { 0x80000000 | 4, 5 },
        }}),
        // Method 'persistentIndexForDesktopEntry'
        QtMocHelpers::MethodData<QPersistentModelIndex(const QString &) const>(6, 3, QMC::AccessPublic, 0x80000000 | 2, {{
            { QMetaType::QString, 7 },
        }}),
        // Method 'persistentIndexForNotifyRcName'
        QtMocHelpers::MethodData<QPersistentModelIndex(const QString &) const>(8, 3, QMC::AccessPublic, 0x80000000 | 2, {{
            { QMetaType::QString, 9 },
        }}),
        // Method 'indexOfEvent'
        QtMocHelpers::MethodData<QPersistentModelIndex(const QModelIndex &, const QString &) const>(10, 3, QMC::AccessPublic, 0x80000000 | 2, {{
            { 0x80000000 | 4, 11 }, { QMetaType::QString, 12 },
        }}),
        // Method 'load'
        QtMocHelpers::MethodData<void()>(13, 3, QMC::AccessPublic, QMetaType::Void),
    };
    QtMocHelpers::UintData qt_properties {
    };
    QtMocHelpers::UintData qt_enums {
        // enum 'Roles'
        QtMocHelpers::EnumData<enum Roles>(14, 14, QMC::EnumFlags{}).add({
            {   15, Roles::SourceTypeRole },
            {   16, Roles::NotifyRcNameRole },
            {   17, Roles::DesktopEntryRole },
            {   18, Roles::IsDefaultRole },
            {   19, Roles::EventIdRole },
            {   20, Roles::CommentRole },
            {   21, Roles::ShowIconsRole },
            {   22, Roles::ActionsRole },
            {   23, Roles::SoundRole },
            {   24, Roles::DefaultActionsRole },
            {   25, Roles::DefaultSoundRole },
        }),
        // enum 'Type'
        QtMocHelpers::EnumData<enum Type>(26, 26, QMC::EnumFlags{}).add({
            {   27, Type::ApplicationType },
            {   28, Type::ServiceType },
        }),
    };
    return QtMocHelpers::metaObjectData<SourcesModel, qt_meta_tag_ZN12SourcesModelE_t>(QMC::MetaObjectFlag{}, qt_stringData,
            qt_methods, qt_properties, qt_enums);
}
Q_CONSTINIT const QMetaObject SourcesModel::staticMetaObject = { {
    QMetaObject::SuperData::link<QAbstractItemModel::staticMetaObject>(),
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN12SourcesModelE_t>.stringdata,
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN12SourcesModelE_t>.data,
    qt_static_metacall,
    nullptr,
    qt_staticMetaObjectRelocatingContent<qt_meta_tag_ZN12SourcesModelE_t>.metaTypes,
    nullptr
} };

void SourcesModel::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
    auto *_t = static_cast<SourcesModel *>(_o);
    if (_c == QMetaObject::InvokeMetaMethod) {
        switch (_id) {
        case 0: { QPersistentModelIndex _r = _t->makePersistentModelIndex((*reinterpret_cast<std::add_pointer_t<QModelIndex>>(_a[1])));
            if (_a[0]) *reinterpret_cast<QPersistentModelIndex*>(_a[0]) = std::move(_r); }  break;
        case 1: { QPersistentModelIndex _r = _t->persistentIndexForDesktopEntry((*reinterpret_cast<std::add_pointer_t<QString>>(_a[1])));
            if (_a[0]) *reinterpret_cast<QPersistentModelIndex*>(_a[0]) = std::move(_r); }  break;
        case 2: { QPersistentModelIndex _r = _t->persistentIndexForNotifyRcName((*reinterpret_cast<std::add_pointer_t<QString>>(_a[1])));
            if (_a[0]) *reinterpret_cast<QPersistentModelIndex*>(_a[0]) = std::move(_r); }  break;
        case 3: { QPersistentModelIndex _r = _t->indexOfEvent((*reinterpret_cast<std::add_pointer_t<QModelIndex>>(_a[1])),(*reinterpret_cast<std::add_pointer_t<QString>>(_a[2])));
            if (_a[0]) *reinterpret_cast<QPersistentModelIndex*>(_a[0]) = std::move(_r); }  break;
        case 4: _t->load(); break;
        default: ;
        }
    }
}

const QMetaObject *SourcesModel::metaObject() const
{
    return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
}

void *SourcesModel::qt_metacast(const char *_clname)
{
    if (!_clname) return nullptr;
    if (!strcmp(_clname, qt_staticMetaObjectStaticContent<qt_meta_tag_ZN12SourcesModelE_t>.strings))
        return static_cast<void*>(this);
    return QAbstractItemModel::qt_metacast(_clname);
}

int SourcesModel::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QAbstractItemModel::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        if (_id < 5)
            qt_static_metacall(this, _c, _id, _a);
        _id -= 5;
    }
    if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
        if (_id < 5)
            *reinterpret_cast<QMetaType *>(_a[0]) = QMetaType();
        _id -= 5;
    }
    return _id;
}
QT_WARNING_POP
