[Libreoffice-commits] core.git: comphelper/source

Kohei Yoshida kohei.yoshida at collabora.com
Thu Jul 10 17:10:05 PDT 2014


 comphelper/source/container/embeddedobjectcontainer.cxx |   27 +---------------
 1 file changed, 2 insertions(+), 25 deletions(-)

New commits:
commit d5dd1216804afae35d7fe7dbb1d37b0ca1fcce88
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date:   Thu Jul 10 20:09:15 2014 -0400

    Use OUStringHash here.
    
    Change-Id: I37625fb421e5b20f299fccccbc9d5ac74c31de3c

diff --git a/comphelper/source/container/embeddedobjectcontainer.cxx b/comphelper/source/container/embeddedobjectcontainer.cxx
index 9286ec8..d614c1a 100644
--- a/comphelper/source/container/embeddedobjectcontainer.cxx
+++ b/comphelper/source/container/embeddedobjectcontainer.cxx
@@ -47,32 +47,9 @@
 
 using namespace ::com::sun::star;
 
-namespace comphelper
-{
-
-struct hashObjectName_Impl
-{
-    size_t operator()(const OUString & Str) const
-    {
-        return (size_t)Str.hashCode();
-    }
-};
-
-struct eqObjectName_Impl
-{
-    bool operator()(const OUString & Str1, const OUString & Str2) const
-    {
-        return ( Str1 == Str2 );
-    }
-};
+namespace comphelper {
 
-typedef boost::unordered_map
-<
-    OUString,
-    ::com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject >,
-    hashObjectName_Impl,
-    eqObjectName_Impl
->
+typedef boost::unordered_map<OUString, uno::Reference <embed::XEmbeddedObject>, OUStringHash>
 EmbeddedObjectContainerNameMap;
 
 struct EmbedImpl


More information about the Libreoffice-commits mailing list