[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - vcl/source

Tomaž Vajngerl (via logerrit) logerrit at kemper.freedesktop.org
Tue Jun 9 13:34:26 UTC 2020


 vcl/source/graphic/VectorGraphicSearch.cxx |   45 +++++++++++++++++++++++++++++
 1 file changed, 45 insertions(+)

New commits:
commit 8c0776fb005cb99a1f8e289f26173bec9c246585
Author:     Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
AuthorDate: Sun May 31 12:13:59 2020 +0200
Commit:     Tomaž Vajngerl <quikee at gmail.com>
CommitDate: Tue Jun 9 15:33:53 2020 +0200

    vcl: use HAVE_FEATURE_PDFIUM in VectorGraphicSearch impl.
    
    Change-Id: Id6c30e8f1c5bdb0481b0c7d4680554e3e8caa323
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95393
    Tested-by: Jenkins
    Reviewed-by: Tomaž Vajngerl <quikee at gmail.com>
    (cherry picked from commit 67f7a26c047ae2878e3ecd76f83af3941b9079c3)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95935
    Tested-by: Tomaž Vajngerl <quikee at gmail.com>

diff --git a/vcl/source/graphic/VectorGraphicSearch.cxx b/vcl/source/graphic/VectorGraphicSearch.cxx
index 911c19cebd38..a719329b7708 100644
--- a/vcl/source/graphic/VectorGraphicSearch.cxx
+++ b/vcl/source/graphic/VectorGraphicSearch.cxx
@@ -10,6 +10,10 @@
 
 #include <vcl/VectorGraphicSearch.hxx>
 
+#include <config_features.h>
+
+#if HAVE_FEATURE_PDFIUM
+
 #include <vcl/filter/PDFiumLibrary.hxx>
 
 #include <sal/config.h>
@@ -289,4 +293,45 @@ std::vector<basegfx::B2DRectangle> VectorGraphicSearch::getTextRectangles()
     return std::vector<basegfx::B2DRectangle>();
 }
 
+#else // !HAVE_FEATURE_PDFIUM
+
+class VectorGraphicSearch::Implementation
+{
+};
+
+VectorGraphicSearch::VectorGraphicSearch(Graphic const& rGraphic)
+    : maGraphic(rGraphic)
+{
+}
+
+VectorGraphicSearch::~VectorGraphicSearch() {}
+
+bool VectorGraphicSearch::search(OUString const& /*rSearchString*/,
+                                 SearchStartPosition /*eStartPosition*/)
+{
+    return false;
+}
+
+bool VectorGraphicSearch::searchPDF(std::shared_ptr<VectorGraphicData> const& /*rData*/,
+                                    OUString const& /*rSearchString*/,
+                                    SearchStartPosition /*eStartPosition*/)
+{
+    return false;
+}
+
+basegfx::B2DSize VectorGraphicSearch::pageSize() { return basegfx::B2DSize(); }
+
+bool VectorGraphicSearch::next() { return false; }
+
+bool VectorGraphicSearch::previous() { return false; }
+
+int VectorGraphicSearch::index() { return -1; }
+
+std::vector<basegfx::B2DRectangle> VectorGraphicSearch::getTextRectangles()
+{
+    return std::vector<basegfx::B2DRectangle>();
+}
+
+#endif // HAVE_FEATURE_PDFIUM
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */


More information about the Libreoffice-commits mailing list