diff options
author | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2022-09-14 16:07:30 +0200 |
---|---|---|
committer | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2022-09-19 14:52:24 +0200 |
commit | 29bf63108f954119a0df6c70dd283367777a7e23 (patch) | |
tree | de762e4736f090e94a8102a8bc723bc540031500 /src/location | |
parent | 87eb1a45b83e6044d7d0c83f98f419c8fbd5e007 (diff) | |
download | qtlocation-29bf63108f954119a0df6c70dd283367777a7e23.tar.gz |
Cleanup: de-virtualize QPlaceAttributePrivate
The possibility to override this type in plugins is not used anywhere,
and overcomplicates the code. There isn't even a way to create a
QPlaceAttribute with a reimplementation of the private.
So remove this; if this is really needed for anything, then we can bring
it back later.
Change-Id: I4881583b87b775a4bcaf36bc972248b321e0ef2b
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/location')
-rw-r--r-- | src/location/places/qplaceattribute.cpp | 12 | ||||
-rw-r--r-- | src/location/places/qplaceattribute_p.h | 8 |
2 files changed, 1 insertions, 19 deletions
diff --git a/src/location/places/qplaceattribute.cpp b/src/location/places/qplaceattribute.cpp index 30e053a8..3c4aabda 100644 --- a/src/location/places/qplaceattribute.cpp +++ b/src/location/places/qplaceattribute.cpp @@ -44,18 +44,6 @@ QT_USE_NAMESPACE QT_DEFINE_QSDP_SPECIALIZATION_DTOR(QPlaceAttributePrivate) -template<> QPlaceAttributePrivate *QSharedDataPointer<QPlaceAttributePrivate>::clone() -{ - return d->clone(); -} - -QPlaceAttributePrivate::QPlaceAttributePrivate(const QPlaceAttributePrivate &other) - : QSharedData(other), - label(other.label), - text(other.text) -{ -} - bool QPlaceAttributePrivate::operator== (const QPlaceAttributePrivate &other) const { return label == other.label diff --git a/src/location/places/qplaceattribute_p.h b/src/location/places/qplaceattribute_p.h index b1d576c0..849ef29f 100644 --- a/src/location/places/qplaceattribute_p.h +++ b/src/location/places/qplaceattribute_p.h @@ -61,11 +61,7 @@ QT_BEGIN_NAMESPACE class QPlaceAttributePrivate : public QSharedData { public: - QPlaceAttributePrivate(){} - QPlaceAttributePrivate(const QPlaceAttributePrivate &other); - virtual ~QPlaceAttributePrivate(){} - virtual bool operator== (const QPlaceAttributePrivate &other) const; - virtual QPlaceAttributePrivate *clone() const { return new QPlaceAttributePrivate(*this); } + bool operator== (const QPlaceAttributePrivate &other) const; bool isEmpty() const; @@ -73,8 +69,6 @@ public: QString text; }; -template<> QPlaceAttributePrivate *QSharedDataPointer<QPlaceAttributePrivate>::clone(); - QT_END_NAMESPACE #endif |