[Libreoffice-commits] core.git: 2 commits - accessibility/inc accessibility/source framework/source
Caolán McNamara
caolanm at redhat.com
Tue Feb 4 06:58:04 PST 2014
accessibility/inc/accessibility/extended/accessiblelistbox.hxx | 2
accessibility/source/helper/acc_factory.cxx | 4
framework/source/services/substitutepathvars.cxx | 313 ++++------
3 files changed, 147 insertions(+), 172 deletions(-)
New commits:
commit 0be44f7d15009bffd6c03cc3ad81fa54aace40e6
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Feb 4 14:57:16 2014 +0000
fix ambiguities
Change-Id: Ice46cfbe8a21c5e641e09070128b8f412411c9d9
diff --git a/accessibility/inc/accessibility/extended/accessiblelistbox.hxx b/accessibility/inc/accessibility/extended/accessiblelistbox.hxx
index 58d22a5..78a1765 100644
--- a/accessibility/inc/accessibility/extended/accessiblelistbox.hxx
+++ b/accessibility/inc/accessibility/extended/accessiblelistbox.hxx
@@ -121,7 +121,7 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > m_xFocusedChild;
- accessibility::AccessibleListBoxEntry* GetCurEventEntry( const VclWindowEvent& rVclWindowEvent );
+ ::accessibility::AccessibleListBoxEntry* GetCurEventEntry( const VclWindowEvent& rVclWindowEvent );
};
diff --git a/accessibility/source/helper/acc_factory.cxx b/accessibility/source/helper/acc_factory.cxx
index 640c2d5..4ebbbb4 100644
--- a/accessibility/source/helper/acc_factory.cxx
+++ b/accessibility/source/helper/acc_factory.cxx
@@ -398,11 +398,11 @@ inline bool hasFloatingChild(Window *pWindow)
}
else if ( ( nType == WINDOW_HELPTEXTWINDOW ) || ( nType == WINDOW_FIXEDLINE ) )
{
- xContext = (accessibility::XAccessibleContext*) new VCLXAccessibleFixedText( _pXWindow );
+ xContext = (::accessibility::XAccessibleContext*) new VCLXAccessibleFixedText( _pXWindow );
}
else
{
- xContext = (accessibility::XAccessibleContext*) new VCLXAccessibleComponent( _pXWindow );
+ xContext = (::accessibility::XAccessibleContext*) new VCLXAccessibleComponent( _pXWindow );
}
}
commit e1b606e0718928f648aae3cf46f2c780eb0a9277
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Feb 4 14:50:53 2014 +0000
nPrio is always 0
Change-Id: Idc5bd213562de95c83752dc089ff6a928e9085d3
diff --git a/framework/source/services/substitutepathvars.cxx b/framework/source/services/substitutepathvars.cxx
index ccf31ab..517aed8 100644
--- a/framework/source/services/substitutepathvars.cxx
+++ b/framework/source/services/substitutepathvars.cxx
@@ -1264,180 +1264,155 @@ throw ( NoSuchElementException, RuntimeException )
}
namespace {
-const char* GetLang( LanguageType& nType, sal_uInt16 nPrio )
+const char* GetLang(LanguageType& nType)
{
if ( nType == LANGUAGE_SYSTEM || nType == LANGUAGE_DONTKNOW )
nType = MsLangId::getSystemUILanguage();
- if ( nPrio == 0 )
+ switch ( nType )
{
- switch ( nType )
- {
- case LANGUAGE_DANISH:
- return "45";
-
- case LANGUAGE_DUTCH:
- case LANGUAGE_DUTCH_BELGIAN:
- return "31";
-
- case LANGUAGE_ENGLISH:
- case LANGUAGE_ENGLISH_UK:
- case LANGUAGE_ENGLISH_EIRE:
- case LANGUAGE_ENGLISH_SAFRICA:
- case LANGUAGE_ENGLISH_JAMAICA:
- case LANGUAGE_ENGLISH_BELIZE:
- case LANGUAGE_ENGLISH_TRINIDAD:
- case LANGUAGE_ENGLISH_ZIMBABWE:
- case LANGUAGE_ENGLISH_PHILIPPINES:
- return "44";
-
- case LANGUAGE_ENGLISH_US:
- case LANGUAGE_ENGLISH_CAN:
- return "01";
-
- case LANGUAGE_ENGLISH_AUS:
- case LANGUAGE_ENGLISH_NZ:
- return "61";
- case LANGUAGE_ESTONIAN:
- return "77";
-
-
- case LANGUAGE_FINNISH:
- return "35";
-
- case LANGUAGE_FRENCH_CANADIAN:
- return "02";
-
- case LANGUAGE_FRENCH:
- case LANGUAGE_FRENCH_BELGIAN:
- case LANGUAGE_FRENCH_SWISS:
- case LANGUAGE_FRENCH_LUXEMBOURG:
- case LANGUAGE_FRENCH_MONACO:
- return "33";
-
- case LANGUAGE_GERMAN:
- case LANGUAGE_GERMAN_SWISS:
- case LANGUAGE_GERMAN_AUSTRIAN:
- case LANGUAGE_GERMAN_LUXEMBOURG:
- case LANGUAGE_GERMAN_LIECHTENSTEIN:
- return "49";
-
- case LANGUAGE_ITALIAN:
- case LANGUAGE_ITALIAN_SWISS:
- return "39";
-
- case LANGUAGE_NORWEGIAN:
- case LANGUAGE_NORWEGIAN_BOKMAL:
- return "47";
-
- case LANGUAGE_PORTUGUESE:
- return "03";
-
- case LANGUAGE_PORTUGUESE_BRAZILIAN:
- return "55";
-
- case LANGUAGE_SPANISH_DATED:
- case LANGUAGE_SPANISH_MEXICAN:
- case LANGUAGE_SPANISH_MODERN:
- case LANGUAGE_SPANISH_GUATEMALA:
- case LANGUAGE_SPANISH_COSTARICA:
- case LANGUAGE_SPANISH_PANAMA:
- case LANGUAGE_SPANISH_DOMINICAN_REPUBLIC:
- case LANGUAGE_SPANISH_VENEZUELA:
- case LANGUAGE_SPANISH_COLOMBIA:
- case LANGUAGE_SPANISH_PERU:
- case LANGUAGE_SPANISH_ARGENTINA:
- case LANGUAGE_SPANISH_ECUADOR:
- case LANGUAGE_SPANISH_CHILE:
- case LANGUAGE_SPANISH_URUGUAY:
- case LANGUAGE_SPANISH_PARAGUAY:
- case LANGUAGE_SPANISH_BOLIVIA:
- return "34";
-
- case LANGUAGE_SWEDISH:
- return "46";
-
- case LANGUAGE_POLISH:
- return "48";
- case LANGUAGE_CZECH:
- return "42";
- case LANGUAGE_SLOVENIAN:
- return "50";
- case LANGUAGE_HUNGARIAN:
- return "36";
- case LANGUAGE_RUSSIAN:
- return "07";
- case LANGUAGE_SLOVAK:
- return "43";
- case LANGUAGE_GREEK:
- return "30";
- case LANGUAGE_TURKISH:
- return "90";
-
- case LANGUAGE_CHINESE_SIMPLIFIED:
- return "86";
- case LANGUAGE_CHINESE_TRADITIONAL:
- return "88";
- case LANGUAGE_JAPANESE:
- return "81";
- case LANGUAGE_KOREAN:
- case LANGUAGE_KOREAN_JOHAB:
- return "82";
- case LANGUAGE_THAI:
- return "66";
- case LANGUAGE_HINDI:
- return "91";
-
- case LANGUAGE_ARABIC_PRIMARY_ONLY:
- case LANGUAGE_ARABIC_IRAQ:
- case LANGUAGE_ARABIC_EGYPT:
- case LANGUAGE_ARABIC_LIBYA:
- case LANGUAGE_ARABIC_ALGERIA:
- case LANGUAGE_ARABIC_MOROCCO:
- case LANGUAGE_ARABIC_TUNISIA:
- case LANGUAGE_ARABIC_OMAN:
- case LANGUAGE_ARABIC_YEMEN:
- case LANGUAGE_ARABIC_SYRIA:
- case LANGUAGE_ARABIC_JORDAN:
- case LANGUAGE_ARABIC_LEBANON:
- case LANGUAGE_ARABIC_KUWAIT:
- case LANGUAGE_ARABIC_UAE:
- case LANGUAGE_ARABIC_BAHRAIN:
- case LANGUAGE_ARABIC_QATAR:
- return "96";
-
- case LANGUAGE_HEBREW:
- return "97";
-
- case LANGUAGE_CATALAN:
- return "37";
-
- default:
- return "99";
- }
+ case LANGUAGE_DANISH:
+ return "45";
+
+ case LANGUAGE_DUTCH:
+ case LANGUAGE_DUTCH_BELGIAN:
+ return "31";
+
+ case LANGUAGE_ENGLISH:
+ case LANGUAGE_ENGLISH_UK:
+ case LANGUAGE_ENGLISH_EIRE:
+ case LANGUAGE_ENGLISH_SAFRICA:
+ case LANGUAGE_ENGLISH_JAMAICA:
+ case LANGUAGE_ENGLISH_BELIZE:
+ case LANGUAGE_ENGLISH_TRINIDAD:
+ case LANGUAGE_ENGLISH_ZIMBABWE:
+ case LANGUAGE_ENGLISH_PHILIPPINES:
+ return "44";
+
+ case LANGUAGE_ENGLISH_US:
+ case LANGUAGE_ENGLISH_CAN:
+ return "01";
+
+ case LANGUAGE_ENGLISH_AUS:
+ case LANGUAGE_ENGLISH_NZ:
+ return "61";
+ case LANGUAGE_ESTONIAN:
+ return "77";
+
+
+ case LANGUAGE_FINNISH:
+ return "35";
+
+ case LANGUAGE_FRENCH_CANADIAN:
+ return "02";
+
+ case LANGUAGE_FRENCH:
+ case LANGUAGE_FRENCH_BELGIAN:
+ case LANGUAGE_FRENCH_SWISS:
+ case LANGUAGE_FRENCH_LUXEMBOURG:
+ case LANGUAGE_FRENCH_MONACO:
+ return "33";
+
+ case LANGUAGE_GERMAN:
+ case LANGUAGE_GERMAN_SWISS:
+ case LANGUAGE_GERMAN_AUSTRIAN:
+ case LANGUAGE_GERMAN_LUXEMBOURG:
+ case LANGUAGE_GERMAN_LIECHTENSTEIN:
+ return "49";
+
+ case LANGUAGE_ITALIAN:
+ case LANGUAGE_ITALIAN_SWISS:
+ return "39";
+
+ case LANGUAGE_NORWEGIAN:
+ case LANGUAGE_NORWEGIAN_BOKMAL:
+ return "47";
+
+ case LANGUAGE_PORTUGUESE:
+ return "03";
+
+ case LANGUAGE_PORTUGUESE_BRAZILIAN:
+ return "55";
+
+ case LANGUAGE_SPANISH_DATED:
+ case LANGUAGE_SPANISH_MEXICAN:
+ case LANGUAGE_SPANISH_MODERN:
+ case LANGUAGE_SPANISH_GUATEMALA:
+ case LANGUAGE_SPANISH_COSTARICA:
+ case LANGUAGE_SPANISH_PANAMA:
+ case LANGUAGE_SPANISH_DOMINICAN_REPUBLIC:
+ case LANGUAGE_SPANISH_VENEZUELA:
+ case LANGUAGE_SPANISH_COLOMBIA:
+ case LANGUAGE_SPANISH_PERU:
+ case LANGUAGE_SPANISH_ARGENTINA:
+ case LANGUAGE_SPANISH_ECUADOR:
+ case LANGUAGE_SPANISH_CHILE:
+ case LANGUAGE_SPANISH_URUGUAY:
+ case LANGUAGE_SPANISH_PARAGUAY:
+ case LANGUAGE_SPANISH_BOLIVIA:
+ return "34";
+
+ case LANGUAGE_SWEDISH:
+ return "46";
+
+ case LANGUAGE_POLISH:
+ return "48";
+ case LANGUAGE_CZECH:
+ return "42";
+ case LANGUAGE_SLOVENIAN:
+ return "50";
+ case LANGUAGE_HUNGARIAN:
+ return "36";
+ case LANGUAGE_RUSSIAN:
+ return "07";
+ case LANGUAGE_SLOVAK:
+ return "43";
+ case LANGUAGE_GREEK:
+ return "30";
+ case LANGUAGE_TURKISH:
+ return "90";
+
+ case LANGUAGE_CHINESE_SIMPLIFIED:
+ return "86";
+ case LANGUAGE_CHINESE_TRADITIONAL:
+ return "88";
+ case LANGUAGE_JAPANESE:
+ return "81";
+ case LANGUAGE_KOREAN:
+ case LANGUAGE_KOREAN_JOHAB:
+ return "82";
+ case LANGUAGE_THAI:
+ return "66";
+ case LANGUAGE_HINDI:
+ return "91";
+
+ case LANGUAGE_ARABIC_PRIMARY_ONLY:
+ case LANGUAGE_ARABIC_IRAQ:
+ case LANGUAGE_ARABIC_EGYPT:
+ case LANGUAGE_ARABIC_LIBYA:
+ case LANGUAGE_ARABIC_ALGERIA:
+ case LANGUAGE_ARABIC_MOROCCO:
+ case LANGUAGE_ARABIC_TUNISIA:
+ case LANGUAGE_ARABIC_OMAN:
+ case LANGUAGE_ARABIC_YEMEN:
+ case LANGUAGE_ARABIC_SYRIA:
+ case LANGUAGE_ARABIC_JORDAN:
+ case LANGUAGE_ARABIC_LEBANON:
+ case LANGUAGE_ARABIC_KUWAIT:
+ case LANGUAGE_ARABIC_UAE:
+ case LANGUAGE_ARABIC_BAHRAIN:
+ case LANGUAGE_ARABIC_QATAR:
+ return "96";
+
+ case LANGUAGE_HEBREW:
+ return "97";
+
+ case LANGUAGE_CATALAN:
+ return "37";
+
+ default:
+ return "99";
}
- else if ( nPrio == 1 )
- {
- switch ( nType )
- {
- case LANGUAGE_FRENCH_CANADIAN:
- return "33";
-
- case LANGUAGE_PORTUGUESE_BRAZILIAN:
- return "03";
-
- default:
- return NULL;
- }
- }
- else if ( nPrio == 2 )
- return "01";
- else if ( nPrio == 3 )
- return "44";
- else if ( nPrio == 4 )
- return "49";
- else
- return "99";
}
}
@@ -1497,7 +1472,7 @@ void SubstitutePathVariables::SetPredefinedPathVariables( PredefinedPathVariable
// Set $(lang)
aPreDefPathVariables.m_FixedVar[ PREDEFVAR_LANG ] = ConvertOSLtoUCBURL(
- OUString::createFromAscii( GetLang( aPreDefPathVariables.m_eLanguageType, 0 ) ));
+ OUString::createFromAscii( GetLang(aPreDefPathVariables.m_eLanguageType) ));
// Set $(vlang)
aPreDefPathVariables.m_FixedVar[ PREDEFVAR_VLANG ] = aLocaleStr;
More information about the Libreoffice-commits
mailing list