[Libreoffice-commits] core.git: chart2/qa

Stephan Bergmann (via logerrit) logerrit at kemper.freedesktop.org
Thu Sep 23 13:29:58 UTC 2021


 chart2/qa/extras/charttest.hxx |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 14713f91393abe4ec76ad28bdc45eaced943cd72
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Thu Sep 23 14:34:38 2021 +0200
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Thu Sep 23 15:29:24 2021 +0200

    loplugin:stringviewparam
    
    Change-Id: I3fc029e2691026bcd315a807e90290d763146648
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122526
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/chart2/qa/extras/charttest.hxx b/chart2/qa/extras/charttest.hxx
index c1772702afd0..9094ab308afb 100644
--- a/chart2/qa/extras/charttest.hxx
+++ b/chart2/qa/extras/charttest.hxx
@@ -30,6 +30,7 @@
 #include <com/sun/star/frame/XStorable.hpp>
 #include <com/sun/star/packages/zip/ZipFileAccess.hpp>
 
+#include <o3tl/string_view.hxx>
 #include <unotools/tempfile.hxx>
 #include <rtl/math.hxx>
 #include <svx/charthelper.hxx>
@@ -87,12 +88,12 @@ public:
     explicit CheckForChartName( const OUString& rDir ):
         aDir(rDir) {}
 
-    bool operator()(const OUString& rName)
+    bool operator()(std::u16string_view rName)
     {
-        if(!rName.startsWith(aDir))
+        if(!o3tl::starts_with(rName, aDir))
             return false;
 
-        if(!rName.endsWith(".xml"))
+        if(!o3tl::ends_with(rName, u".xml"))
             return false;
 
         return true;


More information about the Libreoffice-commits mailing list