From bac345908ed99397fd34f6c1da513ce13acaa114 Mon Sep 17 00:00:00 2001 From: Emmanuel Lepage Vallee <emmanuel.lepage@savoirfairelinux.com> Date: Thu, 26 Mar 2015 10:04:18 -0400 Subject: [PATCH] collection: Fix build on OSX (naming collision wiht system headers) Refs #69290 --- src/collectioninterface.h | 3 --- src/fallbackpersoncollection.cpp | 2 +- src/personmodel.cpp | 2 +- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/collectioninterface.h b/src/collectioninterface.h index 838541e6..9d5a4051 100644 --- a/src/collectioninterface.h +++ b/src/collectioninterface.h @@ -231,9 +231,6 @@ private: CollectionInterfacePrivate* d_ptr; }; -//The end user of don't care it is an abstract type -typedef CollectionInterface Collection; - #include <collectioninterface.hpp> #endif diff --git a/src/fallbackpersoncollection.cpp b/src/fallbackpersoncollection.cpp index aea16f92..cd069025 100644 --- a/src/fallbackpersoncollection.cpp +++ b/src/fallbackpersoncollection.cpp @@ -236,7 +236,7 @@ void FallbackPersonCollectionPrivate::loadAsync() QDir d(m_Path); for (const QString& dir : d.entryList(QDir::AllDirs)) { if (dir != QString('.') && dir != "..") { - Collection* col = PersonModel::instance()->addCollection<FallbackPersonCollection,QString,FallbackPersonCollection*>(m_Path+'/'+dir,q_ptr); + CollectionInterface* col = PersonModel::instance()->addCollection<FallbackPersonCollection,QString,FallbackPersonCollection*>(m_Path+'/'+dir,q_ptr); if (ItemModelStateSerializationDelegate::instance()->isChecked(col)) { col->load(); } diff --git a/src/personmodel.cpp b/src/personmodel.cpp index 6e3b5cc9..974969e6 100644 --- a/src/personmodel.cpp +++ b/src/personmodel.cpp @@ -339,7 +339,7 @@ bool PersonModel::addNewPerson(Person* c, CollectionInterface* backend) if (backend) { ret |= backend->editor<Person>()->addNew(c); } - else for (Collection* col :collections(CollectionInterface::SupportedFeatures::ADD)) { + else for (CollectionInterface* col :collections(CollectionInterface::SupportedFeatures::ADD)) { if (col->id() != "trcb") //Do not add to the transitional contact backend ret |= col->editor<Person>()->addNew(c); } -- GitLab