From 1ee038d05089aea25d3602f3e65592d7dd07b76f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorbj=C3=B8rn=20Lindeijer?= Date: Mon, 21 Sep 2009 18:18:26 +0200 Subject: Fixed compile for example support library --- examples/declarative/support/contact.cpp | 8 +++----- examples/declarative/support/contact.h | 5 ++--- examples/declarative/support/contactmodel.cpp | 5 ++--- 3 files changed, 7 insertions(+), 11 deletions(-) diff --git a/examples/declarative/support/contact.cpp b/examples/declarative/support/contact.cpp index 0821295..9ffeb97 100644 --- a/examples/declarative/support/contact.cpp +++ b/examples/declarative/support/contact.cpp @@ -12,7 +12,6 @@ ****************************************************************************/ #include "contact.h" -#include "qmltypes.h" QML_DEFINE_TYPE(0,0,0,0,Contact,Contact); Contact::Contact() : QObject(0) @@ -26,13 +25,13 @@ Contact::Contact() : QObject(0) m_numbers << new PhoneNumber; m_numbers << new PhoneNumber; m_numbers << new PhoneNumber; - + m_numbers.at(0)->setType(PhoneNumber::HomePhone); m_numbers.at(0)->setNumber("35412451"); m_numbers.at(1)->setType(PhoneNumber::BusinessPhone); m_numbers.at(1)->setNumber("33424994"); - + m_numbers.at(2)->setType(PhoneNumber::MobilePhone); m_numbers.at(2)->setNumber("0424655137"); @@ -52,8 +51,7 @@ Contact::Contact() : QObject(0) void Contact::addNumber(PhoneNumber *newNumber) { - - m_numbers << newNumber; + m_numbers << newNumber; emit numbersChanged(); } diff --git a/examples/declarative/support/contact.h b/examples/declarative/support/contact.h index c403f8b..7b25869 100644 --- a/examples/declarative/support/contact.h +++ b/examples/declarative/support/contact.h @@ -15,8 +15,7 @@ #define CONTACT_H #include -#include - +#include class Address : public QObject { @@ -105,7 +104,7 @@ public: Q_PROPERTY(QList* numbers READ numbers); QList* numbers() { return &m_numbers; } - + void addEmail(QString&); void addAddress(Address*); void addNumber(PhoneNumber*); diff --git a/examples/declarative/support/contactmodel.cpp b/examples/declarative/support/contactmodel.cpp index efe108fb..ff71b9c 100644 --- a/examples/declarative/support/contactmodel.cpp +++ b/examples/declarative/support/contactmodel.cpp @@ -12,7 +12,6 @@ ****************************************************************************/ #include "contactmodel.h" -#include "qmltypes.h" ContactModel::ContactModel(QObject *parent) : QListModelInterface(parent) { @@ -29,7 +28,7 @@ ContactModel::ContactModel(QObject *parent) : QListModelInterface(parent) c->addEmail(list[i]); //contactList.append(c); insertContact(c); - + text = ts.readLine(); } f.close(); @@ -149,7 +148,7 @@ int ContactModel::findIndex(QString &searchName) const else return middle; } return start; -} +} int ContactModel::isAfter(QString &name1, QString &name2) const { -- cgit v0.12