File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change 77
88#include < qobjectdefs.h>
99#include " util.h" // For Quotient::Literals::operator""_L1
10+ #include < QtQmlIntegration/qqmlintegration.h>
1011
1112#include < array>
1213
@@ -133,6 +134,16 @@ enum JoinRule : uint16_t {
133134};
134135Q_ENUM_NS (JoinRule)
135136
137+
138+ struct JoinRuleQml
139+ {
140+ Q_GADGET
141+ QML_NAMED_ELEMENT (JoinRule)
142+ QML_UNCREATABLE (" Only for enum values" )
143+ QML_FOREIGN_NAMESPACE (Quotient)
144+ };
145+
146+
136147} // namespace Quotient
137148Q_DECLARE_OPERATORS_FOR_FLAGS (Quotient::MembershipMask)
138149Q_DECLARE_OPERATORS_FOR_FLAGS(Quotient::JoinStates)
Original file line number Diff line number Diff line change @@ -170,7 +170,7 @@ class QUOTIENT_API Room : public QObject {
170170 Q_PROPERTY (QStringList tagNames READ tagNames NOTIFY tagsChanged)
171171 Q_PROPERTY (bool isFavourite READ isFavourite NOTIFY tagsChanged STORED false )
172172 Q_PROPERTY (bool isLowPriority READ isLowPriority NOTIFY tagsChanged STORED false )
173- Q_PROPERTY (JoinRule joinRule READ joinRule WRITE setJoinRule NOTIFY joinRuleChanged)
173+ Q_PROPERTY (Quotient:: JoinRule joinRule READ joinRule WRITE setJoinRule NOTIFY joinRuleChanged)
174174 Q_PROPERTY (QList<QString> allowIds READ allowIds NOTIFY joinRuleChanged)
175175
176176 Q_PROPERTY (GetRoomEventsJob* eventsHistoryJob READ eventsHistoryJob NOTIFY eventsHistoryJobChanged)
You can’t perform that action at this time.
0 commit comments