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

#include "../../../../../../stellarium/plugins/Oculars/src/Ocular.hpp"
#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 'Ocular.hpp' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 69
#error "This file was generated using the moc from 6.11.0. 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_ZN6OcularE_t {};
} // unnamed namespace

template <> constexpr inline auto Ocular::qt_create_metaobjectdata<qt_meta_tag_ZN6OcularE_t>()
{
    namespace QMC = QtMocConstants;
    QtMocHelpers::StringRefStorage qt_stringData {
        "Ocular",
        "",
        "QObject",
        "other",
        "binoculars",
        "permanentCrosshair",
        "apparentFOV",
        "effectiveFocalLength",
        "fieldStop",
        "name",
        "reticlePath"
    };

    QtMocHelpers::UintData qt_methods {
    };
    QtMocHelpers::UintData qt_properties {
        // property 'binoculars'
        QtMocHelpers::PropertyData<bool>(4, QMetaType::Bool, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'permanentCrosshair'
        QtMocHelpers::PropertyData<bool>(5, QMetaType::Bool, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'apparentFOV'
        QtMocHelpers::PropertyData<double>(6, QMetaType::Double, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'effectiveFocalLength'
        QtMocHelpers::PropertyData<double>(7, QMetaType::Double, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'fieldStop'
        QtMocHelpers::PropertyData<double>(8, QMetaType::Double, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'name'
        QtMocHelpers::PropertyData<QString>(9, QMetaType::QString, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
        // property 'reticlePath'
        QtMocHelpers::PropertyData<QString>(10, QMetaType::QString, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet),
    };
    QtMocHelpers::UintData qt_enums {
    };
    using Constructor = QtMocHelpers::NoType;
    QtMocHelpers::UintData qt_constructors {
        QtMocHelpers::ConstructorData<Constructor(const QObject &)>(1, QMC::AccessPublic, {{
            { 0x80000000 | 2, 3 },
        }}),
    };
    return QtMocHelpers::metaObjectData<Ocular, qt_meta_tag_ZN6OcularE_t>(QMC::MetaObjectFlag{}, qt_stringData,
            qt_methods, qt_properties, qt_enums, qt_constructors);
}
Q_CONSTINIT const QMetaObject Ocular::staticMetaObject = { {
    QMetaObject::SuperData::link<QObject::staticMetaObject>(),
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN6OcularE_t>.stringdata,
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN6OcularE_t>.data,
    qt_static_metacall,
    nullptr,
    qt_staticMetaObjectRelocatingContent<qt_meta_tag_ZN6OcularE_t>.metaTypes,
    nullptr
} };

void Ocular::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
    auto *_t = static_cast<Ocular *>(_o);
    if (_c == QMetaObject::CreateInstance) {
        switch (_id) {
        case 0: { Ocular *_r = new Ocular((*reinterpret_cast<std::add_pointer_t<QObject>>(_a[1])));
            if (_a[0]) *reinterpret_cast<QObject**>(_a[0]) = _r; } break;
        default: break;
        }
    }
    if (_c == QMetaObject::ConstructInPlace) {
        switch (_id) {
        case 0: { new (_a[0]) Ocular((*reinterpret_cast<std::add_pointer_t<QObject>>(_a[1]))); } break;
        default: break;
        }
    }
    if (_c == QMetaObject::ReadProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: *reinterpret_cast<bool*>(_v) = _t->isBinoculars(); break;
        case 1: *reinterpret_cast<bool*>(_v) = _t->hasPermanentCrosshair(); break;
        case 2: *reinterpret_cast<double*>(_v) = _t->apparentFOV(); break;
        case 3: *reinterpret_cast<double*>(_v) = _t->effectiveFocalLength(); break;
        case 4: *reinterpret_cast<double*>(_v) = _t->fieldStop(); break;
        case 5: *reinterpret_cast<QString*>(_v) = _t->name(); break;
        case 6: *reinterpret_cast<QString*>(_v) = _t->reticlePath(); break;
        default: break;
        }
    }
    if (_c == QMetaObject::WriteProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: _t->setBinoculars(*reinterpret_cast<bool*>(_v)); break;
        case 1: _t->setPermanentCrosshair(*reinterpret_cast<bool*>(_v)); break;
        case 2: _t->setApparentFOV(*reinterpret_cast<double*>(_v)); break;
        case 3: _t->setEffectiveFocalLength(*reinterpret_cast<double*>(_v)); break;
        case 4: _t->setFieldStop(*reinterpret_cast<double*>(_v)); break;
        case 5: _t->setName(*reinterpret_cast<QString*>(_v)); break;
        case 6: _t->setReticlePath(*reinterpret_cast<QString*>(_v)); break;
        default: break;
        }
    }
}

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

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

int Ocular::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QObject::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::ReadProperty || _c == QMetaObject::WriteProperty
            || _c == QMetaObject::ResetProperty || _c == QMetaObject::BindableProperty
            || _c == QMetaObject::RegisterPropertyMetaType) {
        qt_static_metacall(this, _c, _id, _a);
        _id -= 7;
    }
    return _id;
}
QT_WARNING_POP
