Kaydet (Commit) d1bab2c2 authored tarafından Chr. Rossmanith's avatar Chr. Rossmanith

RTL_CONSTASCII_(U)STRINGPARAM removed in desktop/source/app

removed OUSTRING() as well

Change-Id: Ib074d4729370a921b6b51d50360e4fa92f3d5ddf
üst 55bdbf3d
...@@ -1156,7 +1156,7 @@ void restartOnMac(bool passArguments) { ...@@ -1156,7 +1156,7 @@ void restartOnMac(bool passArguments) {
for (sal_uInt32 i = 0; i < n; ++i) { for (sal_uInt32 i = 0; i < n; ++i) {
rtl::OUString arg; rtl::OUString arg;
OSL_VERIFY(osl_getCommandArg(i, &arg.pData) == osl_Process_E_None); OSL_VERIFY(osl_getCommandArg(i, &arg.pData) == osl_Process_E_None);
if (arg.matchAsciiL(RTL_CONSTASCII_STRINGPARAM("--accept="))) { if (arg.match("--accept=")) {
wait = true; wait = true;
} }
rtl::OString arg8; rtl::OString arg8;
......
...@@ -42,10 +42,6 @@ using uno::UNO_QUERY; ...@@ -42,10 +42,6 @@ using uno::UNO_QUERY;
static char const CONFIG_ERROR_HANDLER[] = "configuration.interaction-handler"; static char const CONFIG_ERROR_HANDLER[] = "configuration.interaction-handler";
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#define OUSTRING( constascii ) OUString( RTL_CONSTASCII_USTRINGPARAM( constascii ) )
#define k_ERRORHANDLER OUSTRING( CONFIGURATION_ERROR_HANDLER )
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// ConfigurationErrorHandler // ConfigurationErrorHandler
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
......
...@@ -112,7 +112,7 @@ bool LanguageSelection::prepareLanguage() ...@@ -112,7 +112,7 @@ bool LanguageSelection::prepareLanguage()
try try
{ {
Reference< XPropertySet > xProp(getConfigAccess("org.openoffice.System/L10N/", sal_False), UNO_QUERY_THROW); Reference< XPropertySet > xProp(getConfigAccess("org.openoffice.System/L10N/", sal_False), UNO_QUERY_THROW);
Any aWin16SysLocale = xProp->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("SystemLocale"))); Any aWin16SysLocale = xProp->getPropertyValue("SystemLocale");
::rtl::OUString sWin16SysLocale; ::rtl::OUString sWin16SysLocale;
aWin16SysLocale >>= sWin16SysLocale; aWin16SysLocale >>= sWin16SysLocale;
if( !sWin16SysLocale.isEmpty()) if( !sWin16SysLocale.isEmpty())
...@@ -129,7 +129,7 @@ bool LanguageSelection::prepareLanguage() ...@@ -129,7 +129,7 @@ bool LanguageSelection::prepareLanguage()
OUString usLocale; OUString usLocale;
Reference< XPropertySet > xLocaleProp(getConfigAccess( Reference< XPropertySet > xLocaleProp(getConfigAccess(
"org.openoffice.System/L10N", sal_True), UNO_QUERY_THROW); "org.openoffice.System/L10N", sal_True), UNO_QUERY_THROW);
xLocaleProp->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("Locale"))) >>= usLocale; xLocaleProp->getPropertyValue("Locale") >>= usLocale;
setDefaultLanguage(usLocale); setDefaultLanguage(usLocale);
} }
catch (const Exception&) catch (const Exception&)
...@@ -193,7 +193,7 @@ bool LanguageSelection::prepareLanguage() ...@@ -193,7 +193,7 @@ bool LanguageSelection::prepareLanguage()
if ( !bCmdLanguage ) if ( !bCmdLanguage )
{ {
// Store language only // Store language only
xProp->setPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("ooLocale")), makeAny(aLocaleString)); xProp->setPropertyValue("ooLocale", makeAny(aLocaleString));
Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges(); Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges();
} }
...@@ -201,14 +201,14 @@ bool LanguageSelection::prepareLanguage() ...@@ -201,14 +201,14 @@ bool LanguageSelection::prepareLanguage()
{ {
// Store language only // Store language only
Reference< XPropertySet > xProp2(getConfigAccess("org.openoffice.Office.Linguistic/General/", sal_True), UNO_QUERY_THROW); Reference< XPropertySet > xProp2(getConfigAccess("org.openoffice.Office.Linguistic/General/", sal_True), UNO_QUERY_THROW);
xProp2->setPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("UILocale")), makeAny(aLocaleString)); xProp2->setPropertyValue("UILocale", makeAny(aLocaleString));
Reference< XChangesBatch >(xProp2, UNO_QUERY_THROW)->commitChanges(); Reference< XChangesBatch >(xProp2, UNO_QUERY_THROW)->commitChanges();
} }
MsLangId::setConfiguredSystemUILanguage( aUILanguageTag.getLanguageType( false) ); MsLangId::setConfiguredSystemUILanguage( aUILanguageTag.getLanguageType( false) );
OUString sLocale; OUString sLocale;
xProp->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("ooSetupSystemLocale"))) >>= sLocale; xProp->getPropertyValue("ooSetupSystemLocale") >>= sLocale;
if ( !sLocale.isEmpty() ) if ( !sLocale.isEmpty() )
{ {
LanguageTag aLocaleLanguageTag(sLocale); LanguageTag aLocaleLanguageTag(sLocale);
...@@ -308,11 +308,11 @@ OUString LanguageSelection::getLanguageString() ...@@ -308,11 +308,11 @@ OUString LanguageSelection::getLanguageString()
} }
} }
// fallback 1: en-US // fallback 1: en-US
OUString usFB(RTL_CONSTASCII_USTRINGPARAM("en-US")); OUString usFB("en-US");
if (isInstalledLanguage(usFB)) if (isInstalledLanguage(usFB))
{ {
bFoundLanguage = sal_True; bFoundLanguage = sal_True;
aFoundLanguage = OUString(RTL_CONSTASCII_USTRINGPARAM("en-US")); aFoundLanguage = "en-US";
return aFoundLanguage; return aFoundLanguage;
} }
...@@ -330,9 +330,9 @@ Reference< XNameAccess > LanguageSelection::getConfigAccess(const sal_Char* pPat ...@@ -330,9 +330,9 @@ Reference< XNameAccess > LanguageSelection::getConfigAccess(const sal_Char* pPat
try{ try{
OUString sAccessSrvc; OUString sAccessSrvc;
if (bUpdate) if (bUpdate)
sAccessSrvc = OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationUpdateAccess")); sAccessSrvc = "com.sun.star.configuration.ConfigurationUpdateAccess";
else else
sAccessSrvc = OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationAccess")); sAccessSrvc = "com.sun.star.configuration.ConfigurationAccess";
OUString sConfigURL = OUString::createFromAscii(pPath); OUString sConfigURL = OUString::createFromAscii(pPath);
...@@ -371,7 +371,7 @@ static Sequence< OUString > _getFallbackLocales(const OUString& aIsoLang) ...@@ -371,7 +371,7 @@ static Sequence< OUString > _getFallbackLocales(const OUString& aIsoLang)
Sequence< OUString > seqFallbacks; Sequence< OUString > seqFallbacks;
if ( aIsoLang == "zh-HK" ) { if ( aIsoLang == "zh-HK" ) {
seqFallbacks = Sequence< OUString >(1); seqFallbacks = Sequence< OUString >(1);
seqFallbacks[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("zh-TW")); seqFallbacks[0] = "zh-TW";
} }
return seqFallbacks; return seqFallbacks;
} }
...@@ -442,7 +442,7 @@ OUString LanguageSelection::getUserLanguage() ...@@ -442,7 +442,7 @@ OUString LanguageSelection::getUserLanguage()
{ {
try try
{ {
xAccess->getByName(OUString(RTL_CONSTASCII_USTRINGPARAM("UILocale"))) >>= aUserLanguage; xAccess->getByName("UILocale") >>= aUserLanguage;
} }
catch ( NoSuchElementException const & ) catch ( NoSuchElementException const & )
{ {
...@@ -466,7 +466,7 @@ OUString LanguageSelection::getSystemLanguage() ...@@ -466,7 +466,7 @@ OUString LanguageSelection::getSystemLanguage()
{ {
try try
{ {
xAccess->getByName(OUString(RTL_CONSTASCII_USTRINGPARAM("UILocale"))) >>= aUserLanguage; xAccess->getByName("UILocale") >>= aUserLanguage;
} }
catch ( NoSuchElementException const & ) catch ( NoSuchElementException const & )
{ {
...@@ -488,7 +488,7 @@ void LanguageSelection::resetUserLanguage() ...@@ -488,7 +488,7 @@ void LanguageSelection::resetUserLanguage()
try try
{ {
Reference< XPropertySet > xProp(getConfigAccess("org.openoffice.Office.Linguistic/General", sal_True), UNO_QUERY_THROW); Reference< XPropertySet > xProp(getConfigAccess("org.openoffice.Office.Linguistic/General", sal_True), UNO_QUERY_THROW);
xProp->setPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("UILocale")), makeAny(OUString())); xProp->setPropertyValue("UILocale", makeAny(OUString()));
Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges(); Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges();
} }
catch ( const PropertyVetoException& ) catch ( const PropertyVetoException& )
......
...@@ -547,8 +547,7 @@ OfficeIPCThread::Status OfficeIPCThread::EnableOfficeIPCThread() ...@@ -547,8 +547,7 @@ OfficeIPCThread::Status OfficeIPCThread::EnableOfficeIPCThread()
// Seems another office is running. Pipe arguments to it and self terminate // Seems another office is running. Pipe arguments to it and self terminate
osl::StreamPipe aStreamPipe(pThread->maPipe.getHandle()); osl::StreamPipe aStreamPipe(pThread->maPipe.getHandle());
rtl::OStringBuffer aArguments(RTL_CONSTASCII_STRINGPARAM( rtl::OStringBuffer aArguments(ARGUMENT_PREFIX);
ARGUMENT_PREFIX));
rtl::OUString cwdUrl; rtl::OUString cwdUrl;
if (!(tools::getProcessWorkingDir(cwdUrl) && if (!(tools::getProcessWorkingDir(cwdUrl) &&
addArgument(aArguments, '1', cwdUrl))) addArgument(aArguments, '1', cwdUrl)))
......
...@@ -37,8 +37,7 @@ extern "C" int DESKTOP_DLLPUBLIC soffice_main() ...@@ -37,8 +37,7 @@ extern "C" int DESKTOP_DLLPUBLIC soffice_main()
{ {
#if defined ANDROID #if defined ANDROID
try { try {
rtl::Bootstrap::setIniFilename( rtl::Bootstrap::setIniFilename("file:///assets/program/lofficerc");
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("file:///assets/program/lofficerc")));
#endif #endif
tools::extendApplicationEnvironment(); tools::extendApplicationEnvironment();
...@@ -46,7 +45,7 @@ extern "C" int DESKTOP_DLLPUBLIC soffice_main() ...@@ -46,7 +45,7 @@ extern "C" int DESKTOP_DLLPUBLIC soffice_main()
desktop::Desktop aDesktop; desktop::Desktop aDesktop;
// This string is used during initialization of the Gtk+ VCL module // This string is used during initialization of the Gtk+ VCL module
aDesktop.SetAppName( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("soffice")) ); aDesktop.SetAppName( OUString("soffice") );
#ifdef UNX #ifdef UNX
// handle --version and --help already here, otherwise they would be handled // handle --version and --help already here, otherwise they would be handled
// after VCL initialization that might fail if $DISPLAY is not set // after VCL initialization that might fail if $DISPLAY is not set
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment