[Libreoffice-commits] .: 2 commits - sd/source slideshow/source

Caolán McNamara caolan at kemper.freedesktop.org
Thu Nov 25 08:06:29 PST 2010


 sd/source/ui/dlg/TemplateScanner.cxx |    8 +++++---
 slideshow/source/engine/tools.cxx    |    4 ++--
 2 files changed, 7 insertions(+), 5 deletions(-)

New commits:
commit acdbff57f1082423629ea7370442bfc473167f13
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Nov 25 11:12:38 2010 +0000

    cppcheck: methods can be const

diff --git a/sd/source/ui/dlg/TemplateScanner.cxx b/sd/source/ui/dlg/TemplateScanner.cxx
index 3443fcf..020abaa 100644
--- a/sd/source/ui/dlg/TemplateScanner.cxx
+++ b/sd/source/ui/dlg/TemplateScanner.cxx
@@ -89,9 +89,11 @@ public:
     //    Reference<sdbc::XResultSet> mxFolderResultSet;
     Reference<com::sun::star::ucb::XCommandEnvironment> mxFolderEnvironment;
 
-    class Comparator { public:
-        bool operator() (const FolderDescriptor& r1, const FolderDescriptor& r2)
-        { return r1.mnPriority < r2.mnPriority; }
+    class Comparator
+    {
+    public:
+        bool operator() (const FolderDescriptor& r1, const FolderDescriptor& r2) const
+            { return r1.mnPriority < r2.mnPriority; }
     };
 };
 
commit fe80d4c55085995989223f5a9adab653fbcfc540
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Nov 25 11:10:48 2010 +0000

    cppcheck: methods can be const

diff --git a/slideshow/source/engine/tools.cxx b/slideshow/source/engine/tools.cxx
index 9a74e41..b5e1ec5 100644
--- a/slideshow/source/engine/tools.cxx
+++ b/slideshow/source/engine/tools.cxx
@@ -77,7 +77,7 @@ namespace slideshow
                 {
                 }
 
-                bool operator()( const beans::NamedValue& rValue )
+                bool operator()( const beans::NamedValue& rValue ) const
                 {
                     return rValue.Name == mrSearchString;
                 }
@@ -94,7 +94,7 @@ namespace slideshow
                 {
                 }
 
-                bool operator()( const beans::NamedValue& rValue )
+                bool operator()( const beans::NamedValue& rValue ) const
                 {
                     return rValue.Name == mrKey.Name && rValue.Value == mrKey.Value;
                 }


More information about the Libreoffice-commits mailing list