mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-25 20:48:52 +03:00
Properly register image pack types
This commit is contained in:
parent
b15d889da0
commit
08d5980d40
2 changed files with 9 additions and 2 deletions
|
@ -8,10 +8,14 @@
|
||||||
#include <QQmlEngine>
|
#include <QQmlEngine>
|
||||||
#include <QSharedPointer>
|
#include <QSharedPointer>
|
||||||
|
|
||||||
class SingleImagePackModel;
|
#include "SingleImagePackModel.h"
|
||||||
class ImagePackListModel final : public QAbstractListModel
|
|
||||||
|
class ImagePackListModel : public QAbstractListModel
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
QML_ELEMENT
|
||||||
|
QML_UNCREATABLE("")
|
||||||
|
|
||||||
Q_PROPERTY(bool containsAccountPack READ containsAccountPack CONSTANT)
|
Q_PROPERTY(bool containsAccountPack READ containsAccountPack CONSTANT)
|
||||||
public:
|
public:
|
||||||
enum Roles
|
enum Roles
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
|
|
||||||
#include <QAbstractListModel>
|
#include <QAbstractListModel>
|
||||||
#include <QList>
|
#include <QList>
|
||||||
|
#include <QQmlEngine>
|
||||||
#include <QUrl>
|
#include <QUrl>
|
||||||
|
|
||||||
#include <mtx/events/mscs/image_packs.hpp>
|
#include <mtx/events/mscs/image_packs.hpp>
|
||||||
|
@ -15,6 +16,8 @@
|
||||||
class SingleImagePackModel final : public QAbstractListModel
|
class SingleImagePackModel final : public QAbstractListModel
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
QML_ELEMENT
|
||||||
|
QML_UNCREATABLE("")
|
||||||
|
|
||||||
Q_PROPERTY(QString roomid READ roomid CONSTANT)
|
Q_PROPERTY(QString roomid READ roomid CONSTANT)
|
||||||
Q_PROPERTY(bool fromSpace READ fromSpace CONSTANT)
|
Q_PROPERTY(bool fromSpace READ fromSpace CONSTANT)
|
||||||
|
|
Loading…
Reference in a new issue