diff options
Diffstat (limited to 'examples/qml/referenceexamples/properties/birthdayparty.cpp')
-rw-r--r-- | examples/qml/referenceexamples/properties/birthdayparty.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/examples/qml/referenceexamples/properties/birthdayparty.cpp b/examples/qml/referenceexamples/properties/birthdayparty.cpp index fe6abab3f5..2dc9bd803d 100644 --- a/examples/qml/referenceexamples/properties/birthdayparty.cpp +++ b/examples/qml/referenceexamples/properties/birthdayparty.cpp @@ -81,12 +81,12 @@ void BirthdayParty::appendGuest(Person* p) { } -int BirthdayParty::guestCount() const +qsizetype BirthdayParty::guestCount() const { return m_guests.count(); } -Person *BirthdayParty::guest(int index) const +Person *BirthdayParty::guest(qsizetype index) const { return m_guests.at(index); } @@ -95,7 +95,7 @@ void BirthdayParty::clearGuests() { m_guests.clear(); } -void BirthdayParty::replaceGuest(int index, Person *p) +void BirthdayParty::replaceGuest(qsizetype index, Person *p) { m_guests[index] = p; } @@ -115,7 +115,7 @@ void BirthdayParty::clearGuests(QQmlListProperty<Person>* list) { reinterpret_cast< BirthdayParty* >(list->data)->clearGuests(); } -void BirthdayParty::replaceGuest(QQmlListProperty<Person> *list, int i, Person *p) +void BirthdayParty::replaceGuest(QQmlListProperty<Person> *list, qsizetype i, Person *p) { reinterpret_cast< BirthdayParty* >(list->data)->replaceGuest(i, p); } @@ -125,10 +125,10 @@ void BirthdayParty::removeLastGuest(QQmlListProperty<Person> *list) reinterpret_cast< BirthdayParty* >(list->data)->removeLastGuest(); } -Person* BirthdayParty::guest(QQmlListProperty<Person>* list, int i) { +Person* BirthdayParty::guest(QQmlListProperty<Person>* list, qsizetype i) { return reinterpret_cast< BirthdayParty* >(list->data)->guest(i); } -int BirthdayParty::guestCount(QQmlListProperty<Person>* list) { +qsizetype BirthdayParty::guestCount(QQmlListProperty<Person>* list) { return reinterpret_cast< BirthdayParty* >(list->data)->guestCount(); } |