diff options
Diffstat (limited to 'src/pdfquick/qquickpdfsearchmodel.cpp')
-rw-r--r-- | src/pdfquick/qquickpdfsearchmodel.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/pdfquick/qquickpdfsearchmodel.cpp b/src/pdfquick/qquickpdfsearchmodel.cpp index ca33a6dc6..896584ad7 100644 --- a/src/pdfquick/qquickpdfsearchmodel.cpp +++ b/src/pdfquick/qquickpdfsearchmodel.cpp @@ -199,7 +199,7 @@ QList<QPolygonF> QQuickPdfSearchModel::boundingPolygonsOnPage(int page) */ void QQuickPdfSearchModel::setCurrentPage(int currentPage) { - if (m_currentPage == currentPage) + if (m_currentPage == currentPage || !document()) return; const auto pageCount = document()->document()->pageCount(); @@ -270,6 +270,13 @@ QPdfLink QQuickPdfSearchModel::currentResultLink() const The string to search for. */ +/*! + \since 6.8 + \qmlproperty int PdfSearchModel::count + + The number of search results found. +*/ + QT_END_NAMESPACE #include "moc_qquickpdfsearchmodel_p.cpp" |