summaryrefslogtreecommitdiff
path: root/unotools
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-10-19 17:18:17 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-10-23 08:15:35 +0200
commit87a9979c8938b800aab6e35903d60d24892e7f2e (patch)
tree6beb01f22537e63df24c023ab65d391a7bee0cf6 /unotools
parentd76c4e5c9aaf8bd27ec97679bcaeba5b18aca493 (diff)
overload std::hash for OUString and OString
no need to explicitly specify it anymore Change-Id: I6ad9259cce77201fdd75152533f5151aae83e9ec Reviewed-on: https://gerrit.libreoffice.org/43567 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'unotools')
-rw-r--r--unotools/source/config/cmdoptions.cxx2
-rw-r--r--unotools/source/config/eventcfg.cxx2
-rw-r--r--unotools/source/config/extendedsecurityoptions.cxx2
-rw-r--r--unotools/source/config/fontcfg.cxx6
-rw-r--r--unotools/source/config/optionsdlg.cxx2
-rw-r--r--unotools/source/config/pathoptions.cxx2
-rw-r--r--unotools/source/i18n/resmgr.cxx2
-rw-r--r--unotools/source/misc/fontdefs.cxx2
8 files changed, 10 insertions, 10 deletions
diff --git a/unotools/source/config/cmdoptions.cxx b/unotools/source/config/cmdoptions.cxx
index 5f1eac638403..e7cebb526beb 100644
--- a/unotools/source/config/cmdoptions.cxx
+++ b/unotools/source/config/cmdoptions.cxx
@@ -78,7 +78,7 @@ class SvtCmdOptions
}
private:
- typedef std::unordered_map<OUString, sal_Int32, OUStringHash>
+ typedef std::unordered_map<OUString, sal_Int32>
CommandHashMap;
CommandHashMap m_aCommandHashMap;
diff --git a/unotools/source/config/eventcfg.cxx b/unotools/source/config/eventcfg.cxx
index 2f2f57956a5e..2a8dc2034822 100644
--- a/unotools/source/config/eventcfg.cxx
+++ b/unotools/source/config/eventcfg.cxx
@@ -76,7 +76,7 @@ static o3tl::enumarray<GlobalEventId, const char*> pEventAsciiNames =
"OnStorageChanged"
};
-typedef std::unordered_map< OUString, OUString, OUStringHash > EventBindingHash;
+typedef std::unordered_map< OUString, OUString > EventBindingHash;
typedef std::vector< css::uno::WeakReference< css::frame::XFrame > > FrameVector;
typedef o3tl::enumarray< GlobalEventId, OUString > SupportedEventsVector;
diff --git a/unotools/source/config/extendedsecurityoptions.cxx b/unotools/source/config/extendedsecurityoptions.cxx
index 7a9630595189..46841d3dad01 100644
--- a/unotools/source/config/extendedsecurityoptions.cxx
+++ b/unotools/source/config/extendedsecurityoptions.cxx
@@ -50,7 +50,7 @@ using namespace ::com::sun::star::uno;
#define PROPERTYCOUNT 1
-typedef std::unordered_map<OUString, sal_Int32, OUStringHash>
+typedef std::unordered_map<OUString, sal_Int32>
ExtensionHashMap;
class SvtExtendedSecurityOptions_Impl : public ConfigItem
diff --git a/unotools/source/config/fontcfg.cxx b/unotools/source/config/fontcfg.cxx
index e09a03f058a2..91aa70272eff 100644
--- a/unotools/source/config/fontcfg.cxx
+++ b/unotools/source/config/fontcfg.cxx
@@ -151,7 +151,7 @@ OUString DefaultFontConfiguration::tryLocale( const OUString& rBcp47, const OUSt
{
OUString aRet;
- std::unordered_map< OUString, LocaleAccess, OUStringHash >::const_iterator it = m_aConfig.find( rBcp47 );
+ std::unordered_map< OUString, LocaleAccess >::const_iterator it = m_aConfig.find( rBcp47 );
if( it != m_aConfig.end() )
{
if( !it->second.xAccess.is() )
@@ -992,7 +992,7 @@ ImplFontAttrs FontSubstConfiguration::getSubstType( const css::uno::Reference< X
void FontSubstConfiguration::readLocaleSubst( const OUString& rBcp47 ) const
{
- std::unordered_map< OUString, LocaleSubst, OUStringHash >::const_iterator it = m_aSubst.find( rBcp47 );
+ std::unordered_map< OUString, LocaleSubst >::const_iterator it = m_aSubst.find( rBcp47 );
if( it != m_aSubst.end() )
{
if( ! it->second.bConfigRead )
@@ -1088,7 +1088,7 @@ const FontNameAttr* FontSubstConfiguration::getSubstInfo( const OUString& rFontN
for (::std::vector< OUString >::const_iterator fb( aFallbacks.begin()); fb != aFallbacks.end(); ++fb)
{
- std::unordered_map< OUString, LocaleSubst, OUStringHash >::const_iterator lang = m_aSubst.find( *fb );
+ std::unordered_map< OUString, LocaleSubst >::const_iterator lang = m_aSubst.find( *fb );
if( lang != m_aSubst.end() )
{
if( ! lang->second.bConfigRead )
diff --git a/unotools/source/config/optionsdlg.cxx b/unotools/source/config/optionsdlg.cxx
index 7da3f2305455..b0a053e1fc93 100644
--- a/unotools/source/config/optionsdlg.cxx
+++ b/unotools/source/config/optionsdlg.cxx
@@ -43,7 +43,7 @@ static sal_Int32 nRefCount = 0;
class SvtOptionsDlgOptions_Impl : public utl::ConfigItem
{
private:
- typedef std::unordered_map< OUString, sal_Bool, OUStringHash > OptionNodeList;
+ typedef std::unordered_map< OUString, sal_Bool > OptionNodeList;
OUString m_sPathDelimiter;
OptionNodeList m_aOptionNodeList;
diff --git a/unotools/source/config/pathoptions.cxx b/unotools/source/config/pathoptions.cxx
index 634fa2639015..09d1df3beb86 100644
--- a/unotools/source/config/pathoptions.cxx
+++ b/unotools/source/config/pathoptions.cxx
@@ -70,7 +70,7 @@ using namespace com::sun::star::lang;
#define STRPOS_NOTFOUND -1
-typedef std::unordered_map<OUString, sal_Int32, OUStringHash> NameToHandleMap;
+typedef std::unordered_map<OUString, sal_Int32> NameToHandleMap;
typedef std::set<OUString> VarNameSet;
diff --git a/unotools/source/i18n/resmgr.cxx b/unotools/source/i18n/resmgr.cxx
index 492c7fcf8632..a0ad625f7aff 100644
--- a/unotools/source/i18n/resmgr.cxx
+++ b/unotools/source/i18n/resmgr.cxx
@@ -91,7 +91,7 @@ namespace Translate
{
std::locale Create(const sal_Char* pPrefixName, const LanguageTag& rLocale)
{
- static std::unordered_map<OString, std::locale, OStringHash> aCache;
+ static std::unordered_map<OString, std::locale> aCache;
OString sIdentifier = rLocale.getGlibcLocaleString(".UTF-8").toUtf8();
OString sUnique = sIdentifier + OString(pPrefixName);
auto aFind = aCache.find(sUnique);
diff --git a/unotools/source/misc/fontdefs.cxx b/unotools/source/misc/fontdefs.cxx
index 8a625388d56e..67f4d73a3fc3 100644
--- a/unotools/source/misc/fontdefs.cxx
+++ b/unotools/source/misc/fontdefs.cxx
@@ -419,7 +419,7 @@ OUString GetEnglishSearchFontName(const OUString& rInName)
// translate normalized localized name to its normalized English ASCII name
if( bNeedTranslation )
{
- typedef std::unordered_map<OUString, const char*, OUStringHash> FontNameDictionary;
+ typedef std::unordered_map<OUString, const char*> FontNameDictionary;
static FontNameDictionary aDictionary( SAL_N_ELEMENTS(aImplLocalizedNamesList) );
// the font name dictionary needs to be initialized once
if( aDictionary.empty() )