diff options
Diffstat (limited to 'examples/declarative/extending/default/birthdayparty.h')
-rw-r--r-- | examples/declarative/extending/default/birthdayparty.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/examples/declarative/extending/default/birthdayparty.h b/examples/declarative/extending/default/birthdayparty.h index c0cb0a4..9741040 100644 --- a/examples/declarative/extending/default/birthdayparty.h +++ b/examples/declarative/extending/default/birthdayparty.h @@ -42,28 +42,28 @@ #define BIRTHDAYPARTY_H #include <QObject> -#include <qdeclarative.h> +#include <QDeclarativeListProperty> #include "person.h" // ![0] class BirthdayParty : public QObject { -Q_OBJECT -Q_PROPERTY(Person *celebrant READ celebrant WRITE setCelebrant) -Q_PROPERTY(QDeclarativeListProperty<Person> guests READ guests) -Q_CLASSINFO("DefaultProperty", "guests") + Q_OBJECT + Q_PROPERTY(Person *host READ host WRITE setHost) + Q_PROPERTY(QDeclarativeListProperty<Person> guests READ guests) + Q_CLASSINFO("DefaultProperty", "guests") public: BirthdayParty(QObject *parent = 0); - Person *celebrant() const; - void setCelebrant(Person *); + Person *host() const; + void setHost(Person *); QDeclarativeListProperty<Person> guests(); int guestCount() const; Person *guest(int) const; private: - Person *m_celebrant; + Person *m_host; QList<Person *> m_guests; }; // ![0] |