diff options
Diffstat (limited to 'examples/declarative/cppextensions/referenceexamples/attached')
4 files changed, 10 insertions, 10 deletions
diff --git a/examples/declarative/cppextensions/referenceexamples/attached/attached.pro b/examples/declarative/cppextensions/referenceexamples/attached/attached.pro index 32f01468..a5f595bc 100644 --- a/examples/declarative/cppextensions/referenceexamples/attached/attached.pro +++ b/examples/declarative/cppextensions/referenceexamples/attached/attached.pro @@ -2,7 +2,7 @@ QT += declarative SOURCES += main.cpp \ person.cpp \ - birthdayparty.cpp + birthdayparty.cpp HEADERS += person.h \ birthdayparty.h RESOURCES += attached.qrc diff --git a/examples/declarative/cppextensions/referenceexamples/attached/birthdayparty.cpp b/examples/declarative/cppextensions/referenceexamples/attached/birthdayparty.cpp index 333bce84..b226a4fb 100644 --- a/examples/declarative/cppextensions/referenceexamples/attached/birthdayparty.cpp +++ b/examples/declarative/cppextensions/referenceexamples/attached/birthdayparty.cpp @@ -69,7 +69,7 @@ void BirthdayParty::setHost(Person *c) m_host = c; } -QDeclarativeListProperty<Person> BirthdayParty::guests() +QDeclarativeListProperty<Person> BirthdayParty::guests() { return QDeclarativeListProperty<Person>(this, m_guests); } diff --git a/examples/declarative/cppextensions/referenceexamples/attached/example.qml b/examples/declarative/cppextensions/referenceexamples/attached/example.qml index 5376d223..12825a77 100644 --- a/examples/declarative/cppextensions/referenceexamples/attached/example.qml +++ b/examples/declarative/cppextensions/referenceexamples/attached/example.qml @@ -47,23 +47,23 @@ BirthdayParty { } // ![1] - Boy { - name: "Leo Hodges" + Boy { + name: "Leo Hodges" shoe { size: 10; color: "black"; brand: "Reebok"; price: 59.95 } BirthdayParty.rsvp: "2009-07-06" } // ![1] - Boy { - name: "Jack Smith" + Boy { + name: "Jack Smith" shoe { size: 8; color: "blue"; brand: "Puma"; price: 19.95 } } - Girl { - name: "Anne Brown" + Girl { + name: "Anne Brown" shoe.size: 7 shoe.color: "red" shoe.brand: "Marc Jacobs" - shoe.price: 699.99 + shoe.price: 699.99 BirthdayParty.rsvp: "2009-07-01" } diff --git a/examples/declarative/cppextensions/referenceexamples/attached/main.cpp b/examples/declarative/cppextensions/referenceexamples/attached/main.cpp index 084b506a..df6ea5c0 100644 --- a/examples/declarative/cppextensions/referenceexamples/attached/main.cpp +++ b/examples/declarative/cppextensions/referenceexamples/attached/main.cpp @@ -71,7 +71,7 @@ int main(int argc, char ** argv) Person *guest = party->guest(ii); QDate rsvpDate; - QObject *attached = + QObject *attached = qmlAttachedPropertiesObject<BirthdayParty>(guest, false); if (attached) rsvpDate = attached->property("rsvp").toDate(); |