summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pdf/api/qpdfdestination.h5
-rw-r--r--src/pdf/api/qpdfselection.h5
-rw-r--r--src/pdf/qpdfdestination.cpp5
-rw-r--r--src/pdf/qpdfselection.cpp11
4 files changed, 22 insertions, 4 deletions
diff --git a/src/pdf/api/qpdfdestination.h b/src/pdf/api/qpdfdestination.h
index 325863226..f9c186ff6 100644
--- a/src/pdf/api/qpdfdestination.h
+++ b/src/pdf/api/qpdfdestination.h
@@ -56,10 +56,11 @@ class Q_PDF_EXPORT QPdfDestination
Q_PROPERTY(qreal zoom READ zoom)
public:
- QPdfDestination(const QPdfDestination &other);
~QPdfDestination();
+ QPdfDestination(const QPdfDestination &other);
QPdfDestination &operator=(const QPdfDestination &other);
- inline QPdfDestination &operator=(QPdfDestination &&other) noexcept { swap(other); return *this; }
+ QPdfDestination(QPdfDestination &&other) noexcept;
+ QPdfDestination &operator=(QPdfDestination &&other) noexcept { swap(other); return *this; }
void swap(QPdfDestination &other) noexcept { d.swap(other.d); }
bool isValid() const;
int page() const;
diff --git a/src/pdf/api/qpdfselection.h b/src/pdf/api/qpdfselection.h
index a5e9280dc..5a6a1cddc 100644
--- a/src/pdf/api/qpdfselection.h
+++ b/src/pdf/api/qpdfselection.h
@@ -56,10 +56,11 @@ class Q_PDF_EXPORT QPdfSelection
Q_PROPERTY(QString text READ text)
public:
- QPdfSelection(const QPdfSelection &other);
~QPdfSelection();
+ QPdfSelection(const QPdfSelection &other);
QPdfSelection &operator=(const QPdfSelection &other);
- inline QPdfSelection &operator=(QPdfSelection &&other) noexcept { swap(other); return *this; }
+ QPdfSelection(QPdfSelection &&other) noexcept;
+ QPdfSelection &operator=(QPdfSelection &&other) noexcept { swap(other); return *this; }
void swap(QPdfSelection &other) noexcept { d.swap(other.d); }
bool isValid() const;
QVector<QPolygonF> bounds() const;
diff --git a/src/pdf/qpdfdestination.cpp b/src/pdf/qpdfdestination.cpp
index b347445e9..b70e031ca 100644
--- a/src/pdf/qpdfdestination.cpp
+++ b/src/pdf/qpdfdestination.cpp
@@ -73,6 +73,11 @@ QPdfDestination::QPdfDestination(const QPdfDestination &other)
{
}
+QPdfDestination::QPdfDestination(QPdfDestination &&other) noexcept
+ : d(std::move(other.d))
+{
+}
+
QPdfDestination::~QPdfDestination()
{
}
diff --git a/src/pdf/qpdfselection.cpp b/src/pdf/qpdfselection.cpp
index 8c3d6fde0..e334f0fb6 100644
--- a/src/pdf/qpdfselection.cpp
+++ b/src/pdf/qpdfselection.cpp
@@ -82,10 +82,21 @@ QPdfSelection::QPdfSelection(const QPdfSelection &other)
{
}
+QPdfSelection::QPdfSelection(QPdfSelection &&other) noexcept
+ : d(std::move(other.d))
+{
+}
+
QPdfSelection::~QPdfSelection()
{
}
+QPdfSelection &QPdfSelection::operator=(const QPdfSelection &other)
+{
+ d = other.d;
+ return *this;
+}
+
/*!
\property QPdfSelection::valid