RTL_CONSTASCII_USTRINGPARAM and ::rtl:: removals
Conflicts:
cui/source/options/optgdlg.cxx
cui/source/options/webconninfo.cxx
dbaccess/source/ui/app/AppController.cxx
Change-Id: I2abfad91318e8be8c0f77909cbd76825cdca9b85
Reviewed-on: https://gerrit.libreoffice.org/2350
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx
index 78463c94..fb313b7 100644
--- a/cui/source/customize/acccfg.cxx
+++ b/cui/source/customize/acccfg.cxx
@@ -77,16 +77,16 @@ using namespace com::sun::star;
//-----------------------------------------------
static ::rtl::OUString SERVICE_UICONFIGMGR (RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.UIConfigurationManager" ));
static OUString SERVICE_UICONFIGMGR ("com.sun.star.ui.UIConfigurationManager" );
static ::rtl::OUString MODULEPROP_SHORTNAME (RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryShortName" ));
static ::rtl::OUString MODULEPROP_UINAME (RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryUIName" ));
static ::rtl::OUString CMDPROP_UINAME (RTL_CONSTASCII_USTRINGPARAM("Name" ));
static OUString MODULEPROP_SHORTNAME ("ooSetupFactoryShortName" );
static OUString MODULEPROP_UINAME ("ooSetupFactoryUIName" );
static OUString CMDPROP_UINAME ("Name" );
static ::rtl::OUString FOLDERNAME_UICONFIG (RTL_CONSTASCII_USTRINGPARAM("Configurations2" ));
static OUString FOLDERNAME_UICONFIG ("Configurations2" );
static ::rtl::OUString MEDIATYPE_PROPNAME (RTL_CONSTASCII_USTRINGPARAM("MediaType" ));
static ::rtl::OUString MEDIATYPE_UICONFIG (RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.xml.ui.configuration" ));
static OUString MEDIATYPE_PROPNAME ("MediaType" );
static OUString MEDIATYPE_UICONFIG ("application/vnd.sun.xml.ui.configuration");
//-----------------------------------------------
static sal_uInt16 KEYCODE_ARRAY[] =
@@ -848,8 +848,8 @@ void SfxAcceleratorConfigPage::InitAccCfg()
css::frame::ModuleManager::create(comphelper::getComponentContext(m_xSMGR)));
m_sModuleLongName = xModuleManager->identify(m_xFrame);
::comphelper::SequenceAsHashMap lModuleProps(xModuleManager->getByName(m_sModuleLongName));
m_sModuleShortName = lModuleProps.getUnpackedValueOrDefault(MODULEPROP_SHORTNAME, ::rtl::OUString());
m_sModuleUIName = lModuleProps.getUnpackedValueOrDefault(MODULEPROP_UINAME , ::rtl::OUString());
m_sModuleShortName = lModuleProps.getUnpackedValueOrDefault(MODULEPROP_SHORTNAME, OUString());
m_sModuleUIName = lModuleProps.getUnpackedValueOrDefault(MODULEPROP_UINAME , OUString());
// get global accelerator configuration
m_xGlobal = css::ui::GlobalAcceleratorConfiguration::create(comphelper::getComponentContext(m_xSMGR));
@@ -929,7 +929,7 @@ void SfxAcceleratorConfigPage::Init(const css::uno::Reference< css::ui::XAcceler
for (i2=0; i2<c2; ++i2)
{
const css::awt::KeyEvent& aAWTKey = lKeys[i2];
::rtl::OUString sCommand = xAccMgr->getCommandByKeyEvent(aAWTKey);
OUString sCommand = xAccMgr->getCommandByKeyEvent(aAWTKey);
String sLabel = GetLabel4Command(sCommand);
KeyCode aKeyCode = ::svt::AcceleratorExecute::st_AWTKey2VCLKey(aAWTKey);
sal_uInt16 nPos = MapKeyCodeToPos(aKeyCode);
@@ -980,7 +980,7 @@ void SfxAcceleratorConfigPage::Apply(const css::uno::Reference< css::ui::XAccele
while (pEntry)
{
TAccInfo* pUserData = (TAccInfo*)pEntry->GetUserData();
::rtl::OUString sCommand ;
OUString sCommand ;
css::awt::KeyEvent aAWTKey ;
if (pUserData)
@@ -1071,7 +1071,7 @@ IMPL_LINK_NOARG(SfxAcceleratorConfigPage, RemoveHdl)
// remove function name from selected entry
sal_uInt16 nCol = aEntriesBox.TabCount() - 1;
aEntriesBox.SetEntryText( String(), nPos, nCol );
pEntry->m_sCommand = ::rtl::OUString();
pEntry->m_sCommand = OUString();
((Link &) pFunctionBox->GetSelectHdl()).Call( pFunctionBox );
return 0;
@@ -1086,7 +1086,7 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox )
{
sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() );
TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData();
::rtl::OUString sPossibleNewCommand = pFunctionBox->GetCurCommand();
OUString sPossibleNewCommand = pFunctionBox->GetCurCommand();
aRemoveButton.Enable( sal_False );
aChangeButton.Enable( sal_False );
@@ -1115,7 +1115,7 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox )
{
sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( pLBEntry );
TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData();
::rtl::OUString sPossibleNewCommand = pFunctionBox->GetCurCommand();
OUString sPossibleNewCommand = pFunctionBox->GetCurCommand();
if (pEntry->m_bIsConfigurable)
{
@@ -1205,7 +1205,7 @@ IMPL_LINK_NOARG(SfxAcceleratorConfigPage, LoadHdl)
{
DBG_ASSERT( m_pFileDlg, "SfxInternetPage::DialogClosedHdl(): no file dialog" );
::rtl::OUString sCfgName;
OUString sCfgName;
if ( ERRCODE_NONE == m_pFileDlg->GetError() )
sCfgName = m_pFileDlg->GetPath();
@@ -1289,7 +1289,7 @@ IMPL_LINK_NOARG(SfxAcceleratorConfigPage, SaveHdl)
{
DBG_ASSERT( m_pFileDlg, "SfxInternetPage::DialogClosedHdl(): no file dialog" );
::rtl::OUString sCfgName;
OUString sCfgName;
if ( ERRCODE_NONE == m_pFileDlg->GetError() )
sCfgName = m_pFileDlg->GetPath();
@@ -1332,7 +1332,7 @@ IMPL_LINK_NOARG(SfxAcceleratorConfigPage, SaveHdl)
css::uno::UNO_QUERY_THROW);
// set the correct media type if the storage was new created
::rtl::OUString sMediaType;
OUString sMediaType;
xUIConfigProps->getPropertyValue(MEDIATYPE_PROPNAME) >>= sMediaType;
if (sMediaType.isEmpty())
xUIConfigProps->setPropertyValue(MEDIATYPE_PROPNAME, css::uno::makeAny(MEDIATYPE_UICONFIG));
@@ -1497,7 +1497,7 @@ String SfxAcceleratorConfigPage::GetLabel4Command(const String& sCommand)
if (xModuleConf.is())
{
::comphelper::SequenceAsHashMap lProps(xModuleConf->getByName(sCommand));
String sLabel = String(lProps.getUnpackedValueOrDefault(CMDPROP_UINAME, ::rtl::OUString()));
String sLabel = String(lProps.getUnpackedValueOrDefault(CMDPROP_UINAME, OUString()));
if (sLabel.Len())
return sLabel;
}
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index 6603538..ee6387e 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -67,7 +67,7 @@ using namespace ::com::sun::star::frame;
using namespace ::com::sun::star::document;
namespace css = ::com::sun::star;
static ::rtl::OUString SERVICE_UICATEGORYDESCRIPTION (RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.UICategoryDescription") );
static OUString SERVICE_UICATEGORYDESCRIPTION ("com.sun.star.ui.UICategoryDescription");
SfxStylesInfo_Impl::SfxStylesInfo_Impl()
{}
@@ -77,18 +77,18 @@ void SfxStylesInfo_Impl::setModel(const ::com::sun::star::uno::Reference< ::com:
m_xDoc = xModel;
}
static ::rtl::OUString CMDURL_SPART (RTL_CONSTASCII_USTRINGPARAM(".uno:StyleApply?Style:string=") );
static ::rtl::OUString CMDURL_FPART2 (RTL_CONSTASCII_USTRINGPARAM("&FamilyName:string=") );
static OUString CMDURL_SPART (".uno:StyleApply?Style:string=");
static OUString CMDURL_FPART2 ("&FamilyName:string=");
static ::rtl::OUString CMDURL_STYLEPROT_ONLY (RTL_CONSTASCII_USTRINGPARAM(".uno:StyleApply?") );
static ::rtl::OUString CMDURL_SPART_ONLY (RTL_CONSTASCII_USTRINGPARAM("Style:string=") );
static ::rtl::OUString CMDURL_FPART_ONLY (RTL_CONSTASCII_USTRINGPARAM("FamilyName:string=") );
static OUString CMDURL_STYLEPROT_ONLY (".uno:StyleApply?");
static OUString CMDURL_SPART_ONLY ("Style:string=");
static OUString CMDURL_FPART_ONLY ("FamilyName:string=");
static ::rtl::OUString STYLEPROP_UINAME (RTL_CONSTASCII_USTRINGPARAM("DisplayName") );
static OUString STYLEPROP_UINAME ("DisplayName");
::rtl::OUString SfxStylesInfo_Impl::generateCommand(const ::rtl::OUString& sFamily, const ::rtl::OUString& sStyle)
OUString SfxStylesInfo_Impl::generateCommand(const OUString& sFamily, const OUString& sStyle)
{
::rtl::OUStringBuffer sCommand(1024);
OUStringBuffer sCommand(1024);
sCommand.append(CMDURL_SPART );
sCommand.append(sStyle );
sCommand.append(CMDURL_FPART2);
@@ -105,16 +105,16 @@ sal_Bool SfxStylesInfo_Impl::parseStyleCommand(SfxStyleInfo_Impl& aStyle)
if (aStyle.sCommand.indexOf(CMDURL_STYLEPROT_ONLY, 0) != 0)
return sal_False;
aStyle.sFamily = ::rtl::OUString();
aStyle.sStyle = ::rtl::OUString();
aStyle.sFamily = OUString();
aStyle.sStyle = OUString();
sal_Int32 nCmdLen = aStyle.sCommand.getLength();
::rtl::OUString sCmdArgs = aStyle.sCommand.copy(LEN_STYLEPROT, nCmdLen-LEN_STYLEPROT);
OUString sCmdArgs = aStyle.sCommand.copy(LEN_STYLEPROT, nCmdLen-LEN_STYLEPROT);
sal_Int32 i = sCmdArgs.indexOf('&');
if (i<0)
return sal_False;
::rtl::OUString sArg = sCmdArgs.copy(0, i);
OUString sArg = sCmdArgs.copy(0, i);
if (sArg.indexOf(CMDURL_SPART_ONLY) == 0)
aStyle.sStyle = sArg.copy(LEN_SPART, sArg.getLength()-LEN_SPART);
else if (sArg.indexOf(CMDURL_FPART_ONLY) == 0)
@@ -150,14 +150,14 @@ void SfxStylesInfo_Impl::getLabel4Style(SfxStyleInfo_Impl& aStyle)
if (xStyleSet.is())
xStyleSet->getByName(aStyle.sStyle) >>= xStyle;
aStyle.sLabel = ::rtl::OUString();
aStyle.sLabel = OUString();
if (xStyle.is())
xStyle->getPropertyValue(STYLEPROP_UINAME) >>= aStyle.sLabel;
}
catch(const css::uno::RuntimeException&)
{ throw; }
catch(const css::uno::Exception&)
{ aStyle.sLabel = ::rtl::OUString(); }
{ aStyle.sLabel = OUString(); }
if (aStyle.sLabel.isEmpty())
{
@@ -173,7 +173,7 @@ void SfxStylesInfo_Impl::getLabel4Style(SfxStyleInfo_Impl& aStyle)
return ::std::vector< SfxStyleInfo_Impl >();
css::uno::Reference< css::container::XNameAccess > xCont = xModel->getStyleFamilies();
css::uno::Sequence< ::rtl::OUString > lFamilyNames = xCont->getElementNames();
css::uno::Sequence< OUString > lFamilyNames = xCont->getElementNames();
::std::vector< SfxStyleInfo_Impl > lFamilies;
sal_Int32 c = lFamilyNames.getLength();
sal_Int32 i = 0;
@@ -205,11 +205,11 @@ void SfxStylesInfo_Impl::getLabel4Style(SfxStyleInfo_Impl& aStyle)
return lFamilies;
}
::std::vector< SfxStyleInfo_Impl > SfxStylesInfo_Impl::getStyles(const ::rtl::OUString& sFamily)
::std::vector< SfxStyleInfo_Impl > SfxStylesInfo_Impl::getStyles(const OUString& sFamily)
{
static ::rtl::OUString PROP_UINAME (RTL_CONSTASCII_USTRINGPARAM("DisplayName") );
static OUString PROP_UINAME ("DisplayName");
css::uno::Sequence< ::rtl::OUString > lStyleNames;
css::uno::Sequence< OUString > lStyleNames;
css::uno::Reference< css::style::XStyleFamiliesSupplier > xModel(m_xDoc, css::uno::UNO_QUERY_THROW);
css::uno::Reference< css::container::XNameAccess > xFamilies = xModel->getStyleFamilies();
css::uno::Reference< css::container::XNameAccess > xStyleSet;
@@ -371,8 +371,8 @@ struct SvxConfigGroupBoxResource_Impl : public Resource
Image m_libImage;
Image m_macImage;
Image m_docImage;
::rtl::OUString m_sMyMacros;
::rtl::OUString m_sProdMacros;
OUString m_sMyMacros;
OUString m_sProdMacros;
String m_sMacros;
String m_sDlgMacros;
String m_aHumanAppName;
@@ -454,8 +454,8 @@ void SfxConfigGroupListBox_Impl::InitModule()
for (i1=0; i1<c1; ++i1)
{
sal_Int16& rGroupID = lGroups[i1];
::rtl::OUString sGroupID = ::rtl::OUString::valueOf((sal_Int32)rGroupID);
::rtl::OUString sGroupName ;
OUString sGroupID = OUString::valueOf((sal_Int32)rGroupID);
OUString sGroupName ;
try
{
@@ -543,7 +543,7 @@ namespace
//-----------------------------------------------
void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR ,
const css::uno::Reference< css::frame::XFrame >& xFrame ,
const ::rtl::OUString& sModuleLongName)
const OUString& sModuleLongName)
{
SetUpdateMode(sal_False);
ClearAll(); // Remove all old entries from treelist box
@@ -572,13 +572,13 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul
try
{
Reference< browse::XBrowseNodeFactory > xFac( xCtx->getValueByName(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory") ) ), UNO_QUERY_THROW );
OUString( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory") ), UNO_QUERY_THROW );
rootNode.set( xFac->createView( browse::BrowseNodeFactoryViewTypes::MACROSELECTOR ) );
}
catch( Exception& e )
{
OSL_TRACE(" Caught some exception whilst retrieving browse nodes from factory... Exception: %s",
::rtl::OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).pData->buffer );
OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).pData->buffer );
// TODO exception handling
}
@@ -612,8 +612,8 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul
rootNode->getChildNodes();
sal_Bool bIsRootNode = sal_False;
::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") );
::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share") );
OUString user("user");
OUString share("share");
if ( rootNode->getName() == "Root" )
{
bIsRootNode = sal_True;
@@ -625,7 +625,7 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul
//set the bDisplay flag to FALSE if the current
//node is a first level child of the Root and is NOT
//either the current document, user or share
::rtl::OUString currentDocTitle;
OUString currentDocTitle;
Reference< XModel > xDocument( lcl_getScriptableDocument_nothrow( m_xFrame ) );
if ( xDocument.is() )
{
@@ -636,7 +636,7 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul
{
Reference< browse::XBrowseNode >& theChild = children[n];
sal_Bool bDisplay = sal_True;
::rtl::OUString uiName = theChild->getName();
OUString uiName = theChild->getName();
if ( bIsRootNode )
{
if ( ! ((theChild->getName().equals( user ) || theChild->getName().equals( share ) ||
@@ -722,28 +722,28 @@ Image SfxConfigGroupListBox_Impl::GetImage(
Image aImage;
if ( bIsRootNode )
{
::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") );
::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share") );
OUString user("user");
OUString share("share");
if (node->getName().equals( user ) || node->getName().equals(share ) )
{
aImage = pImp->m_hdImage;
}
else
{
::rtl::OUString factoryURL;
::rtl::OUString nodeName = node->getName();
OUString factoryURL;
OUString nodeName = node->getName();
Reference<XInterface> xDocumentModel = getDocumentModel(xCtx, nodeName );
if ( xDocumentModel.is() )
{
Reference< frame::XModuleManager2 > xModuleManager( frame::ModuleManager::create(xCtx) );
// get the long name of the document:
::rtl::OUString appModule( xModuleManager->identify(
OUString appModule( xModuleManager->identify(
xDocumentModel ) );
Sequence<beans::PropertyValue> moduleDescr;
Any aAny = xModuleManager->getByName(appModule);
if( sal_True != ( aAny >>= moduleDescr ) )
{
throw RuntimeException(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SFTreeListBox::Init: failed to get PropertyValue") ), Reference< XInterface >());
throw RuntimeException(OUString("SFTreeListBox::Init: failed to get PropertyValue"), Reference< XInterface >());
}
beans::PropertyValue const * pmoduleDescr =
moduleDescr.getConstArray();
@@ -753,7 +753,7 @@ Image SfxConfigGroupListBox_Impl::GetImage(
{
pmoduleDescr[ pos ].Value >>= factoryURL;
OSL_TRACE("factory url for doc images is %s",
::rtl::OUStringToOString( factoryURL , RTL_TEXTENCODING_ASCII_US ).pData->buffer );
OUStringToOString( factoryURL , RTL_TEXTENCODING_ASCII_US ).pData->buffer );
break;
}
}
@@ -779,7 +779,7 @@ Image SfxConfigGroupListBox_Impl::GetImage(
}
Reference< XInterface >
SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xCtx, ::rtl::OUString& docName )
SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xCtx, OUString& docName )
{
Reference< XInterface > xModel;
Reference< frame::XDesktop2 > desktop = frame::Desktop::create( xCtx );
@@ -794,7 +794,7 @@ SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xC
components->nextElement(), UNO_QUERY );
if ( model.is() )
{
::rtl::OUString sTdocUrl =
OUString sTdocUrl =
::comphelper::DocumentInfo::getDocumentTitle( model );
if( sTdocUrl.equals( docName ) )
{
@@ -807,9 +807,9 @@ SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xC
}
//-----------------------------------------------
::rtl::OUString SfxConfigGroupListBox_Impl::MapCommand2UIName(const ::rtl::OUString& sCommand)
OUString SfxConfigGroupListBox_Impl::MapCommand2UIName(const OUString& sCommand)
{
::rtl::OUString sUIName;
OUString sUIName;
try
{
css::uno::Reference< css::container::XNameAccess > xModuleConf;
@@ -817,13 +817,13 @@ SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xC
if (xModuleConf.is())
{
::comphelper::SequenceAsHashMap lProps(xModuleConf->getByName(sCommand));
sUIName = lProps.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name") ), ::rtl::OUString());
sUIName = lProps.getUnpackedValueOrDefault(OUString("Name"), OUString());
}
}
catch(const css::uno::RuntimeException&)
{ throw; }
catch(css::uno::Exception&)
{ sUIName = ::rtl::OUString(); }
{ sUIName = OUString(); }
// fallback for missing UINames !?
if (sUIName.isEmpty())
@@ -866,7 +866,7 @@ void SfxConfigGroupListBox_Impl::GroupSelected()
for (i=0; i<c; ++i)
{
const css::frame::DispatchInformation& rInfo = lCommands[i];
::rtl::OUString sUIName = MapCommand2UIName(rInfo.Command);
OUString sUIName = MapCommand2UIName(rInfo.Command);
SvTreeListEntry* pFuncEntry = pFunctionListBox->InsertEntry(sUIName, NULL);
SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl(SFX_CFGFUNCTION_SLOT, 0);
pGrpInfo->sCommand = rInfo.Command;
@@ -894,7 +894,7 @@ void SfxConfigGroupListBox_Impl::GroupSelected()
{
if (children[n]->getType() == browse::BrowseNodeTypes::SCRIPT)
{
::rtl::OUString uri;
OUString uri;
Reference < beans::XPropertySet >xPropSet( children[n], UNO_QUERY );
if (!xPropSet.is())
@@ -1019,8 +1019,8 @@ void SfxConfigGroupListBox_Impl::RequestingChildren( SvTreeListEntry *pEntry )
rootNode->getChildNodes();
sal_Bool bIsRootNode = sal_False;
::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") );
::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share" ));
OUString user("user");
OUString share("share" );
if ( rootNode->getName() == "Root" )
{
bIsRootNode = sal_True;
@@ -1032,7 +1032,7 @@ void SfxConfigGroupListBox_Impl::RequestingChildren( SvTreeListEntry *pEntry )
set the bDisplay flag to sal_False if the current
node is a first level child of the Root and is NOT
either the current document, user or share */
::rtl::OUString currentDocTitle;
OUString currentDocTitle;
Reference< XModel > xDocument( lcl_getScriptableDocument_nothrow( m_xFrame ) );
if ( xDocument.is() )
{
@@ -1043,7 +1043,7 @@ void SfxConfigGroupListBox_Impl::RequestingChildren( SvTreeListEntry *pEntry )
for ( sal_Int32 n = 0; n < nLen; ++n )
{
Reference< browse::XBrowseNode >& theChild = children[n];
::rtl::OUString aName( theChild->getName() );
OUString aName( theChild->getName() );
sal_Bool bDisplay = sal_True;
if ( bIsRootNode )
{
diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx
index 5370375..b5b7566e 100644
--- a/cui/source/customize/macropg.cxx
+++ b/cui/source/customize/macropg.cxx
@@ -48,8 +48,8 @@
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
static ::rtl::OUString aVndSunStarUNO( RTL_CONSTASCII_USTRINGPARAM( "vnd.sun.star.UNO:") );
static ::rtl::OUString aVndSunStarScript( RTL_CONSTASCII_USTRINGPARAM( "vnd.sun.star.script:") );
static OUString aVndSunStarUNO( "vnd.sun.star.UNO:" );
static OUString aVndSunStarScript( "vnd.sun.star.script:" );
_SvxMacroTabPage_Impl::_SvxMacroTabPage_Impl( const SfxItemSet& rAttrSet ) :
pAssignFT( NULL ),
@@ -226,7 +226,7 @@ _SvxMacroTabPage::~_SvxMacroTabPage()
SvTreeListEntry* pE = rListBox.GetEntry( 0 );
while( pE )
{
::rtl::OUString* pEventName = (::rtl::OUString*)pE->GetUserData();
OUString* pEventName = (OUString*)pE->GetUserData();
delete pEventName;
pE->SetUserData((void*)0);
pE = rListBox.NextSibling( pE );
@@ -322,7 +322,7 @@ sal_Bool _SvxMacroTabPage::FillItemSet( SfxItemSet& /*rSet*/ )
{
try
{
::rtl::OUString eventName;
OUString eventName;
if( m_xAppEvents.is() )
{
EventsHash::iterator h_itEnd = m_appEventsHash.end();
@@ -384,7 +384,7 @@ void _SvxMacroTabPage::Reset()
try
{
::rtl::OUString sEmpty;
OUString sEmpty;
if( m_xAppEvents.is() )
{
EventsHash::iterator h_itEnd = m_appEventsHash.end();
@@ -458,14 +458,14 @@ void IconLBoxString::Paint(
String aTxt( GetText() );
if( aTxt.Len() )
{
::rtl::OUString aURL( aTxt );
OUString aURL( aTxt );
sal_Int32 nIndex = aURL.indexOf( aVndSunStarUNO );
bool bUNO = nIndex == 0;
const Image* pImg = bUNO ? m_pComponentImg : m_pMacroImg;
aDevice.DrawImage( aPos, *pImg );
::rtl::OUString aPureMethod;
OUString aPureMethod;
if( bUNO )
{
sal_Int32 nBegin = aVndSunStarUNO.getLength();
@@ -513,12 +513,12 @@ void _SvxMacroTabPage::DisplayAppEvents( bool appEvents)
return;
}
Sequence< ::rtl::OUString > eventNames = nameReplace->getElementNames();
::std::set< ::rtl::OUString > aEventNamesCache;
Sequence< OUString > eventNames = nameReplace->getElementNames();
::std::set< OUString > aEventNamesCache;
::std::copy(
eventNames.getConstArray(),
eventNames.getConstArray() + eventNames.getLength(),
::std::insert_iterator< ::std::set< ::rtl::OUString > >( aEventNamesCache, aEventNamesCache.end() )
::std::insert_iterator< ::std::set< OUString > >( aEventNamesCache, aEventNamesCache.end() )
);
for ( EventDisplayNames::const_iterator displayableEvent = aDisplayNames.begin();
@@ -526,7 +526,7 @@ void _SvxMacroTabPage::DisplayAppEvents( bool appEvents)
++displayableEvent
)
{
::rtl::OUString sEventName( ::rtl::OUString::createFromAscii( displayableEvent->pAsciiEventName ) );
OUString sEventName( OUString::createFromAscii( displayableEvent->pAsciiEventName ) );
if ( !nameReplace->hasByName( sEventName ) )
continue;
@@ -537,12 +537,12 @@ void _SvxMacroTabPage::DisplayAppEvents( bool appEvents)
continue;
}
::rtl::OUString eventURL = h_it->second.second;
OUString eventURL = h_it->second.second;
String displayName( CUI_RES( displayableEvent->nEventResourceID ) );
displayName += '\t';
SvTreeListEntry* _pE = rListBox.InsertEntry( displayName );
::rtl::OUString* pEventName = new ::rtl::OUString( sEventName );
OUString* pEventName = new OUString( sEventName );
_pE->SetUserData( (void*)pEventName );
String sNew( eventURL );
_pE->ReplaceItem( new IconLBoxString( _pE, 0, sNew,
@@ -608,10 +608,10 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton*
const sal_Bool bAssEnabled = pBtn != pImpl->pDeletePB && pImpl->pAssignPB->IsEnabled();
::rtl::OUString* pEventName = (::rtl::OUString*)pE->GetUserData();
OUString* pEventName = (OUString*)pE->GetUserData();
::rtl::OUString sEventURL;
::rtl::OUString sEventType;
OUString sEventURL;
OUString sEventType;
if(pThis->bAppEvents)
{
EventsHash::iterator h_it = pThis->m_appEventsHash.find( *pEventName );
@@ -636,8 +636,8 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton*
if( pBtn == pImpl->pDeletePB )
{
// delete pressed
sEventType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Script") );
sEventURL = ::rtl::OUString();
sEventType = OUString( "Script" );
sEventURL = OUString();
if(!pThis->bAppEvents)
pThis->bDocModified = true;
}
@@ -654,7 +654,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton*
short ret = pAssignDlg->Execute();
if( ret )
{
sEventType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UNO"));
sEventType = OUString("UNO");
sEventURL = pAssignDlg->getURL();
if(!pThis->bAppEvents)
pThis->bDocModified = true;
@@ -670,7 +670,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton*
short ret = pDlg->Execute();
if ( ret )
{
sEventType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Script"));
sEventType = OUString("Script");
sEventURL = pDlg->GetScriptURL();
if(!pThis->bAppEvents)
pThis->bDocModified = true;
@@ -746,7 +746,7 @@ void _SvxMacroTabPage::InitAndSetHandler( Reference< container::XNameReplace> xA
{
return;
}
Sequence< ::rtl::OUString > eventNames = m_xAppEvents->getElementNames();
Sequence< OUString > eventNames = m_xAppEvents->getElementNames();
sal_Int32 nEventCount = eventNames.getLength();
for(sal_Int32 nEvent = 0; nEvent < nEventCount; ++nEvent )
{
@@ -777,9 +777,9 @@ void _SvxMacroTabPage::InitAndSetHandler( Reference< container::XNameReplace> xA
}
// returns the two props EventType & Script for a given event name
Any _SvxMacroTabPage::GetPropsByName( const ::rtl::OUString& eventName, EventsHash& eventsHash )
Any _SvxMacroTabPage::GetPropsByName( const OUString& eventName, EventsHash& eventsHash )
{
const ::std::pair< ::rtl::OUString, ::rtl::OUString >& rAssignedEvent( eventsHash[ eventName ] );
const ::std::pair< OUString, OUString >& rAssignedEvent( eventsHash[ eventName ] );
Any aReturn;
::comphelper::NamedValueCollection aProps;
@@ -795,10 +795,10 @@ Any _SvxMacroTabPage::GetPropsByName( const ::rtl::OUString& eventName, EventsHa
// converts the Any returned by GetByName into a pair which can be stored in
// the EventHash
::std::pair< ::rtl::OUString, ::rtl::OUString > _SvxMacroTabPage::GetPairFromAny( Any aAny )
::std::pair< OUString, OUString > _SvxMacroTabPage::GetPairFromAny( Any aAny )
{
Sequence< beans::PropertyValue > props;
::rtl::OUString type, url;
OUString type, url;
if( sal_True == ( aAny >>= props ) )
{
::comphelper::NamedValueCollection aProps( props );
@@ -872,8 +872,8 @@ SvxMacroAssignDlg::~SvxMacroAssignDlg()
IMPL_LINK_NOARG(AssignComponentDialog, ButtonHandler)
{
::rtl::OUString aMethodName = maMethodEdit.GetText();
maURL = ::rtl::OUString();
OUString aMethodName = maMethodEdit.GetText();
maURL = OUString();
if( !aMethodName.isEmpty() )
{
maURL = aVndSunStarUNO;
@@ -883,7 +883,7 @@ IMPL_LINK_NOARG(AssignComponentDialog, ButtonHandler)
return 0;
}
AssignComponentDialog::AssignComponentDialog( Window * pParent, const ::rtl::OUString& rURL )
AssignComponentDialog::AssignComponentDialog( Window * pParent, const OUString& rURL )
: ModalDialog( pParent, CUI_RES( RID_SVXDLG_ASSIGNCOMPONENT ) )
, maMethodLabel( this, CUI_RES( FT_METHOD ) )
, maMethodEdit( this, CUI_RES( EDIT_METHOD ) )
@@ -895,7 +895,7 @@ AssignComponentDialog::AssignComponentDialog( Window * pParent, const ::rtl::OUS
FreeResource();
maOKButton.SetClickHdl(LINK(this, AssignComponentDialog, ButtonHandler));
::rtl::OUString aMethodName;
OUString aMethodName;
if( !maURL.isEmpty() )
{
sal_Int32 nIndex = maURL.indexOf( aVndSunStarUNO );
diff --git a/cui/source/customize/selector.cxx b/cui/source/customize/selector.cxx
index 65bfde5..49e02e5 100644
--- a/cui/source/customize/selector.cxx
+++ b/cui/source/customize/selector.cxx
@@ -308,7 +308,7 @@ void SvxConfigGroupListBox::fillScriptList( const Reference< browse::XBrowseNode
//#139111# some crash reports show that it might be unset
if ( !theChild.is() )
continue;
::rtl::OUString sUIName = theChild->getName();
OUString sUIName = theChild->getName();
sal_Bool bDisplay = sal_True;
if ( bIsRootNode
@@ -409,7 +409,7 @@ void SvxConfigGroupListBox::Init(bool bShowSlots, const Reference< frame::XFrame
try{
aModuleId = xModuleManager->identify( m_xFrame );
}catch(const uno::Exception&)
{ aModuleId = ::rtl::OUString(); }
{ aModuleId = OUString(); }
Reference< container::XNameAccess > const xNameAccess(
frame::UICommandDescription::create(xContext) );
@@ -417,8 +417,8 @@ void SvxConfigGroupListBox::Init(bool bShowSlots, const Reference< frame::XFrame
Reference< container::XNameAccess > xAllCategories(
xMCF->createInstanceWithContext(
OUString(RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.ui.UICategoryDescription" )),
OUString(
"com.sun.star.ui.UICategoryDescription" ),
xContext ),
UNO_QUERY );
@@ -494,7 +494,7 @@ void SvxConfigGroupListBox::Init(bool bShowSlots, const Reference< frame::XFrame
try
{
Reference< browse::XBrowseNodeFactory > xFac( xContext->getValueByName(
OUString(RTL_CONSTASCII_USTRINGPARAM( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory")) ), UNO_QUERY_THROW );
OUString( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory") ), UNO_QUERY_THROW );
rootNode.set( xFac->createView( browse::BrowseNodeFactoryViewTypes::MACROSELECTOR ) );
}
catch( const Exception& )
@@ -553,7 +553,7 @@ Image SvxConfigGroupListBox::GetImage(
Any aAny = xModuleManager->getByName(appModule);
if( sal_True != ( aAny >>= moduleDescr ) )
{
throw RuntimeException(OUString(RTL_CONSTASCII_USTRINGPARAM("SFTreeListBox::Init: failed to get PropertyValue")), Reference< XInterface >());
throw RuntimeException(OUString("SFTreeListBox::Init: failed to get PropertyValue"), Reference< XInterface >());
}
beans::PropertyValue const * pmoduleDescr =
moduleDescr.getConstArray();
@@ -706,7 +706,7 @@ void SvxConfigGroupListBox::GroupSelected()
}
SvxGroupInfo_Impl *_pGroupInfo = new SvxGroupInfo_Impl(
SVX_CFGFUNCTION_SLOT, 123, aCmdURL, ::rtl::OUString() );
SVX_CFGFUNCTION_SLOT, 123, aCmdURL, OUString() );
pFunctionListBox->aArr.push_back( _pGroupInfo );
@@ -742,13 +742,13 @@ void SvxConfigGroupListBox::GroupSelected()
}
Any value = xPropSet->getPropertyValue(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URI")));
OUString("URI"));
value >>= uri;
try
{
value = xPropSet->getPropertyValue(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Description")));
OUString("Description"));
value >>= description;
}
catch (Exception &) {
diff --git a/cui/source/dialogs/hyphen.cxx b/cui/source/dialogs/hyphen.cxx
index 3491cb7..983893a 100644
--- a/cui/source/dialogs/hyphen.cxx
+++ b/cui/source/dialogs/hyphen.cxx
@@ -177,8 +177,8 @@ String SvxHyphenWordDialog::EraseUnusableHyphens_Impl(
// 1) remove all not usable hyphenation positions from the end of the string
nPos = nIdx == STRING_NOTFOUND ? 0 : nIdx + 1;
nPos1 = nPos; //save for later use in 2) below
const rtl::OUString aTmp( sal_Unicode( HYPH_POS_CHAR ) );
const rtl::OUString aEmpty;
const OUString aTmp( sal_Unicode( HYPH_POS_CHAR ) );
const OUString aEmpty;
while (nPos != STRING_NOTFOUND)
nPos = aTxt.SearchAndReplace( aTmp, aEmpty, nPos + 1 );
@@ -359,7 +359,7 @@ IMPL_LINK( SvxHyphenWordDialog, HyphenateAllHdl_Impl, Button *, EMPTYARG /*pButt
try
{
uno::Reference< beans::XPropertySet > xProp( SvxGetLinguPropertySet() );
const rtl::OUString aName( RTL_CONSTASCII_USTRINGPARAM( "IsHyphAuto" ) );
const OUString aName( "IsHyphAuto" );
uno::Any aAny;
aAny <<= sal_True;
diff --git a/cui/source/options/connpoolconfig.cxx b/cui/source/options/connpoolconfig.cxx
index b5de077..d66a595 100644
--- a/cui/source/options/connpoolconfig.cxx
+++ b/cui/source/options/connpoolconfig.cxx
@@ -37,44 +37,44 @@ namespace offapp
using namespace ::com::sun::star::uno;
//--------------------------------------------------------------------
static const ::rtl::OUString& getConnectionPoolNodeName()
static const OUString& getConnectionPoolNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.DataAccess/ConnectionPool") );
static OUString s_sNodeName("org.openoffice.Office.DataAccess/ConnectionPool" );
return s_sNodeName;
}
//--------------------------------------------------------------------
static const ::rtl::OUString& getEnablePoolingNodeName()
static const OUString& getEnablePoolingNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("EnablePooling"));
static OUString s_sNodeName("EnablePooling");
return s_sNodeName;
}
//--------------------------------------------------------------------
static const ::rtl::OUString& getDriverSettingsNodeName()
static const OUString& getDriverSettingsNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("DriverSettings"));
static OUString s_sNodeName("DriverSettings");
return s_sNodeName;
}
//--------------------------------------------------------------------
static const ::rtl::OUString& getDriverNameNodeName()
static const OUString& getDriverNameNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("DriverName"));
static OUString s_sNodeName("DriverName");
return s_sNodeName;
}
//--------------------------------------------------------------------
static const ::rtl::OUString& getEnableNodeName()
static const OUString& getEnableNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Enable"));
static OUString s_sNodeName("Enable");
return s_sNodeName;
}
//--------------------------------------------------------------------
static const ::rtl::OUString& getTimeoutNodeName()
static const OUString& getTimeoutNodeName()
{
static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Timeout"));
static OUString s_sNodeName("Timeout");
return s_sNodeName;
}
@@ -109,14 +109,14 @@ namespace offapp
// then look for which of them settings are stored in the configuration
OConfigurationNode aDriverSettings = aConnectionPoolRoot.openNode(getDriverSettingsNodeName());
Sequence< ::rtl::OUString > aDriverKeys = aDriverSettings.getNodeNames();
const ::rtl::OUString* pDriverKeys = aDriverKeys.getConstArray();
const ::rtl::OUString* pDriverKeysEnd = pDriverKeys + aDriverKeys.getLength();
Sequence< OUString > aDriverKeys = aDriverSettings.getNodeNames();
const OUString* pDriverKeys = aDriverKeys.getConstArray();
const OUString* pDriverKeysEnd = pDriverKeys + aDriverKeys.getLength();
for (;pDriverKeys != pDriverKeysEnd; ++pDriverKeys)
{
// the name of the driver in this round
OConfigurationNode aThisDriverSettings = aDriverSettings.openNode(*pDriverKeys);
::rtl::OUString sThisDriverName;
OUString sThisDriverName;
aThisDriverSettings.getNodeValue(getDriverNameNodeName()) >>= sThisDriverName;
// look if we (resp. the driver manager) know this driver
@@ -176,7 +176,7 @@ namespace offapp
if (!aDriverSettings.isValid())
return;
::rtl::OUString sThisDriverName;
OUString sThisDriverName;
OConfigurationNode aThisDriverSettings;
const DriverPoolingSettings& rNewSettings = pDriverSettings->getSettings();
@@ -185,7 +185,7 @@ namespace offapp
++aLoop
)
{
// need the name as ::rtl::OUString
// need the name as OUString
sThisDriverName = aLoop->sName;
// the sub-node for this driver
diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index 380a295..f6d7934 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -111,40 +111,40 @@ int OfaMiscTabPage::DeactivatePage( SfxItemSet* pSet_ )
namespace
{
static ::rtl::OUString impl_SystemFileOpenServiceName()
static OUString impl_SystemFileOpenServiceName()
{
const ::rtl::OUString &rDesktopEnvironment = Application::GetDesktopEnvironment();
const OUString &rDesktopEnvironment = Application::GetDesktopEnvironment();
if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM("kde4")) )
{
#ifdef ENABLE_KDE4
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.dialogs.KDE4FilePicker") );
return OUString("com.sun.star.ui.dialogs.KDE4FilePicker" );
#else
return rtl::OUString();
return OUString();
#endif
}
else if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM("kde")) )
{
#ifdef ENABLE_KDE
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.dialogs.KDEFilePicker") );
return OUString("com.sun.star.ui.dialogs.KDEFilePicker");
#else
return rtl::OUString();
return OUString();
#endif
}
else if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM("tde")) )
{
#ifdef ENABLE_TDE
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.dialogs.TDEFilePicker") );
return OUString("com.sun.star.ui.dialogs.TDEFilePicker");
#else
return rtl::OUString();
return OUString();
#endif
}
#if defined WNT
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.dialogs.SystemFilePicker") );
return OUString("com.sun.star.ui.dialogs.SystemFilePicker");
#elif defined MACOSX
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.dialogs.AquaFilePicker") );
return OUString("com.sun.star.ui.dialogs.AquaFilePicker");
#else
return rtl::OUString();
return OUString();
#endif
}
@@ -165,7 +165,7 @@ namespace
try
{
::rtl::OUString aFileService = impl_SystemFileOpenServiceName();
OUString aFileService = impl_SystemFileOpenServiceName();
Reference< XEnumeration > xEnum = xEnumAccess->createContentEnumeration( aFileService );
if ( xEnum.is() && xEnum->hasMoreElements() )
bRet = true;
@@ -421,23 +421,23 @@ CanvasSettings::CanvasSettings() :
Any propValue(
makeAny( NamedValue(
OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath")),
makeAny( OUString(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Canvas")) ) ) ) );
OUString("nodepath"),
makeAny( OUString("/org.openoffice.Office.Canvas") ) ) ) );
mxForceFlagNameAccess.set(
xConfigProvider->createInstanceWithArguments(
OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationUpdateAccess")),
OUString("com.sun.star.configuration.ConfigurationUpdateAccess"),
Sequence<Any>( &propValue, 1 ) ),
UNO_QUERY_THROW );
propValue = makeAny(
NamedValue(
OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath")),
makeAny( OUString(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Canvas/CanvasServiceList")) ) ) );
OUString("nodepath"),
makeAny( OUString("/org.openoffice.Office.Canvas/CanvasServiceList") ) ) );
Reference<XNameAccess> xNameAccess(
xConfigProvider->createInstanceWithArguments(
OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationAccess")),
OUString("com.sun.star.configuration.ConfigurationAccess"),
Sequence<Any>( &propValue, 1 ) ), UNO_QUERY_THROW );
Reference<XHierarchicalNameAccess> xHierarchicalNameAccess(
xNameAccess, UNO_QUERY_THROW);
@@ -454,7 +454,7 @@ CanvasSettings::CanvasSettings() :
if( xEntryNameAccess.is() )
{
Sequence<OUString> preferredImplementations;
if( (xEntryNameAccess->getByName( OUString(RTL_CONSTASCII_USTRINGPARAM("PreferredImplementations")) ) >>= preferredImplementations) )
if( (xEntryNameAccess->getByName( OUString("PreferredImplementations") ) >>= preferredImplementations) )
maAvailableImplementations.push_back( std::make_pair(*pCurr,preferredImplementations) );
}
@@ -492,7 +492,7 @@ sal_Bool CanvasSettings::IsHardwareAccelerationAvailable() const
pCurrImpl->trim() ),
UNO_QUERY_THROW );
bool bHasAccel(false);
if( (xPropSet->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("HardwareAcceleration"))) >>= bHasAccel) )
if( (xPropSet->getPropertyValue(OUString("HardwareAcceleration")) >>= bHasAccel) )
if( bHasAccel )
{
mbHWAccelAvailable = true;
@@ -520,7 +520,7 @@ sal_Bool CanvasSettings::IsHardwareAccelerationEnabled() const
if( !mxForceFlagNameAccess.is() )
return true;
if( !(mxForceFlagNameAccess->getByName( OUString(RTL_CONSTASCII_USTRINGPARAM("ForceSafeServiceImpl")) ) >>= bForceLastEntry) )
if( !(mxForceFlagNameAccess->getByName( OUString("ForceSafeServiceImpl") ) >>= bForceLastEntry) )
return true;
return !bForceLastEntry;
@@ -535,7 +535,7 @@ void CanvasSettings::EnabledHardwareAcceleration( sal_Bool _bEnabled ) const
if( !xNameReplace.is() )
return;
xNameReplace->replaceByName( OUString(RTL_CONSTASCII_USTRINGPARAM("ForceSafeServiceImpl")),
xNameReplace->replaceByName( OUString("ForceSafeServiceImpl"),
makeAny(!_bEnabled) );
Reference< XChangesBatch > xChangesBatch(
@@ -625,7 +625,7 @@ OfaViewTabPage::OfaViewTabPage(Window* pParent, const SfxItemSet& rSet)
{
::rtl::OUString aAutoStr( m_pIconStyleLB->GetEntry( 0 ) );
aAutoStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" (") );
aAutoStr += OUString(" (" );
// prefer the icon style set by the desktop native widgets modules
sal_uLong nAutoStyle = aStyleSettings.GetPreferredSymbolsStyle();
@@ -990,12 +990,12 @@ struct LanguageConfig_Impl
static sal_Bool bLanguageCurrentDoc_Impl = sal_False;
// some things we'll need...
static const OUString sAccessSrvc(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationAccess"));
static const OUString sAccessUpdSrvc(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationUpdateAccess"));
static const OUString sInstalledLocalesPath(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Setup/Office/InstalledLocales"));
static OUString sUserLocalePath(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Linguistic/General"));
//static const OUString sUserLocalePath(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office/Linguistic"));
static const OUString sUserLocaleKey(RTL_CONSTASCII_USTRINGPARAM("UILocale"));
static const OUString sAccessSrvc("com.sun.star.configuration.ConfigurationAccess");
static const OUString sAccessUpdSrvc("com.sun.star.configuration.ConfigurationUpdateAccess");
static const OUString sInstalledLocalesPath("org.openoffice.Setup/Office/InstalledLocales");
static OUString sUserLocalePath("org.openoffice.Office.Linguistic/General");
//static const OUString sUserLocalePath("org.openoffice.Office/Linguistic");
static const OUString sUserLocaleKey("UILocale");
static Sequence< OUString > seqInstalledLanguages;
static OUString lcl_getDatePatternsConfigString( const LocaleDataWrapper& rLocaleWrapper )
@@ -1072,7 +1072,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe
Reference< XNameAccess > theNameAccess;
// find out which locales are currently installed and add them to the listbox
theArgs[0] = makeAny(NamedValue(OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath")), makeAny(sInstalledLocalesPath)));
theArgs[0] = makeAny(NamedValue(OUString("nodepath"), makeAny(sInstalledLocalesPath)));
theNameAccess = Reference< XNameAccess > (
theConfigProvider->createInstanceWithArguments(sAccessSrvc, theArgs ), UNO_QUERY_THROW );
seqInstalledLanguages = theNameAccess->getElementNames();
@@ -1091,7 +1091,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe
// find out whether the user has a specific locale specified
Sequence< Any > theArgs2(1);
theArgs2[0] = makeAny(NamedValue(OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath")), makeAny(sUserLocalePath)));
theArgs2[0] = makeAny(NamedValue(OUString("nodepath"), makeAny(sUserLocalePath)));
theNameAccess = Reference< XNameAccess > (
theConfigProvider->createInstanceWithArguments(sAccessSrvc, theArgs2 ), UNO_QUERY_THROW );
if (theNameAccess->hasByName(sUserLocaleKey))
@@ -1267,7 +1267,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
com::sun::star::configuration::theDefaultProvider::get(
comphelper::getProcessComponentContext()));
Sequence< Any > theArgs(1);
theArgs[0] = makeAny(NamedValue(OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath")), makeAny(sUserLocalePath)));
theArgs[0] = makeAny(NamedValue(OUString("nodepath"), makeAny(sUserLocalePath)));
Reference< XPropertySet >xProp(
theConfigProvider->createInstanceWithArguments(sAccessUpdSrvc, theArgs ), UNO_QUERY_THROW );
if ( !m_sUserLocaleValue.equals(aLangString))
@@ -1285,7 +1285,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
Reference< XMultiServiceFactory > theMSF(
comphelper::getProcessServiceFactory());
Reference< XInitialization > xInit(theMSF->createInstance(
OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.office.Quickstart"))), UNO_QUERY);
OUString("com.sun.star.office.Quickstart")), UNO_QUERY);
if (xInit.is())
{
Sequence< Any > args(3);
diff --git a/cui/source/options/optinet2.cxx b/cui/source/options/optinet2.cxx
index 08def31..c8bd32a 100644
--- a/cui/source/options/optinet2.cxx
+++ b/cui/source/options/optinet2.cxx
@@ -130,7 +130,7 @@ void SvxNoSpaceEdit::Modify()
if ( bOnlyNumeric )
{
rtl::OUString aValue = GetText();
OUString aValue = GetText();
if ( !comphelper::string::isdigitAsciiString(aValue) || (long)aValue.toInt32() > USHRT_MAX )
// the maximum value of a port number is USHRT_MAX
@@ -170,14 +170,14 @@ SvxProxyTabPage::SvxProxyTabPage(Window* pParent, const SfxItemSet& rSet ) :
aNoProxyForED (this, CUI_RES( ED_NOPROXYFOR )),
aNoProxyDescFT (this, CUI_RES( ED_NOPROXYDESC )),
sFromBrowser ( CUI_RES( ST_PROXY_FROM_BROWSER ) ),
aProxyModePN(RTL_CONSTASCII_USTRINGPARAM("ooInetProxyType")),
aHttpProxyPN(RTL_CONSTASCII_USTRINGPARAM("ooInetHTTPProxyName")),
aHttpPortPN(RTL_CONSTASCII_USTRINGPARAM("ooInetHTTPProxyPort")),
aHttpsProxyPN(RTL_CONSTASCII_USTRINGPARAM("ooInetHTTPSProxyName")),
aHttpsPortPN(RTL_CONSTASCII_USTRINGPARAM("ooInetHTTPSProxyPort")),
aFtpProxyPN(RTL_CONSTASCII_USTRINGPARAM("ooInetFTPProxyName")),
aFtpPortPN(RTL_CONSTASCII_USTRINGPARAM("ooInetFTPProxyPort")),
aNoProxyDescPN(RTL_CONSTASCII_USTRINGPARAM("ooInetNoProxy"))
aProxyModePN("ooInetProxyType"),
aHttpProxyPN("ooInetHTTPProxyName"),
aHttpPortPN("ooInetHTTPProxyPort"),
aHttpsProxyPN("ooInetHTTPSProxyName"),
aHttpsPortPN("ooInetHTTPSProxyPort"),
aFtpProxyPN("ooInetFTPProxyName"),
aFtpPortPN("ooInetFTPProxyPort"),
aNoProxyDescPN("ooInetNoProxy")
{
FreeResource();
@@ -196,18 +196,18 @@ SvxProxyTabPage::SvxProxyTabPage(Window* pParent, const SfxItemSet& rSet ) :
configuration::theDefaultProvider::get(
comphelper::getProcessComponentContext() ) );
OUString aConfigRoot(RTL_CONSTASCII_USTRINGPARAM( "org.openoffice.Inet/Settings" ) );
OUString aConfigRoot( "org.openoffice.Inet/Settings" );
beans::NamedValue aProperty;
aProperty.Name = OUString(RTL_CONSTASCII_USTRINGPARAM( "nodepath" ));
aProperty.Name = OUString( "nodepath" );
aProperty.Value = makeAny( aConfigRoot );
Sequence< Any > aArgumentList( 1 );
aArgumentList[0] = makeAny( aProperty );
m_xConfigurationUpdateAccess = xConfigurationProvider->createInstanceWithArguments( rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.configuration.ConfigurationUpdateAccess" ) ),
aArgumentList );
m_xConfigurationUpdateAccess = xConfigurationProvider->createInstanceWithArguments(
OUString( "com.sun.star.configuration.ConfigurationUpdateAccess" ),
aArgumentList );
ArrangeControls_Impl();
}
@@ -575,10 +575,10 @@ IMPL_LINK( SvxProxyTabPage, ProxyHdl_Impl, ListBox *, pBox )
IMPL_LINK( SvxProxyTabPage, LoseFocusHdl_Impl, Edit *, pEdit )
{
rtl::OUString aValue = pEdit->GetText();
OUString aValue = pEdit->GetText();
if ( !comphelper::string::isdigitAsciiString(aValue) || (long)aValue.toInt32() > USHRT_MAX )
pEdit->SetText( rtl::OUString('0') );
pEdit->SetText( OUString('0') );
return 0;
}
@@ -811,7 +811,7 @@ IMPL_LINK_NOARG(SvxSecurityTabPage, CertPathPBHdl)
if (!mpCertPathDlg)
mpCertPathDlg = new CertPathDialog(this);
rtl::OUString sOrig = mpCertPathDlg->getDirectory();
OUString sOrig = mpCertPathDlg->getDirectory();
short nRet = mpCertPathDlg->Execute();
if (nRet == RET_OK && sOrig != mpCertPathDlg->getDirectory())
@@ -833,7 +833,7 @@ IMPL_LINK_NOARG(SvxSecurityTabPage, MacroSecPBHdl)
}
catch (const Exception& e)
{
OSL_FAIL(rtl::OUStringToOString(e.Message, osl_getThreadTextEncoding()).getStr());
OSL_FAIL(OUStringToOString(e.Message, osl_getThreadTextEncoding()).getStr());
(void)e;
}
return 0;
@@ -1002,15 +1002,15 @@ extern "C" {
#endif
#define NPP_PATH_MAX 2048
inline bool getDllURL(rtl::OString * path)
inline bool getDllURL(OString * path)
{
OSL_ASSERT(path != NULL);
::rtl::OUString dirPath/*dllPath, */;
OUString dirPath/*dllPath, */;
if (osl_getExecutableFile(&dirPath.pData) != osl_Process_E_None) {
return false;
}
dirPath = dirPath.copy(0, dirPath.lastIndexOf('/'));
::rtl::OUString sysDirPath;
OUString sysDirPath;
osl::FileBase::getSystemPathFromFileURL(dirPath, sysDirPath);
*path = OUStringToOString(sysDirPath, RTL_TEXTENCODING_ASCII_US);
return true;
@@ -1039,7 +1039,7 @@ sal_Bool MozPluginTabPage::isInstalled()
// get the real file path
char realFilePath[NPP_PATH_MAX] = {0};
::rtl::OString tempString;
OString tempString;
if (!getDllURL(&tempString)) {
return false;
}
@@ -1053,7 +1053,7 @@ sal_Bool MozPluginTabPage::isInstalled()
#ifdef WNT
// get the value from registry
sal_Bool ret = true;
::rtl::OString tempString;
OString tempString;
char realFilePath[NPP_PATH_MAX] = {0};
if (!getDllURL(&tempString)){
return false;
@@ -1090,7 +1090,7 @@ sal_Bool MozPluginTabPage::installPlugin()
// get the real file path
char realFilePath[NPP_PATH_MAX] = {0};
::rtl::OString tempString;
OString tempString;
if (!getDllURL(&tempString)) {
return false;
}
@@ -1103,7 +1103,7 @@ sal_Bool MozPluginTabPage::installPlugin()
return true;
#endif
#ifdef WNT
::rtl::OString tempString;
OString tempString;
char realFilePath[NPP_PATH_MAX] = {0};
if (!getDllURL(&tempString)) {
return false;
@@ -1130,7 +1130,7 @@ sal_Bool MozPluginTabPage::uninstallPlugin()
return true;
#endif
#ifdef WNT
::rtl::OString tempString;
OString tempString;
char realFilePath[NPP_PATH_MAX] = {0};
if (!getDllURL(&tempString)) {
return false;
@@ -1159,7 +1159,7 @@ public:
virtual ~MailerProgramCfg_Impl();
virtual void Commit();
virtual void Notify( const com::sun::star::uno::Sequence< rtl::OUString >& _rPropertyNames);
virtual void Notify( const com::sun::star::uno::Sequence< OUString >& _rPropertyNames);
};
/* -------------------------------------------------------------------------*/
@@ -1239,7 +1239,7 @@ void MailerProgramCfg_Impl::Commit()
PutProperties(aNames, aValues);
}
void MailerProgramCfg_Impl::Notify( const com::sun::star::uno::Sequence< rtl::OUString >& )
void MailerProgramCfg_Impl::Notify( const com::sun::star::uno::Sequence< OUString >& )
{
}
@@ -1343,14 +1343,14 @@ IMPL_LINK( SvxEMailTabPage, FileDialogHdl_Impl, PushButton*, pButton )
FileDialogHelper aHelper(
com::sun::star::ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE,
0 );
rtl::OUString sPath = aMailerURLED.GetText();
OUString sPath = aMailerURLED.GetText();
if ( sPath.isEmpty() )
sPath = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/usr/bin"));
sPath = OUString("/usr/bin");
rtl::OUString sUrl;
OUString sUrl;
::utl::LocalFileHelper::ConvertPhysicalNameToURL(sPath, sUrl);
aHelper.SetDisplayDirectory(sUrl);
aHelper.AddFilter( m_sDefaultFilterName, rtl::OUString("*"));
aHelper.AddFilter( m_sDefaultFilterName, OUString("*"));
if ( ERRCODE_NONE == aHelper.Execute() )
{
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 21c0414..c794bdd 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -133,7 +133,7 @@ static sal_Int32 lcl_SeqGetEntryPos(
return i < nLen ? i : -1;
}
static void lcl_OpenURL( ::rtl::OUString sURL )
static void lcl_OpenURL( OUString sURL )
{
if ( !sURL.isEmpty() )
{
@@ -144,12 +144,12 @@ static void lcl_OpenURL( ::rtl::OUString sURL )
::comphelper::getProcessComponentContext();
uno::Reference< css::system::XSystemShellExecute > xSystemShell(
css::system::SystemShellExecute::create(xContext) );
xSystemShell->execute( sURL, ::rtl::OUString(), css::system::SystemShellExecuteFlags::URIS_ONLY );
xSystemShell->execute( sURL, OUString(), css::system::SystemShellExecuteFlags::URIS_ONLY );
}
catch( const uno::Exception& e )
{
OSL_TRACE( "Caught exception: %s\n thread terminated.\n",
rtl::OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());
OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());
}
}
}
@@ -375,7 +375,7 @@ static const char * aEidToPropName[] =
static inline String lcl_GetPropertyName( EID_OPTIONS eEntryId )
{
DBG_ASSERT( (unsigned int) eEntryId < SAL_N_ELEMENTS(aEidToPropName), "index out of range" );
return rtl::OUString::createFromAscii( aEidToPropName[ (int) eEntryId ] );
return OUString::createFromAscii( aEidToPropName[ (int) eEntryId ] );
}
// class OptionsUserData -------------------------------------------------
@@ -474,7 +474,7 @@ void BrwString_Impl::Paint(
OptionsUserData aData( (sal_uLong) pEntry->GetUserData() );
if(aData.HasNumericValue())
{
rtl::OUStringBuffer sTxt;
OUStringBuffer sTxt;
sTxt.append(' ').append(static_cast<sal_Int32>(aData.GetNumericValue()));
rDev.SetFont( aFont );
rDev.DrawText( aNewPos, sTxt.makeStringAndClear() );
@@ -1108,7 +1108,7 @@ SvxLinguTabPage::SvxLinguTabPage( Window* pParent,
!= SvtExtendedSecurityOptions::OPEN_NEVER )
{
aMoreDictsLink.SetURL( String(
RTL_CONSTASCII_USTRINGPARAM( "http://extensions.libreoffice.org/dictionaries/" ) ) );
"http://extensions.libreoffice.org/dictionaries/" ) );
aMoreDictsLink.SetClickHdl( LINK( this, SvxLinguTabPage, OpenURLHdl_Impl ) );
}
else
@@ -1579,7 +1579,7 @@ IMPL_LINK_NOARG(SvxLinguTabPage, PostDblClickHdl_Impl)
IMPL_LINK_NOARG(SvxLinguTabPage, OpenURLHdl_Impl)
{
::rtl::OUString sURL( aMoreDictsLink.GetURL() );
OUString sURL( aMoreDictsLink.GetURL() );
lcl_OpenURL( sURL );
return 0;
}
@@ -1962,7 +1962,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData)
!= SvtExtendedSecurityOptions::OPEN_NEVER )
{
aMoreDictsLink.SetURL( String(
RTL_CONSTASCII_USTRINGPARAM( "http://extensions.libreoffice.org/dictionaries/" ) ) );
"http://extensions.libreoffice.org/dictionaries/" ) );
aMoreDictsLink.SetClickHdl( LINK( this, SvxEditModulesDlg, OpenURLHdl_Impl ) );
}
else
@@ -2405,7 +2405,7 @@ IMPL_LINK_NOARG(SvxEditModulesDlg, BackHdl_Impl)
IMPL_LINK_NOARG(SvxEditModulesDlg, OpenURLHdl_Impl)
{
::rtl::OUString sURL( aMoreDictsLink.GetURL() );
OUString sURL( aMoreDictsLink.GetURL() );
lcl_OpenURL( sURL );
return 0;
}
diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx
index d63081e..2ca777b 100644
--- a/cui/source/options/optpath.cxx
+++ b/cui/source/options/optpath.cxx
@@ -66,11 +66,11 @@ using namespace svx;
#define ITEMID_TYPE 1
#define ITEMID_PATH 2
#define POSTFIX_INTERNAL rtl::OUString("_internal")
#define POSTFIX_USER rtl::OUString("_user")
#define POSTFIX_WRITABLE rtl::OUString("_writable")
#define VAR_ONE rtl::OUString("%1")
#define IODLG_CONFIGNAME rtl::OUString("FilePicker_Save")
#define POSTFIX_INTERNAL OUString("_internal")
#define POSTFIX_USER OUString("_user")
#define POSTFIX_WRITABLE OUString("_writable")
#define VAR_ONE OUString("%1")
#define IODLG_CONFIGNAME OUString("FilePicker_Save")
// struct OptPath_Impl ---------------------------------------------------
@@ -133,7 +133,7 @@ static String getCfgName_Impl( sal_uInt16 _nHandle )
if ( Hdl2CfgMap_Impl[ nIndex ].m_nHandle == _nHandle )
{
// config name found
sCfgName = rtl::OUString::createFromAscii( Hdl2CfgMap_Impl[ nIndex ].m_pCfgName );
sCfgName = OUString::createFromAscii( Hdl2CfgMap_Impl[ nIndex ].m_pCfgName );
break;
}
++nIndex;
@@ -486,7 +486,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const String& _rFolder )
// old path is an URL?
INetURLObject aObj( sWritable );
bool bURL = ( aObj.GetProtocol() != INET_PROT_NOT_VALID );
rtl::OUString aPathStr( _rFolder );
OUString aPathStr( _rFolder );
INetURLObject aNewObj( aPathStr );
aNewObj.removeFinalSlash();
@@ -723,8 +723,7 @@ void SvxPathTabPage::GetPathList(
{
Reference< XMultiServiceFactory > xSMgr = comphelper::getProcessServiceFactory();
pImpl->m_xPathSettings = Reference< XPropertySet >( xSMgr->createInstance(
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.util.PathSettings") ) ), UNO_QUERY );
OUString( "com.sun.star.util.PathSettings" ) ), UNO_QUERY );
}
try
@@ -736,11 +735,11 @@ void SvxPathTabPage::GetPathList(
sProp = sCfgName;
sProp += POSTFIX_INTERNAL;
Any aAny = pImpl->m_xPathSettings->getPropertyValue( sProp );
Sequence< ::rtl::OUString > aPathSeq;
Sequence< OUString > aPathSeq;
if ( aAny >>= aPathSeq )
{
long i, nCount = aPathSeq.getLength();
const ::rtl::OUString* pPaths = aPathSeq.getConstArray();
const OUString* pPaths = aPathSeq.getConstArray();
for ( i = 0; i < nCount; ++i )
{
@@ -756,7 +755,7 @@ void SvxPathTabPage::GetPathList(
if ( aAny >>= aPathSeq )
{
long i, nCount = aPathSeq.getLength();
const ::rtl::OUString* pPaths = aPathSeq.getConstArray();
const OUString* pPaths = aPathSeq.getConstArray();
for ( i = 0; i < nCount; ++i )
{
@@ -769,7 +768,7 @@ void SvxPathTabPage::GetPathList(
sProp = sCfgName;
sProp += POSTFIX_WRITABLE;
aAny = pImpl->m_xPathSettings->getPropertyValue( sProp );
::rtl::OUString sWritablePath;
OUString sWritablePath;
if ( aAny >>= sWritablePath )
_rWritablePath = String( sWritablePath );
@@ -798,8 +797,7 @@ void SvxPathTabPage::SetPathList(
{
Reference< XMultiServiceFactory > xSMgr = comphelper::getProcessServiceFactory();
pImpl->m_xPathSettings = Reference< XPropertySet >( xSMgr->createInstance(
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.util.PathSettings") ) ), UNO_QUERY );
"com.sun.star.util.PathSettings" ), UNO_QUERY );
}
try
@@ -809,10 +807,10 @@ void SvxPathTabPage::SetPathList(
// save user paths
char cDelim = MULTIPATH_DELIMITER;
sal_uInt16 nCount = comphelper::string::getTokenCount(_rUserPath, cDelim);
Sequence< ::rtl::OUString > aPathSeq( nCount );
::rtl::OUString* pArray = aPathSeq.getArray();
Sequence< OUString > aPathSeq( nCount );
OUString* pArray = aPathSeq.getArray();
for ( sal_uInt16 i = 0; i < nCount; ++i )
pArray[i] = ::rtl::OUString( _rUserPath.GetToken( i, cDelim ) );
pArray[i] = OUString( _rUserPath.GetToken( i, cDelim ) );
String sProp( sCfgName );
sProp += POSTFIX_USER;
Any aValue = makeAny( aPathSeq );
diff --git a/cui/source/options/webconninfo.cxx b/cui/source/options/webconninfo.cxx
index 9046792..eb59b4e 100644
--- a/cui/source/options/webconninfo.cxx
+++ b/cui/source/options/webconninfo.cxx
@@ -170,8 +170,8 @@ void WebConnectionInfoDialog::FillPasswordList()
{
for ( sal_Int32 nUserInd = 0; nUserInd < aURLEntries[nURLInd].UserList.getLength(); nUserInd++ )
{
::rtl::OUString aUIEntry( aURLEntries[nURLInd].Url );
aUIEntry += ::rtl::OUString::valueOf( (sal_Unicode)'\t' );
OUString aUIEntry( aURLEntries[nURLInd].Url );
aUIEntry += OUString::valueOf( (sal_Unicode)'\t' );
aUIEntry += aURLEntries[nURLInd].UserList[nUserInd].UserName;
SvTreeListEntry* pEntry = m_pPasswordsLB->InsertEntry( aUIEntry );
pEntry->SetUserData( (void*)(sal_IntPtr)(nCount++) );
@@ -181,7 +181,7 @@ void WebConnectionInfoDialog::FillPasswordList()
// remember pos of first url container entry.
m_nPos = nCount;
uno::Sequence< rtl::OUString > aUrls
uno::Sequence< OUString > aUrls
= xMasterPasswd->getUrls( sal_True /* OnlyPersistent */ );
for ( sal_Int32 nURLIdx = 0; nURLIdx < aUrls.getLength(); nURLIdx++ )
@@ -241,7 +241,7 @@ IMPL_LINK_NOARG(WebConnectionInfoDialog, RemoveAllPasswordsHdl)
// should the master password be requested before?
xPasswdContainer->removeAllPersistent();
uno::Sequence< rtl::OUString > aUrls
uno::Sequence< OUString > aUrls
= xPasswdContainer->getUrls( sal_True /* OnlyPersistent */ );
for ( sal_Int32 nURLIdx = 0; nURLIdx < aUrls.getLength(); nURLIdx++ )
xPasswdContainer->removeUrl( aUrls[ nURLIdx ] );
@@ -277,7 +277,7 @@ IMPL_LINK_NOARG(WebConnectionInfoDialog, ChangePasswordHdl)
if ( pPasswordRequest->isPassword() )
{
String aNewPass = pPasswordRequest->getPassword();
uno::Sequence< ::rtl::OUString > aPasswd( 1 );
uno::Sequence< OUString > aPasswd( 1 );
aPasswd[0] = aNewPass;
uno::Reference< task::XPasswordContainer2 > xPasswdContainer(
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 8f451d6..6c5d2fb 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -726,7 +726,7 @@ IMPL_LINK_NOARG(OfaSwAutoFmtOptionsPage, EditHdl)
*pUserData->pFont = aFont;
sal_UCS4 aChar = pMapDlg->GetChar();
// using the UCS4 constructor
rtl::OUString aOUStr( &aChar, 1 );
OUString aOUStr( &aChar, 1 );
*pUserData->pString = aOUStr;
}
delete pMapDlg;
@@ -1323,7 +1323,7 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt)
aReplaceTLB.GetEntryText( pFirstSel, 1 ) );
if( bEnableNew )
{
for(std::set<rtl::OUString>::iterator i = aFormatText.begin(); i != aFormatText.end(); ++i)
for(std::set<OUString>::iterator i = aFormatText.begin(); i != aFormatText.end(); ++i)
{
if((*i).equals(rShortTxt))
{
@@ -1337,9 +1337,9 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt)
return 0;
}
static sal_Bool lcl_FindInArray(std::vector<rtl::OUString>& rStrings, const String& rString)
static sal_Bool lcl_FindInArray(std::vector<OUString>& rStrings, const String& rString)
{
for(std::vector<rtl::OUString>::iterator i = rStrings.begin(); i != rStrings.end(); ++i)
for(std::vector<OUString>::iterator i = rStrings.begin(); i != rStrings.end(); ++i)
{
if((*i).equals(rString))
{
@@ -1446,7 +1446,7 @@ sal_Bool OfaAutocorrExceptPage::FillItemSet( SfxItemSet& )
}
}
for(std::vector<rtl::OUString>::iterator it = rArrays.aDoubleCapsStrings.begin(); it != rArrays.aDoubleCapsStrings.end(); ++i)
for(std::vector<OUString>::iterator it = rArrays.aDoubleCapsStrings.begin(); it != rArrays.aDoubleCapsStrings.end(); ++i)
{
String* s = new String(*it);
if(!pWrdList->insert(s).second)
@@ -1471,7 +1471,7 @@ sal_Bool OfaAutocorrExceptPage::FillItemSet( SfxItemSet& )
}
}
for(std::vector<rtl::OUString>::iterator it = rArrays.aAbbrevStrings.begin(); it != rArrays.aAbbrevStrings.end(); ++it)
for(std::vector<OUString>::iterator it = rArrays.aAbbrevStrings.begin(); it != rArrays.aAbbrevStrings.end(); ++it)
{
String* s = new String(*it);
if(!pCplList->insert(s).second)
@@ -1580,10 +1580,10 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(sal_Bool bFromReset,
sal_uInt16 i;
for(i = 0; i < aAbbrevLB.GetEntryCount(); i++)
pArrays->aAbbrevStrings.push_back(rtl::OUString(aAbbrevLB.GetEntry(i)));
pArrays->aAbbrevStrings.push_back(OUString(aAbbrevLB.GetEntry(i)));
for(i = 0; i < aDoubleCapsLB.GetEntryCount(); i++)
pArrays->aDoubleCapsStrings.push_back(rtl::OUString(aDoubleCapsLB.GetEntry(i)));
pArrays->aDoubleCapsStrings.push_back(OUString(aDoubleCapsLB.GetEntry(i)));
}
aDoubleCapsLB.Clear();
aAbbrevLB.Clear();
@@ -1594,10 +1594,10 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(sal_Bool bFromReset,
if(aStringsTable.find(eLang) != aStringsTable.end())
{
StringsArrays& rArrays = aStringsTable[eLang];
for(std::vector<rtl::OUString>::iterator i = rArrays.aAbbrevStrings.begin(); i != rArrays.aAbbrevStrings.end(); ++i)
for(std::vector<OUString>::iterator i = rArrays.aAbbrevStrings.begin(); i != rArrays.aAbbrevStrings.end(); ++i)
aAbbrevLB.InsertEntry(*i);
for(std::vector<rtl::OUString>::iterator i = rArrays.aDoubleCapsStrings.begin(); i != rArrays.aDoubleCapsStrings.end(); ++i)
for(std::vector<OUString>::iterator i = rArrays.aDoubleCapsStrings.begin(); i != rArrays.aDoubleCapsStrings.end(); ++i)
aDoubleCapsLB.InsertEntry(*i);
}
else
@@ -2105,7 +2105,7 @@ String OfaQuoteTabPage::ChangeStringExt_Impl( sal_UCS4 cChar )
}
aStrCodes[ nFullLen++ ] = ')';
// using the new UCS4 constructor
rtl::OUString aOUStr( aStrCodes, nFullLen );
OUString aOUStr( aStrCodes, nFullLen );
return aOUStr;
}
@@ -2311,7 +2311,7 @@ void OfaAutoCompleteTabPage::CopyToClipboard() const
::com::sun::star::uno::Reference<
::com::sun::star::datatransfer::XTransferable > xRef( pCntnr );
rtl::OStringBuffer sData;
OStringBuffer sData;
const sal_Char aLineEnd[] =
#if defined(WNT)
"\015\012";
@@ -2323,7 +2323,7 @@ void OfaAutoCompleteTabPage::CopyToClipboard() const
for( sal_uInt16 n = 0; n < nSelCnt; ++n )
{
sData.append(rtl::OUStringToOString(aLBEntries.GetSelectEntry(n),
sData.append(OUStringToOString(aLBEntries.GetSelectEntry(n),
nEncode));
sData.append(RTL_CONSTASCII_STRINGPARAM(aLineEnd));
}
@@ -2395,11 +2395,11 @@ SfxTabPage* OfaSmartTagOptionsTabPage::Create( Window* pParent, const SfxItemSet
*/
struct ImplSmartTagLBUserData
{
rtl::OUString maSmartTagType;
OUString maSmartTagType;
uno::Reference< smarttags::XSmartTagRecognizer > mxRec;
sal_Int32 mnSmartTagIdx;
ImplSmartTagLBUserData( const rtl::OUString& rSmartTagType,
ImplSmartTagLBUserData( const OUString& rSmartTagType,
uno::Reference< smarttags::XSmartTagRecognizer > xRec,
sal_Int32 nSmartTagIdx ) :
maSmartTagType( rSmartTagType ),
@@ -2437,21 +2437,21 @@ void OfaSmartTagOptionsTabPage::FillListBox( const SmartTagMgr& rSmartTagMgr )
{
uno::Reference< smarttags::XSmartTagRecognizer > xRec = rSmartTagMgr.GetRecognizer(i);
const rtl::OUString aName = xRec->getName( aLocale );
const OUString aName = xRec->getName( aLocale );
const sal_Int32 nNumberOfSupportedSmartTags = xRec->getSmartTagCount();
for ( sal_Int32 j = 0; j < nNumberOfSupportedSmartTags; ++j )
{
const rtl::OUString aSmartTagType = xRec->getSmartTagName(j);
rtl::OUString aSmartTagCaption = rSmartTagMgr.GetSmartTagCaption( aSmartTagType, aLocale );
const OUString aSmartTagType = xRec->getSmartTagName(j);
OUString aSmartTagCaption = rSmartTagMgr.GetSmartTagCaption( aSmartTagType, aLocale );
if ( aSmartTagCaption.isEmpty() )
aSmartTagCaption = aSmartTagType;
const rtl::OUString aLBEntry = aSmartTagCaption +
OUString(RTL_CONSTASCII_USTRINGPARAM(" (")) +
const OUString aLBEntry = aSmartTagCaption +
OUString(" (") +
aName +
OUString(RTL_CONSTASCII_USTRINGPARAM(")"));
OUString(")");
SvTreeListEntry* pEntry = m_aSmartTagTypesLB.SvTreeListBox::InsertEntry( aLBEntry );
if ( pEntry )
@@ -2535,7 +2535,7 @@ sal_Bool OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& )
return sal_False;
sal_Bool bModifiedSmartTagTypes = sal_False;
std::vector< rtl::OUString > aDisabledSmartTagTypes;
std::vector< OUString > aDisabledSmartTagTypes;
const sal_uLong nCount = m_aSmartTagTypesLB.GetEntryCount();
diff --git a/dbaccess/source/ext/macromigration/macromigrationdialog.cxx b/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
index c4826fe..84c0ce8 100644
--- a/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
@@ -116,7 +116,7 @@ namespace dbmm
MigrationLog aLogger;
Reference< XOfficeDatabaseDocument > xDocument;
Reference< XModel2 > xDocumentModel;
::rtl::OUString sSuccessfulBackupLocation;
OUString sSuccessfulBackupLocation;
bool bMigrationIsRunning;
bool bMigrationFailure;
bool bMigrationSuccess;
@@ -398,7 +398,7 @@ namespace dbmm
{
bool lcl_equalURLs_nothrow(
const Reference< XComponentContext >& context,
const ::rtl::OUString& _lhs, const ::rtl::OUString _rhs )
const OUString& _lhs, const OUString _rhs )
{
// the cheap situation: the URLs are equal
if ( _lhs == _rhs )
@@ -432,7 +432,7 @@ namespace dbmm
return false;
SaveDBDocPage& rBackupPage = dynamic_cast< SaveDBDocPage& >( *GetPage( STATE_BACKUP_DBDOC ) );
::rtl::OUString sBackupLocation( rBackupPage.getBackupLocation() );
OUString sBackupLocation( rBackupPage.getBackupLocation() );
Any aError;
try
@@ -478,13 +478,13 @@ namespace dbmm
//--------------------------------------------------------------------
void MacroMigrationDialog::impl_reloadDocument_nothrow( bool _bMigrationSuccess )
{
typedef ::std::pair< Reference< XFrame >, ::rtl::OUString > ViewDescriptor;
typedef ::std::pair< Reference< XFrame >, OUString > ViewDescriptor;
::std::list< ViewDescriptor > aViews;
try
{
// the information which is necessary to reload the document
::rtl::OUString sDocumentURL ( m_pData->xDocumentModel->getURL() );
OUString sDocumentURL ( m_pData->xDocumentModel->getURL() );
::comphelper::NamedValueCollection aDocumentArgs( m_pData->xDocumentModel->getArgs() );
if ( !_bMigrationSuccess )
{
@@ -515,7 +515,7 @@ namespace dbmm
aControllers.pop_front();
Reference< XFrame > xFrame( xController->getFrame(), UNO_SET_THROW );
::rtl::OUString sViewName( xController->getViewControllerName() );
OUString sViewName( xController->getViewControllerName() );
if ( !xController->suspend( sal_True ) )
{ // ouch. There shouldn't be any modal dialogs and such, so there
@@ -547,7 +547,7 @@ namespace dbmm
aDocumentArgs.put( "ViewName", aView.second );
Reference< XInterface > xReloaded( xLoader->loadComponentFromURL(
sDocumentURL,
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "_self" ) ),
OUString( "_self" ),
0,
aDocumentArgs.getPropertyValues()
) );
diff --git a/dbaccess/source/ext/macromigration/macromigrationwizard.cxx b/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
index 33c64b7..b81e180 100644
--- a/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
@@ -73,8 +73,8 @@ namespace dbmm
virtual Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(RuntimeException);
// XServiceInfo
virtual ::rtl::OUString SAL_CALL getImplementationName() throw(RuntimeException);
virtual Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() throw(RuntimeException);
virtual OUString SAL_CALL getImplementationName() throw(RuntimeException);
virtual Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(RuntimeException);
// XInitialization
virtual void SAL_CALL initialize( const com::sun::star::uno::Sequence< com::sun::star::uno::Any >& aArguments ) throw(com::sun::star::uno::Exception, com::sun::star::uno::RuntimeException);
@@ -88,8 +88,8 @@ namespace dbmm
// helper for factories
static Reference< XInterface > SAL_CALL Create( const Reference< XComponentContext >& _rxContext );
static ::rtl::OUString SAL_CALL getImplementationName_static() throw(RuntimeException);
static Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames_static() throw(RuntimeException);
static OUString SAL_CALL getImplementationName_static() throw(RuntimeException);
static Sequence< OUString > SAL_CALL getSupportedServiceNames_static() throw(RuntimeException);
protected:
~MacroMigrationDialogService();
@@ -162,27 +162,27 @@ namespace dbmm
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL MacroMigrationDialogService::getImplementationName_static() throw(RuntimeException)
OUString SAL_CALL MacroMigrationDialogService::getImplementationName_static() throw(RuntimeException)
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dbaccess.macromigration.MacroMigrationDialogService" ) );
return OUString( "com.sun.star.comp.dbaccess.macromigration.MacroMigrationDialogService" );
}
//--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL MacroMigrationDialogService::getSupportedServiceNames_static() throw(RuntimeException)
Sequence< OUString > SAL_CALL MacroMigrationDialogService::getSupportedServiceNames_static() throw(RuntimeException)
{
Sequence< ::rtl::OUString > aServices(1);
aServices[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.application.MacroMigrationWizard" ) );
Sequence< OUString > aServices(1);
aServices[0] = OUString( "com.sun.star.sdb.application.MacroMigrationWizard" );
return aServices;
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL MacroMigrationDialogService::getImplementationName() throw(RuntimeException)
OUString SAL_CALL MacroMigrationDialogService::getImplementationName() throw(RuntimeException)
{
return getImplementationName_static();
}
//--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL MacroMigrationDialogService::getSupportedServiceNames() throw(RuntimeException)
Sequence< OUString > SAL_CALL MacroMigrationDialogService::getSupportedServiceNames() throw(RuntimeException)
{
return getSupportedServiceNames_static();
}
@@ -192,7 +192,7 @@ namespace dbmm
{
::osl::MutexGuard aGuard( m_aMutex );
if ( m_bInitialized )
throw AlreadyInitializedException( ::rtl::OUString(), *this );
throw AlreadyInitializedException( OUString(), *this );
if ( _rArguments.getLength() != 1 )
throw IllegalArgumentException(
diff --git a/dbaccess/source/ext/macromigration/migrationengine.cxx b/dbaccess/source/ext/macromigration/migrationengine.cxx
index 6f7f603..02d87f0 100644
--- a/dbaccess/source/ext/macromigration/migrationengine.cxx
+++ b/dbaccess/source/ext/macromigration/migrationengine.cxx
@@ -151,11 +151,11 @@ namespace dbmm
{
Reference< XCommandProcessor > xCommandProcessor;
Reference< XModel > xDocument; // valid only temporarily
::rtl::OUString sHierarchicalName;
OUString sHierarchicalName;
SubDocumentType eType;
size_t nNumber;
SubDocument( const Reference< XCommandProcessor >& _rxCommandProcessor, const ::rtl::OUString& _rName,
SubDocument( const Reference< XCommandProcessor >& _rxCommandProcessor, const OUString& _rName,
const SubDocumentType _eType, const size_t _nNumber )
:xCommandProcessor( _rxCommandProcessor )
,xDocument()
@@ -177,19 +177,19 @@ namespace dbmm
namespace
{
//----------------------------------------------------------------
static const ::rtl::OUString& lcl_getScriptsStorageName()
static const OUString& lcl_getScriptsStorageName()
{
static const ::rtl::OUString s_sScriptsStorageName( RTL_CONSTASCII_USTRINGPARAM( "Scripts" ) );
static const OUString s_sScriptsStorageName( "Scripts" );
return s_sScriptsStorageName;
}
//----------------------------------------------------------------
static const ::rtl::OUString& lcl_getScriptsSubStorageName( const ScriptType _eType )
static const OUString& lcl_getScriptsSubStorageName( const ScriptType _eType )
{
static const ::rtl::OUString s_sBeanShell ( RTL_CONSTASCII_USTRINGPARAM( "beanshell" ) );
static const ::rtl::OUString s_sJavaScript( RTL_CONSTASCII_USTRINGPARAM( "javascript" ) );
static const ::rtl::OUString s_sPython ( RTL_CONSTASCII_USTRINGPARAM( "python" ) ); // TODO: is this correct?
static const ::rtl::OUString s_sJava ( RTL_CONSTASCII_USTRINGPARAM( "java" ) );
static const OUString s_sBeanShell ( "beanshell" );
static const OUString s_sJavaScript( "javascript" );
static const OUString s_sPython ( "python" ); // TODO: is this correct?
static const OUString s_sJava ( "java" );
switch ( _eType )
{
@@ -202,12 +202,12 @@ namespace dbmm
}
OSL_FAIL( "lcl_getScriptsSubStorageName: illegal type!" );
static ::rtl::OUString s_sEmpty;
static OUString s_sEmpty;
return s_sEmpty;
}
//----------------------------------------------------------------
static bool lcl_getScriptTypeFromLanguage( const ::rtl::OUString& _rLanguage, ScriptType& _out_rScriptType )
static bool lcl_getScriptTypeFromLanguage( const OUString& _rLanguage, ScriptType& _out_rScriptType )
{
struct LanguageMapping
{
@@ -241,9 +241,9 @@ namespace dbmm
}
//----------------------------------------------------------------
::rtl::OUString lcl_getSubDocumentDescription( const SubDocument& _rDocument )
OUString lcl_getSubDocumentDescription( const SubDocument& _rDocument )
{
::rtl::OUString sObjectName(
OUString sObjectName(
MacroMigrationResId(
_rDocument.eType == eForm ? STR_FORM : STR_REPORT).toString().
replaceFirst("$name$", _rDocument.sHierarchicalName));
@@ -259,15 +259,15 @@ namespace dbmm
return Any();
Command aCommand;
aCommand.Name = ::rtl::OUString::createFromAscii( _pAsciiCommand );
aCommand.Name = OUString::createFromAscii( _pAsciiCommand );
return _rxCommandProc->execute(
aCommand, _rxCommandProc->createCommandIdentifier(), NULL );
}
//----------------------------------------------------------------
::rtl::OUString lcl_getMimeType_nothrow( const Reference< XCommandProcessor >& _rxContent )
OUString lcl_getMimeType_nothrow( const Reference< XCommandProcessor >& _rxContent )
{
::rtl::OUString sMimeType;
OUString sMimeType;
try
{
Reference< XContent > xContent( _rxContent, UNO_QUERY_THROW );
@@ -302,7 +302,7 @@ namespace dbmm
Reference< XCommandProcessor > xCommandProcessor( _rDocument.xCommandProcessor, UNO_SET_THROW );
Command aCommand;
aCommand.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "openDesign" ) );
aCommand.Name = OUString( "openDesign" );
aCommand.Argument <<= aLoadArgs.getPropertyValues();
Reference< XComponent > xDocComponent(
xCommandProcessor->execute(
@@ -619,7 +619,7 @@ namespace dbmm
/** returns the names of the elements in the "Scripts" storage
*/
::std::set< ::rtl::OUString >
::std::set< OUString >
getElementNames() const;
/** removes the sub storage for a given script type
@@ -717,7 +717,7 @@ namespace dbmm
if ( !isValid() )
return false;
const ::rtl::OUString& rSubStorageName( lcl_getScriptsSubStorageName( _eType ) );
const OUString& rSubStorageName( lcl_getScriptsSubStorageName( _eType ) );
return m_xScriptsStorage->hasByName( rSubStorageName )
&& m_xScriptsStorage->isStorageElement( rSubStorageName );
}
@@ -736,17 +736,17 @@ namespace dbmm
}
//--------------------------------------------------------------------
::std::set< ::rtl::OUString > ScriptsStorage::getElementNames() const
::std::set< OUString > ScriptsStorage::getElementNames() const
{
Sequence< ::rtl::OUString > aElementNames;
Sequence< OUString > aElementNames;
if ( isValid() )
aElementNames = m_xScriptsStorage->getElementNames();
::std::set< ::rtl::OUString > aNames;
::std::set< OUString > aNames;
::std::copy(
aElementNames.getConstArray(),
aElementNames.getConstArray() + aElementNames.getLength(),
::std::insert_iterator< ::std::set< ::rtl::OUString > >( aNames, aNames.end() )
::std::insert_iterator< ::std::set< OUString > >( aNames, aNames.end() )
);
return aNames;
}
@@ -754,7 +754,7 @@ namespace dbmm
//--------------------------------------------------------------------
void ScriptsStorage::removeScriptTypeStorage( const ScriptType _eType ) const
{
::rtl::OUString sSubStorageName( lcl_getScriptsSubStorageName( _eType ) );
OUString sSubStorageName( lcl_getScriptsSubStorageName( _eType ) );
if ( m_xScriptsStorage->hasByName( sSubStorageName ) )
m_xScriptsStorage->removeElement( sSubStorageName );
}
@@ -787,8 +787,8 @@ namespace dbmm
{
public:
ProgressDelegator( IMigrationProgress& _rDelegator,
const ::rtl::OUString& _rObjectName,
const ::rtl::OUString& _rAction
const OUString& _rObjectName,
const OUString& _rAction
)
:m_rDelegator( _rDelegator )
,m_sObjectName( _rObjectName )
@@ -815,8 +815,8 @@ namespace dbmm
private:
IMigrationProgress& m_rDelegator;
::rtl::OUString m_sObjectName;
::rtl::OUString m_sAction;
OUString m_sObjectName;
OUString m_sAction;
};
//====================================================================
@@ -929,9 +929,9 @@ namespace dbmm
*/
bool impl_adjustDialogEvents_nothrow(
Any& _inout_rDialogLibraryElement,
const ::rtl::OUString& _rDocName,
const ::rtl::OUString& _rDialogLibName,
const ::rtl::OUString& _rDialogName
const OUString& _rDocName,
const OUString& _rDialogLibName,
const OUString& _rDialogName
) const;
/** adjust the document-events which refer to macros/scripts in the document, taking into
@@ -960,8 +960,8 @@ namespace dbmm
if and only if adjustments to the script code have been made
*/
bool impl_adjustScriptLibrary_nothrow(
const ::rtl::OUString& _rScriptType,
::rtl::OUString& _inout_rScriptCode
const OUString& _rScriptType,
OUString& _inout_rScriptCode
) const;
bool impl_adjustScriptLibrary_nothrow( Any& _inout_rScriptDescriptor ) const;
@@ -975,7 +975,7 @@ namespace dbmm
bool impl_unprotectPasswordLibrary_throw(
const Reference< XLibraryContainerPassword >& _rxPasswordManager,
const ScriptType _eScriptType,
const ::rtl::OUString& _rLibraryName
const OUString& _rLibraryName
) const;
};
@@ -1016,9 +1016,9 @@ namespace dbmm
// initialize global progress
sal_Int32 nOverallRange( m_aSubDocs.size() );
rtl::OUString sProgressSkeleton(
OUString sProgressSkeleton(
MacroMigrationResId( STR_OVERALL_PROGRESS).toString().
replaceFirst("$overall$", rtl::OUString::valueOf(nOverallRange)));
replaceFirst("$overall$", OUString::valueOf(nOverallRange)));
m_rProgress.start( nOverallRange );
@@ -1029,9 +1029,9 @@ namespace dbmm
{
sal_Int32 nOverallProgressValue( doc - m_aSubDocs.begin() + 1 );
// update overall progress text
::rtl::OUString sOverallProgress(
OUString sOverallProgress(
sProgressSkeleton.replaceFirst("$current$",
::rtl::OUString::valueOf(nOverallProgressValue)));
OUString::valueOf(nOverallProgressValue)));
m_rProgress.setOverallProgressText( sOverallProgress );
// migrate document
@@ -1057,21 +1057,21 @@ namespace dbmm
namespace
{
void lcl_collectHierarchicalElementNames_throw(
const Reference< XNameAccess >& _rxContainer, const ::rtl::OUString& _rContainerLoc,
const Reference< XNameAccess >& _rxContainer, const OUString& _rContainerLoc,
SubDocuments& _out_rDocs, const SubDocumentType _eType, size_t& _io_counter )
{
const ::rtl::OUString sHierarhicalBase(
_rContainerLoc.isEmpty() ? ::rtl::OUString() :
::rtl::OUStringBuffer( _rContainerLoc ).appendAscii( "/" ).makeStringAndClear());
const OUString sHierarhicalBase(
_rContainerLoc.isEmpty() ? OUString() :
OUStringBuffer( _rContainerLoc ).appendAscii( "/" ).makeStringAndClear());
Sequence< ::rtl::OUString > aElementNames( _rxContainer->getElementNames() );
for ( const ::rtl::OUString* elementName = aElementNames.getConstArray();
Sequence< OUString > aElementNames( _rxContainer->getElementNames() );
for ( const OUString* elementName = aElementNames.getConstArray();
elementName != aElementNames.getConstArray() + aElementNames.getLength();
++elementName
)
{
Any aElement( _rxContainer->getByName( *elementName ) );
::rtl::OUString sElementName( sHierarhicalBase + *elementName );
OUString sElementName( sHierarhicalBase + *elementName );
Reference< XNameAccess > xSubContainer( aElement, UNO_QUERY );
if ( xSubContainer.is() )
@@ -1102,11 +1102,11 @@ namespace dbmm
{
Reference< XNameAccess > xDocContainer( m_xDocument->getFormDocuments(), UNO_SET_THROW );
m_nFormCount = 0;
lcl_collectHierarchicalElementNames_throw( xDocContainer, ::rtl::OUString(), m_aSubDocs, eForm, m_nFormCount );
lcl_collectHierarchicalElementNames_throw( xDocContainer, OUString(), m_aSubDocs, eForm, m_nFormCount );
xDocContainer.set( m_xDocument->getReportDocuments(), UNO_SET_THROW );
m_nReportCount = 0;
lcl_collectHierarchicalElementNames_throw( xDocContainer, ::rtl::OUString(), m_aSubDocs, eReport, m_nReportCount );
lcl_collectHierarchicalElementNames_throw( xDocContainer, OUString(), m_aSubDocs, eReport, m_nReportCount );
}
catch( const Exception& )
{
@@ -1127,12 +1127,12 @@ namespace dbmm
m_nCurrentDocumentID = m_rLogger.startedDocument( _rDocument.eType, _rDocument.sHierarchicalName );
// start the progress
::rtl::OUString sObjectName( lcl_getSubDocumentDescription( _rDocument ) );
m_rProgress.startObject( sObjectName, ::rtl::OUString(), DEFAULT_DOC_PROGRESS_RANGE );
OUString sObjectName( lcl_getSubDocumentDescription( _rDocument ) );
m_rProgress.startObject( sObjectName, OUString(), DEFAULT_DOC_PROGRESS_RANGE );
// -----------------
// load the document
::rtl::Reference< ProgressCapture > pStatusIndicator( new ProgressCapture( sObjectName, m_rProgress ) );
Reference< ProgressCapture > pStatusIndicator( new ProgressCapture( sObjectName, m_rProgress ) );
SubDocument aSubDocument( _rDocument );
OpenDocResult eResult = lcl_loadSubDocument_nothrow( aSubDocument, pStatusIndicator.get(), m_rLogger );
if ( eResult != eOpenedDoc )
@@ -1209,13 +1209,13 @@ namespace dbmm
//--------------------------------------------------------------------
namespace
{
static ::rtl::OUString lcl_createTargetLibName( const SubDocument& _rDocument,
const ::rtl::OUString& _rSourceLibName, const Reference< XNameAccess >& _rxTargetContainer )
static OUString lcl_createTargetLibName( const SubDocument& _rDocument,
const OUString& _rSourceLibName, const Reference< XNameAccess >& _rxTargetContainer )
{
// The new library name is composed from the prefix, the base name, and the old library name.
const ::rtl::OUString sPrefix = (_rDocument.eType == eForm)?rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Form_")): rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Report_"));
const OUString sPrefix = (_rDocument.eType == eForm)?OUString("Form_"): OUString("Report_");
::rtl::OUString sBaseName( _rDocument.sHierarchicalName.copy(
OUString sBaseName( _rDocument.sHierarchicalName.copy(
_rDocument.sHierarchicalName.lastIndexOf( '/' ) + 1 ) );
// Normalize this name. In our current storage implementation (and script containers in a document
// are finally mapped to sub storages of the document storage), not all characters are allowed.
@@ -1242,7 +1242,7 @@ namespace dbmm
}
if ( ( nInvalid <= 3 ) && ( nInvalid * 2 <= nValid ) )
{ // not "too many" invalid => replace them
::rtl::OUStringBuffer aReplacement;
OUStringBuffer aReplacement;
aReplacement.ensureCapacity( nBaseNameLen );
aReplacement.append( sBaseName );
const sal_Unicode* pReplacement = aReplacement.getStr();
@@ -1253,12 +1253,12 @@ namespace dbmm
}
sBaseName = aReplacement.makeStringAndClear();
::rtl::OUStringBuffer aNewLibNameAttempt;
OUStringBuffer aNewLibNameAttempt;
aNewLibNameAttempt.append( sPrefix );
aNewLibNameAttempt.append( sBaseName );
aNewLibNameAttempt.appendAscii( "_" );
aNewLibNameAttempt.append( _rSourceLibName );
::rtl::OUString sTargetName( aNewLibNameAttempt.makeStringAndClear() );
OUString sTargetName( aNewLibNameAttempt.makeStringAndClear() );
if ( !_rxTargetContainer->hasByName( sTargetName ) )
return sTargetName;
}
@@ -1267,9 +1267,9 @@ namespace dbmm
// (The latter is valid, since there can be multiple sub documents with the same base name,
// in different levels in the hierarchy.)
// In this case, just use the umambiguous sub document number.
::rtl::OUStringBuffer aNewLibName;
OUStringBuffer aNewLibName;
aNewLibName.append( sPrefix );
aNewLibName.append( ::rtl::OUString::valueOf( sal_Int64( _rDocument.nNumber ) ) );
aNewLibName.append( OUString::valueOf( sal_Int64( _rDocument.nNumber ) ) );
aNewLibName.appendAscii( "_" );
aNewLibName.append( _rSourceLibName );
return aNewLibName.makeStringAndClear();
@@ -1291,7 +1291,7 @@ namespace dbmm
{ // no scripts at all, or no scripts of the given type
return !m_rLogger.hadFailure();
}
::std::set< ::rtl::OUString > aElementNames( aDocStorage.getElementNames() );
::std::set< OUString > aElementNames( aDocStorage.getElementNames() );
ScriptType aKnownStorageBasedTypes[] = {
eBeanShell, eJavaScript, ePython, eJava
@@ -1353,13 +1353,13 @@ namespace dbmm
SharedStorage xScriptsRoot( aDocStorage.getScriptsRoot( _eScriptType ) );
if ( !xScriptsRoot.is() )
throw RuntimeException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "internal error" ) ), NULL );
throw RuntimeException( OUString( "internal error" ), NULL );
// loop through the script libraries
Sequence< ::rtl::OUString > aStorageElements( xScriptsRoot->getElementNames() );
Sequence< OUString > aStorageElements( xScriptsRoot->getElementNames() );
aPhase.start( _nPhaseID, aStorageElements.getLength() );
for ( const ::rtl::OUString* element = aStorageElements.getConstArray();
for ( const OUString* element = aStorageElements.getConstArray();
element != aStorageElements.getConstArray() + aStorageElements.getLength();
++element
)
@@ -1399,7 +1399,7 @@ namespace dbmm
}
// move the library to the DBDoc's scripts library, under the new name
::rtl::OUString sNewLibName( lcl_createTargetLibName( _rDocument, *element, xTargetStorage.getTyped().get() ) );
OUString sNewLibName( lcl_createTargetLibName( _rDocument, *element, xTargetStorage.getTyped().get() ) );
xScriptsRoot->moveElementTo( *element, xTargetStorage, sNewLibName );
// log the fact that we moved the library
@@ -1482,7 +1482,7 @@ namespace dbmm
OSL_ENSURE( xSourcePasswords.is(),
"MigrationEngine_Impl::impl_migrateContainerLibraries_nothrow: suspicious: no password management for the source libraries!" );
Sequence< ::rtl::OUString > aSourceLibNames( xSourceLibraries->getElementNames() );
Sequence< OUString > aSourceLibNames( xSourceLibraries->getElementNames() );
aPhase.start( _nPhaseID, aSourceLibNames.getLength() );
if ( !xSourceLibraries->hasElements() )
@@ -1506,9 +1506,9 @@ namespace dbmm
}
// copy all libs to the target, with potentially renaming them
const ::rtl::OUString* pSourceLibBegin = aSourceLibNames.getConstArray();
const ::rtl::OUString* pSourceLibEnd = pSourceLibBegin + aSourceLibNames.getLength();
for ( const ::rtl::OUString* pSourceLibName = pSourceLibBegin;
const OUString* pSourceLibBegin = aSourceLibNames.getConstArray();
const OUString* pSourceLibEnd = pSourceLibBegin + aSourceLibNames.getLength();
for ( const OUString* pSourceLibName = pSourceLibBegin;
pSourceLibName != pSourceLibEnd;
++pSourceLibName
)
@@ -1531,7 +1531,7 @@ namespace dbmm
}
}
::rtl::OUString sNewLibName( lcl_createTargetLibName( _rDocument, *pSourceLibName, xTargetLibraries.get() ) );
OUString sNewLibName( lcl_createTargetLibName( _rDocument, *pSourceLibName, xTargetLibraries.get() ) );
if ( xSourceLibraries->isLibraryLink( *pSourceLibName ) )
{
@@ -1551,8 +1551,8 @@ namespace dbmm
Reference< XNameAccess > xSourceLib( xSourceLibraries->getByName( *pSourceLibName ), UNO_QUERY_THROW );
Reference< XNameContainer > xTargetLib( xTargetLibraries->createLibrary( sNewLibName ), UNO_QUERY_THROW );
Sequence< ::rtl::OUString > aLibElementNames( xSourceLib->getElementNames() );
for ( const ::rtl::OUString* pSourceElementName = aLibElementNames.getConstArray();
Sequence< OUString > aLibElementNames( xSourceLib->getElementNames() );
for ( const OUString* pSourceElementName = aLibElementNames.getConstArray();
pSourceElementName != aLibElementNames.getConstArray() + aLibElementNames.getLength();
++pSourceElementName
)
@@ -1614,8 +1614,8 @@ namespace dbmm
}
//--------------------------------------------------------------------
bool MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow( const ::rtl::OUString& _rScriptType,
::rtl::OUString& _inout_rScriptCode ) const
bool MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow( const OUString& _rScriptType,
OUString& _inout_rScriptCode ) const
{
OSL_PRECOND( !_inout_rScriptCode.isEmpty(), "MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow: invalid script!" );
if ( _inout_rScriptCode.isEmpty() )
@@ -1640,8 +1640,7 @@ namespace dbmm
Reference< XUriReferenceFactory > xUriRefFac = UriReferenceFactory::create( m_aContext.getUNOContext() );
Reference< XVndSunStarScriptUrlReference > xUri( xUriRefFac->parse( _inout_rScriptCode ), UNO_QUERY_THROW );
::rtl::OUString sScriptLanguage = xUri->getParameter(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "language" ) ) );
OUString sScriptLanguage = xUri->getParameter( OUString( "language" ) );
ScriptType eScriptType = eBasic;
if ( !lcl_getScriptTypeFromLanguage( sScriptLanguage, eScriptType ) )
{
@@ -1654,15 +1653,14 @@ namespace dbmm
return false;
}
::rtl::OUString sLocation = xUri->getParameter(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "location" ) ) );
OUString sLocation = xUri->getParameter( OUString( "location" ) );
if ( sLocation != "document" )
{
// only document libraries must be migrated, of course
return false;
}
::rtl::OUString sScriptName = xUri->getName();
OUString sScriptName = xUri->getName();
sal_Int32 nLibModuleSeparator = sScriptName.indexOf( '.' );
if ( nLibModuleSeparator < 0 )
{
@@ -1676,13 +1674,13 @@ namespace dbmm
}
// replace the library name
::rtl::OUString sLibrary = sScriptName.copy( 0, nLibModuleSeparator );
::rtl::OUString sNewLibName = m_rLogger.getNewLibraryName(
OUString sLibrary = sScriptName.copy( 0, nLibModuleSeparator );
OUString sNewLibName = m_rLogger.getNewLibraryName(
m_nCurrentDocumentID, eScriptType, sLibrary );
OSL_ENSURE( sLibrary != sNewLibName,
"MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow: a library which has not been migrated?" );
::rtl::OUStringBuffer aNewLocation;
OUStringBuffer aNewLocation;
aNewLocation.append( sNewLibName );
aNewLocation.append( sScriptName.copy( nLibModuleSeparator ) );
xUri->setName( aNewLocation.makeStringAndClear() );
@@ -1724,8 +1722,8 @@ namespace dbmm
{
::comphelper::NamedValueCollection aScriptDesc( _inout_rScriptDescriptor );
::rtl::OUString sScriptType;
::rtl::OUString sScript;
OUString sScriptType;
OUString sScript;
try
{
OSL_VERIFY( aScriptDesc.get_ensureType( "EventType", sScriptType ) );
@@ -1759,10 +1757,10 @@ namespace dbmm
return true;
Reference< XNameReplace > xEvents( xSuppEvents->getEvents(), UNO_SET_THROW );
Sequence< ::rtl::OUString > aEventNames = xEvents->getElementNames();
Sequence< OUString > aEventNames = xEvents->getElementNames();
Any aEvent;
for ( const ::rtl::OUString* eventName = aEventNames.getConstArray();
for ( const OUString* eventName = aEventNames.getConstArray();
eventName != aEventNames.getConstArray() + aEventNames.getLength();
++eventName
)
@@ -1796,10 +1794,10 @@ namespace dbmm
{
Reference< XScriptEventsSupplier > xEventsSupplier( _rxElement, UNO_QUERY_THROW );
Reference< XNameReplace > xEvents( xEventsSupplier->getEvents(), UNO_QUERY_THROW );
Sequence< ::rtl::OUString > aEventNames( xEvents->getElementNames() );
Sequence< OUString > aEventNames( xEvents->getElementNames() );
const ::rtl::OUString* eventName = aEventNames.getArray();
const ::rtl::OUString* eventNamesEnd = eventName + aEventNames.getLength();
const OUString* eventName = aEventNames.getArray();
const OUString* eventNamesEnd = eventName + aEventNames.getLength();
ScriptEventDescriptor aScriptEvent;
for ( ; eventName != eventNamesEnd; ++eventName )
@@ -1815,7 +1813,7 @@ namespace dbmm
//--------------------------------------------------------------------
bool MigrationEngine_Impl::impl_adjustDialogEvents_nothrow( Any& _inout_rDialogLibraryElement,
const ::rtl::OUString& _rDocName, const ::rtl::OUString& _rDialogLibName, const ::rtl::OUString& _rDialogName ) const
const OUString& _rDocName, const OUString& _rDialogLibName, const OUString& _rDialogName ) const
{
try
{
@@ -1830,9 +1828,9 @@ namespace dbmm
impl_adjustDialogElementEvents_throw( xDialogModel );
// adjust the events of the controls
Sequence< ::rtl::OUString > aControlNames( xDialogModel->getElementNames() );
const ::rtl::OUString* controlName = aControlNames.getConstArray();
const ::rtl::OUString* controlNamesEnd = controlName + aControlNames.getLength();
Sequence< OUString > aControlNames( xDialogModel->getElementNames() );
const OUString* controlName = aControlNames.getConstArray();
const OUString* controlNamesEnd = controlName + aControlNames.getLength();
for ( ; controlName != controlNamesEnd; ++controlName )
{
impl_adjustDialogElementEvents_throw( Reference< XInterface >( xDialogModel->getByName( *controlName ), UNO_QUERY ) );
@@ -1915,10 +1913,10 @@ namespace dbmm
//--------------------------------------------------------------------
bool MigrationEngine_Impl::impl_unprotectPasswordLibrary_throw( const Reference< XLibraryContainerPassword >& _rxPasswordManager,
const ScriptType _eScriptType, const ::rtl::OUString& _rLibraryName ) const
const ScriptType _eScriptType, const OUString& _rLibraryName ) const
{
// a human-readable description of the affected library
::rtl::OUString sLibraryDescription(
OUString sLibraryDescription(
MacroMigrationResId(STR_LIBRARY_TYPE_AND_NAME).toString().
replaceFirst("$type$",
getScriptTypeDisplayName(_eScriptType)).
@@ -1928,7 +1926,7 @@ namespace dbmm
// replaceFirst
InteractionHandler aHandler( m_aContext, m_xDocumentModel );
::rtl::OUString sPassword;
OUString sPassword;
while ( true )
{
if ( !aHandler.requestDocumentPassword( sLibraryDescription, sPassword ) )
diff --git a/dbaccess/source/ext/macromigration/migrationlog.cxx b/dbaccess/source/ext/macromigration/migrationlog.cxx
index 18a5d7d..647f633 100644
--- a/dbaccess/source/ext/macromigration/migrationlog.cxx
+++ b/dbaccess/source/ext/macromigration/migrationlog.cxx
@@ -46,8 +46,8 @@ namespace dbmm
struct LibraryEntry
{
ScriptType eType;
::rtl::OUString sOldName;
::rtl::OUString sNewName;
OUString sOldName;
OUString sNewName;
LibraryEntry()
:eType( eBasic )
@@ -56,7 +56,7 @@ namespace dbmm
{
}
LibraryEntry( const ScriptType& _eType, const ::rtl::OUString& _rOldName, const ::rtl::OUString& _rNewName )
LibraryEntry( const ScriptType& _eType, const OUString& _rOldName, const OUString& _rNewName )
:eType( _eType )
,sOldName( _rOldName )
,sNewName( _rNewName )
@@ -70,7 +70,7 @@ namespace dbmm
struct DocumentEntry
{
SubDocumentType eType;
::rtl::OUString sName;
OUString sName;
::std::vector< LibraryEntry > aMovedLibraries;
DocumentEntry()
@@ -80,7 +80,7 @@ namespace dbmm
{
}
DocumentEntry( const SubDocumentType _eType, const ::rtl::OUString& _rName )
DocumentEntry( const SubDocumentType _eType, const OUString& _rName )
:eType( _eType )
,sName( _rName )
{
@@ -102,7 +102,7 @@ namespace dbmm
//====================================================================
struct MigrationLog_Data
{
::rtl::OUString sBackupLocation;
OUString sBackupLocation;
DocumentLogs aDocumentLogs;
ErrorLog aFailures;
ErrorLog aWarnings;
@@ -141,13 +141,13 @@ namespace dbmm
}
//--------------------------------------------------------------------
void MigrationLog::backedUpDocument( const ::rtl::OUString& _rNewDocumentLocation )
void MigrationLog::backedUpDocument( const OUString& _rNewDocumentLocation )
{
m_pData->sBackupLocation = _rNewDocumentLocation;
}
//--------------------------------------------------------------------
DocumentID MigrationLog::startedDocument( const SubDocumentType _eType, const ::rtl::OUString& _rName )
DocumentID MigrationLog::startedDocument( const SubDocumentType _eType, const OUString& _rName )
{
#if OSL_DEBUG_LEVEL > 0
bool bAlreadyKnown = false;
@@ -172,7 +172,7 @@ namespace dbmm
//--------------------------------------------------------------------
void MigrationLog::movedLibrary( const DocumentID _nDocID, const ScriptType _eScriptType,
const ::rtl::OUString& _rOriginalLibName, const ::rtl::OUString& _rNewLibName )
const OUString& _rOriginalLibName, const OUString& _rNewLibName )
{
OSL_ENSURE( m_pData->aDocumentLogs.find( _nDocID ) != m_pData->aDocumentLogs.end(),
"MigrationLog::movedLibrary: document is not known!" );
@@ -193,10 +193,10 @@ namespace dbmm
}
//--------------------------------------------------------------------
const ::rtl::OUString& MigrationLog::getNewLibraryName( DocumentID _nDocID, ScriptType _eScriptType,
const ::rtl::OUString& _rOriginalLibName ) const
const OUString& MigrationLog::getNewLibraryName( DocumentID _nDocID, ScriptType _eScriptType,
const OUString& _rOriginalLibName ) const
{
static ::rtl::OUString s_sEmptyString;
static OUString s_sEmptyString;
DocumentLogs::const_iterator docPos = m_pData->aDocumentLogs.find( _nDocID );
if ( docPos == m_pData->aDocumentLogs.end() )
@@ -225,28 +225,25 @@ namespace dbmm
namespace
{
//----------------------------------------------------------------
static void lcl_appendErrorDescription( ::rtl::OUStringBuffer& _inout_rBuffer, const MigrationError& _rError )
static void lcl_appendErrorDescription( OUStringBuffer& _inout_rBuffer, const MigrationError& _rError )
{
const sal_Char* pAsciiErrorDescription( NULL );
::std::vector< rtl::OUString > aParameterNames;
::std::vector< OUString > aParameterNames;
switch ( _rError.eType )
{
case ERR_OPENING_SUB_DOCUMENT_FAILED:
pAsciiErrorDescription = "opening '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_CLOSING_SUB_DOCUMENT_FAILED:
pAsciiErrorDescription = "closing '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_STORAGE_COMMIT_FAILED:
pAsciiErrorDescription = "committing the changes for document '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_STORING_DATABASEDOC_FAILED:
@@ -259,66 +256,52 @@ namespace dbmm
case ERR_UNEXPECTED_LIBSTORAGE_ELEMENT:
pAsciiErrorDescription = "unexpected #lib# storage element in document '#doc#', named '#element#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#libstore#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#element#")));
aParameterNames.push_back(OUString("#doc#"));
aParameterNames.push_back(OUString("#libstore#"));
aParameterNames.push_back(OUString("#element#"));
break;
case ERR_CREATING_DBDOC_SCRIPT_STORAGE_FAILED:
pAsciiErrorDescription = "creating the database document's storage for #scripttype# scripts failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#scripttype#")));
aParameterNames.push_back(OUString("#scripttype#"));
break;
case ERR_COMMITTING_SCRIPT_STORAGES_FAILED:
pAsciiErrorDescription = "saving the #scripttype# scripts for document '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#scripttype#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#scripttype#"));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_GENERAL_SCRIPT_MIGRATION_FAILURE:
pAsciiErrorDescription = "general error while migrating #scripttype# scripts of document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#scripttype#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#scripttype#"));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_GENERAL_MACRO_MIGRATION_FAILURE:
pAsciiErrorDescription = "general error during macro migration of document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_UNKNOWN_SCRIPT_TYPE:
pAsciiErrorDescription = "unknown script type: #type#";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#type#")));
aParameterNames.push_back(OUString("#type#"));
break;
case ERR_UNKNOWN_SCRIPT_LANGUAGE:
pAsciiErrorDescription = "unknown script language: #lang#";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#lang#")));
aParameterNames.push_back(OUString("#lang#"));
break;
case ERR_UNKNOWN_SCRIPT_NAME_FORMAT:
pAsciiErrorDescription = "unknown script name format: #script#";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#script#")));
aParameterNames.push_back(OUString("#script#"));
break;
case ERR_SCRIPT_TRANSLATION_FAILURE:
pAsciiErrorDescription = "analyzing/translating the script URL failed; script type: #type#; script: #code#";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#type#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#code#")));
aParameterNames.push_back(OUString("#type#"));
aParameterNames.push_back(OUString("#code#"));
break;
case ERR_INVALID_SCRIPT_DESCRIPTOR_FORMAT:
@@ -327,72 +310,57 @@ namespace dbmm
case ERR_ADJUSTING_DOCUMENT_EVENTS_FAILED:
pAsciiErrorDescription = "adjusting events for document '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_ADJUSTING_DIALOG_EVENTS_FAILED:
pAsciiErrorDescription = "adjusting events for dialog #lib#.#dlg# in document '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#lib#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#dlg#")));
aParameterNames.push_back(OUString("#doc#"));
aParameterNames.push_back(OUString("#lib#"));
aParameterNames.push_back(OUString("#dlg#"));
break;
case ERR_ADJUSTING_FORMCOMP_EVENTS_FAILED:
pAsciiErrorDescription = "adjusting form component events for '#doc#' failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_BIND_SCRIPT_STORAGE_FAILED:
pAsciiErrorDescription = "binding to the script storage failed for document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_REMOVE_SCRIPTS_STORAGE_FAILED:
pAsciiErrorDescription = "removing a scripts storage failed for document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_DOCUMENT_BACKUP_FAILED:
pAsciiErrorDescription = "backing up the document to #location# failed";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#location#")));
aParameterNames.push_back(OUString("#location#"));
break;
case ERR_UNKNOWN_SCRIPT_FOLDER:
pAsciiErrorDescription = "unknown script folder '#name#' in document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#name#")));
aParameterNames.push_back(OUString("#doc#"));
aParameterNames.push_back(OUString("#name#"));
break;
case ERR_EXAMINING_SCRIPTS_FOLDER_FAILED:
pAsciiErrorDescription = "examining the 'Scripts' folder failed for document '#doc#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
case ERR_PASSWORD_VERIFICATION_FAILED:
pAsciiErrorDescription = "password verification failed for document '#doc#', #libtype# library '#name#'";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#libtype#")));
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#name#")));
aParameterNames.push_back(OUString("#doc#"));
aParameterNames.push_back(OUString("#libtype#"));
aParameterNames.push_back(OUString("#name#"));
break;
case ERR_NEW_STYLE_REPORT:
pAsciiErrorDescription = "#doc# could not be processed, since you don't have the Oracle Report Builder (TM) extension installed.";
aParameterNames.push_back(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("#doc#")));
aParameterNames.push_back(OUString("#doc#"));
break;
// do *not* add a default case here: Without a default, some compilers will warn you when
@@ -401,7 +369,7 @@ namespace dbmm
OSL_ENSURE( pAsciiErrorDescription, "lcl_appendErrorDescription: no error message!" );
if ( pAsciiErrorDescription )
{
::rtl::OUString sSubstituted( ::rtl::OUString::createFromAscii( pAsciiErrorDescription ) );
OUString sSubstituted( OUString::createFromAscii( pAsciiErrorDescription ) );
OSL_ENSURE( aParameterNames.size() == _rError.aErrorDetails.size(),
"lcl_appendErrorDescription: unexpected number of error message parameters!" );
@@ -416,7 +384,7 @@ namespace dbmm
}
//----------------------------------------------------------------
void lcl_describeErrors( ::rtl::OUStringBuffer& _rBuffer, const ErrorLog& _rErrors, const sal_uInt16 _nHeadingResId )
void lcl_describeErrors( OUStringBuffer& _rBuffer, const ErrorLog& _rErrors, const sal_uInt16 _nHeadingResId )
{
_rBuffer.appendAscii( "=== " );
_rBuffer.append ( String( MacroMigrationResId( _nHeadingResId ) ) );
@@ -458,9 +426,9 @@ namespace dbmm
}
//--------------------------------------------------------------------
::rtl::OUString MigrationLog::getCompleteLog() const
OUString MigrationLog::getCompleteLog() const
{
::rtl::OUStringBuffer aBuffer;
OUStringBuffer aBuffer;
if ( !m_pData->sBackupLocation.isEmpty() )
{
diff --git a/dbaccess/source/filter/xml/dbloader2.cxx b/dbaccess/source/filter/xml/dbloader2.cxx
index a7c4833..be6a5a4 100644
--- a/dbaccess/source/filter/xml/dbloader2.cxx
+++ b/dbaccess/source/filter/xml/dbloader2.cxx
@@ -102,20 +102,20 @@ public:
DBTypeDetection(const Reference< XMultiServiceFactory >&);
// XServiceInfo
::rtl::OUString SAL_CALL getImplementationName() throw( );
sal_Bool SAL_CALL supportsService(const ::rtl::OUString& ServiceName) throw( );
Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(void) throw( );
OUString SAL_CALL getImplementationName() throw( );
sal_Bool SAL_CALL supportsService(const OUString& ServiceName) throw( );
Sequence< OUString > SAL_CALL getSupportedServiceNames(void) throw( );
// static methods
static ::rtl::OUString getImplementationName_Static() throw( )
static OUString getImplementationName_Static() throw( )
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbflt.DBTypeDetection"));
return OUString("org.openoffice.comp.dbflt.DBTypeDetection");
}
static Sequence< ::rtl::OUString> getSupportedServiceNames_Static(void) throw( );
static Sequence< OUString> getSupportedServiceNames_Static(void) throw( );
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
SAL_CALL Create(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >&);
virtual ::rtl::OUString SAL_CALL detect( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& Descriptor ) throw (::com::sun::star::uno::RuntimeException);
virtual OUString SAL_CALL detect( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& Descriptor ) throw (::com::sun::star::uno::RuntimeException);
};
// -------------------------------------------------------------------------
DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFactory)
@@ -123,13 +123,13 @@ DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFac
{
}
// -------------------------------------------------------------------------
::rtl::OUString SAL_CALL DBTypeDetection::detect( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& Descriptor ) throw (::com::sun::star::uno::RuntimeException)
OUString SAL_CALL DBTypeDetection::detect( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& Descriptor ) throw (::com::sun::star::uno::RuntimeException)
{
try
{
::comphelper::NamedValueCollection aMedia( Descriptor );
sal_Bool bStreamFromDescr = sal_False;
::rtl::OUString sURL = aMedia.getOrDefault( "URL", ::rtl::OUString() );
OUString sURL = aMedia.getOrDefault( "URL", OUString() );
Reference< XInputStream > xInStream( aMedia.getOrDefault( "InputStream", Reference< XInputStream >() ) );
Reference< XPropertySet > xStorageProperties;
@@ -141,9 +141,9 @@ DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFac
}
else
{
::rtl::OUString sSalvagedURL( aMedia.getOrDefault( "SalvagedFile", ::rtl::OUString() ) );
OUString sSalvagedURL( aMedia.getOrDefault( "SalvagedFile", OUString() ) );
::rtl::OUString sFileLocation( sSalvagedURL.isEmpty() ? sURL : sSalvagedURL );
OUString sFileLocation( sSalvagedURL.isEmpty() ? sURL : sSalvagedURL );
if ( !sFileLocation.isEmpty() )
{
xStorageProperties.set( ::comphelper::OStorageHelper::GetStorageFromURL(
@@ -153,16 +153,16 @@ DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFac
if ( xStorageProperties.is() )
{
::rtl::OUString sMediaType;
OUString sMediaType;
xStorageProperties->getPropertyValue( INFO_MEDIATYPE ) >>= sMediaType;
if ( sMediaType == MIMETYPE_OASIS_OPENDOCUMENT_DATABASE_ASCII || sMediaType == MIMETYPE_VND_SUN_XML_BASE_ASCII )
{
if ( bStreamFromDescr && sURL.compareTo( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "private:stream" ) ), 14 ) != COMPARE_EQUAL )
if ( bStreamFromDescr && sURL.compareTo( OUString( "private:stream" ), 14 ) != COMPARE_EQUAL )
{
// After fixing of the i88522 issue ( use the new file locking for database files ) the stream from the type detection can be used further
// for now the file should be reopened to have read/write access
aMedia.remove( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "InputStream" ) ) );
aMedia.remove( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Stream" ) ) );
aMedia.remove( OUString( "InputStream" ) );
aMedia.remove( OUString( "Stream" ) );
aMedia >>= Descriptor;
try
{
@@ -176,12 +176,12 @@ DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFac
}
}
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("StarBase"));
return OUString("StarBase");
}
::comphelper::disposeComponent(xStorageProperties);
}
} catch(Exception&){}
return ::rtl::OUString();
return OUString();
}
// -------------------------------------------------------------------------
Reference< XInterface > SAL_CALL DBTypeDetection::Create( const Reference< XMultiServiceFactory > & rSMgr )
@@ -190,18 +190,18 @@ Reference< XInterface > SAL_CALL DBTypeDetection::Create( const Reference< XMult
}
// -------------------------------------------------------------------------
// XServiceInfo
::rtl::OUString SAL_CALL DBTypeDetection::getImplementationName() throw( )
OUString SAL_CALL DBTypeDetection::getImplementationName() throw( )
{
return getImplementationName_Static();
}
// -------------------------------------------------------------------------
// XServiceInfo
sal_Bool SAL_CALL DBTypeDetection::supportsService(const ::rtl::OUString& ServiceName) throw( )
sal_Bool SAL_CALL DBTypeDetection::supportsService(const OUString& ServiceName) throw( )
{
Sequence< ::rtl::OUString > aSNL = getSupportedServiceNames();
const ::rtl::OUString * pBegin = aSNL.getConstArray();
const ::rtl::OUString * pEnd = pBegin + aSNL.getLength();
Sequence< OUString > aSNL = getSupportedServiceNames();
const OUString * pBegin = aSNL.getConstArray();
const OUString * pEnd = pBegin + aSNL.getLength();
for( ; pBegin != pEnd; ++pBegin)
if( *pBegin == ServiceName )
return sal_True;
@@ -209,16 +209,16 @@ sal_Bool SAL_CALL DBTypeDetection::supportsService(const ::rtl::OUString& Servic
}
// -------------------------------------------------------------------------
// XServiceInfo
Sequence< ::rtl::OUString > SAL_CALL DBTypeDetection::getSupportedServiceNames(void) throw( )
Sequence< OUString > SAL_CALL DBTypeDetection::getSupportedServiceNames(void) throw( )
{
return getSupportedServiceNames_Static();
}
// -------------------------------------------------------------------------
// ORegistryServiceManager_Static
Sequence< ::rtl::OUString > DBTypeDetection::getSupportedServiceNames_Static(void) throw( )
Sequence< OUString > DBTypeDetection::getSupportedServiceNames_Static(void) throw( )
{
Sequence< ::rtl::OUString > aSNS( 1 );
aSNS.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExtendedTypeDetection"));
Sequence< OUString > aSNS( 1 );
aSNS.getArray()[0] = OUString("com.sun.star.document.ExtendedTypeDetection");
return aSNS;
}
// -------------------------------------------------------------------------
@@ -233,7 +233,7 @@ class DBContentLoader : public ::cppu::WeakImplHelper2< XFrameLoader, XServiceIn
private:
::comphelper::ComponentContext m_aContext;
Reference< XFrameLoader > m_xMySelf;
::rtl::OUString m_sCurrentURL;
OUString m_sCurrentURL;
sal_uLong m_nStartWizard;
DECL_LINK( OnStartTableWizard, void* );
@@ -242,21 +242,21 @@ public:
~DBContentLoader();
// XServiceInfo
::rtl::OUString SAL_CALL getImplementationName() throw( );
sal_Bool SAL_CALL supportsService(const ::rtl::OUString& ServiceName) throw( );
Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(void) throw( );
OUString SAL_CALL getImplementationName() throw( );
sal_Bool SAL_CALL supportsService(const OUString& ServiceName) throw( );
Sequence< OUString > SAL_CALL getSupportedServiceNames(void) throw( );
// static methods
static ::rtl::OUString getImplementationName_Static() throw( )
static OUString getImplementationName_Static() throw( )
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbflt.DBContentLoader2"));
return OUString("org.openoffice.comp.dbflt.DBContentLoader2");
}
static Sequence< ::rtl::OUString> getSupportedServiceNames_Static(void) throw( );
static Sequence< OUString > getSupportedServiceNames_Static(void) throw( );
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
SAL_CALL Create(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >&);
// XLoader
virtual void SAL_CALL load( const Reference< XFrame > & _rFrame, const ::rtl::OUString& _rURL,
virtual void SAL_CALL load( const Reference< XFrame > & _rFrame, const OUString& _rURL,
const Sequence< PropertyValue >& _rArgs,
const Reference< XLoadEventListener > & _rListener) throw(::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL cancel(void) throw();
@@ -289,18 +289,18 @@ Reference< XInterface > SAL_CALL DBContentLoader::Create( const Reference< XMult
}
// -------------------------------------------------------------------------
// XServiceInfo
::rtl::OUString SAL_CALL DBContentLoader::getImplementationName() throw( )
OUString SAL_CALL DBContentLoader::getImplementationName() throw( )
{
return getImplementationName_Static();
}
// -------------------------------------------------------------------------
// XServiceInfo
sal_Bool SAL_CALL DBContentLoader::supportsService(const ::rtl::OUString& ServiceName) throw( )
sal_Bool SAL_CALL DBContentLoader::supportsService(const OUString& ServiceName) throw( )
{
Sequence< ::rtl::OUString > aSNL = getSupportedServiceNames();
const ::rtl::OUString * pBegin = aSNL.getConstArray();
const ::rtl::OUString * pEnd = pBegin + aSNL.getLength();
Sequence< OUString > aSNL = getSupportedServiceNames();
const OUString * pBegin = aSNL.getConstArray();
const OUString * pEnd = pBegin + aSNL.getLength();
for( ; pBegin != pEnd; ++pBegin)
if( *pBegin == ServiceName )
return sal_True;
@@ -308,16 +308,16 @@ sal_Bool SAL_CALL DBContentLoader::supportsService(const ::rtl::OUString& Servic
}
// -------------------------------------------------------------------------
// XServiceInfo
Sequence< ::rtl::OUString > SAL_CALL DBContentLoader::getSupportedServiceNames(void) throw( )
Sequence< OUString > SAL_CALL DBContentLoader::getSupportedServiceNames(void) throw( )
{
return getSupportedServiceNames_Static();
}
// -------------------------------------------------------------------------
// ORegistryServiceManager_Static
Sequence< ::rtl::OUString > DBContentLoader::getSupportedServiceNames_Static(void) throw( )
Sequence< OUString > DBContentLoader::getSupportedServiceNames_Static(void) throw( )
{
Sequence< ::rtl::OUString > aSNS( 1 );
aSNS.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.FrameLoader"));
Sequence< OUString > aSNS( 1 );
aSNS.getArray()[0] = OUString("com.sun.star.frame.FrameLoader");
return aSNS;
}
@@ -325,7 +325,7 @@ Sequence< ::rtl::OUString > DBContentLoader::getSupportedServiceNames_Static(voi
namespace
{
// ...................................................................
sal_Bool lcl_urlAllowsInteraction( const ::comphelper::ComponentContext& _rContext, const ::rtl::OUString& _rURL )
sal_Bool lcl_urlAllowsInteraction( const ::comphelper::ComponentContext& _rContext, const OUString& _rURL )
{
bool bDoesAllow = sal_False;
try
@@ -369,13 +369,13 @@ sal_Bool DBContentLoader::impl_executeNewDatabaseWizard( Reference< XModel >& _r
{
Sequence< Any > aWizardArgs(2);
aWizardArgs[0] <<= PropertyValue(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ParentWindow")),
OUString("ParentWindow"),
0,
makeAny( lcl_getTopMostWindow( m_aContext.getUNOContext() ) ),
PropertyState_DIRECT_VALUE);
aWizardArgs[1] <<= PropertyValue(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InitialSelection")),
OUString("InitialSelection"),
0,
makeAny( _rxModel ),
PropertyState_DIRECT_VALUE);
@@ -390,13 +390,13 @@ sal_Bool DBContentLoader::impl_executeNewDatabaseWizard( Reference< XModel >& _r
Reference<XPropertySet> xProp(xAdminDialog,UNO_QUERY);
sal_Bool bSuccess = sal_False;
xProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OpenDatabase"))) >>= bSuccess;
xProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("StartTableWizard"))) >>= _bShouldStartTableWizard;
xProp->getPropertyValue(OUString("OpenDatabase")) >>= bSuccess;
xProp->getPropertyValue(OUString("StartTableWizard")) >>= _bShouldStartTableWizard;
return bSuccess;
}
// -----------------------------------------------------------------------
void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::rtl::OUString& _rURL,
void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const OUString& _rURL,
const Sequence< PropertyValue >& rArgs,
const Reference< XLoadEventListener > & rListener) throw(::com::sun::star::uno::RuntimeException)
{
@@ -411,7 +411,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
}
Reference< XModel > xModel = aMediaDesc.getOrDefault( "Model", Reference< XModel >() );
::rtl::OUString sSalvagedURL = aMediaDesc.getOrDefault( "SalvagedFile", _rURL );
OUString sSalvagedURL = aMediaDesc.getOrDefault( "SalvagedFile", _rURL );
sal_Bool bCreateNew = sal_False; // does the URL denote the private:factory URL?
sal_Bool bStartTableWizard = sal_False; // start the table wizard after everything was loaded successfully?
@@ -436,7 +436,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
aMediaDesc.remove( "Model" );
// also, it's allowed to specify the type of view which should be created
::rtl::OUString sViewName = aMediaDesc.getOrDefault( "ViewName", ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Default" ) ) );
OUString sViewName = aMediaDesc.getOrDefault( "ViewName", OUString( "Default" ) );
aMediaDesc.remove( "ViewName" );
sal_Int32 nInitialSelection = -1;
@@ -444,7 +444,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
{
Reference< XDatabaseContext > xDatabaseContext( DatabaseContext::create(m_aContext.getUNOContext()) );
::rtl::OUString sFactoryName = SvtModuleOptions().GetFactoryEmptyDocumentURL(SvtModuleOptions::E_DATABASE);
OUString sFactoryName = SvtModuleOptions().GetFactoryEmptyDocumentURL(SvtModuleOptions::E_DATABASE);
bCreateNew = sFactoryName.match(_rURL);
Reference< XDocumentDataSource > xDocumentDataSource;
@@ -457,7 +457,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
else
{
::comphelper::NamedValueCollection aCreationArgs;
aCreationArgs.put( (::rtl::OUString)INFO_POOLURL, sSalvagedURL );
aCreationArgs.put( (OUString)INFO_POOLURL, sSalvagedURL );
xDocumentDataSource.set( xDatabaseContext->createInstanceWithArguments( aCreationArgs.getWrappedNamedValues() ), UNO_QUERY_THROW );
}
@@ -593,14 +593,14 @@ IMPL_LINK( DBContentLoader, OnStartTableWizard, void*, /*NOTINTERESTEDIN*/ )
{
Sequence< Any > aWizArgs(1);
PropertyValue aValue;
aValue.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DatabaseLocation"));
aValue.Name = OUString("DatabaseLocation");
aValue.Value <<= m_sCurrentURL;
aWizArgs[0] <<= aValue;
SolarMutexGuard aGuard;
Reference< XJobExecutor > xTableWizard;
if ( m_aContext.createComponentWithArguments( "com.sun.star.wizards.table.CallTableWizard", aWizArgs, xTableWizard ) )
xTableWizard->trigger(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("start")));
xTableWizard->trigger(OUString("start"));
}
catch(const Exception&)
{
@@ -621,17 +621,17 @@ extern "C" void SAL_CALL writeDBLoaderInfo2(void* pRegistryKey)
Reference< XRegistryKey> xKey(reinterpret_cast< XRegistryKey*>(pRegistryKey));
// register content loader for dispatch
::rtl::OUString aImpl(RTL_CONSTASCII_USTRINGPARAM("/"));
OUString aImpl("/");
aImpl += ::dbaxml::DBContentLoader::getImplementationName_Static();
::rtl::OUString aImpltwo = aImpl;
aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/Loader"));
OUString aImpltwo = aImpl;
aImpltwo += OUString("/UNO/Loader");
Reference< XRegistryKey> xNewKey = xKey->createKey( aImpltwo );
aImpltwo = aImpl;
aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/Loader"));
aImpltwo += OUString("/Loader");
Reference< XRegistryKey > xLoaderKey = xKey->createKey( aImpltwo );
xNewKey = xLoaderKey->createKey( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Pattern")) );
xNewKey->setAsciiValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("private:factory/sdatabase")) );
xNewKey = xLoaderKey->createKey( OUString("Pattern") );
xNewKey->setAsciiValue( OUString("private:factory/sdatabase") );
}
// -----------------------------------------------------------------------------
diff --git a/dbaccess/source/filter/xml/xmlConnectionResource.cxx b/dbaccess/source/filter/xml/xmlConnectionResource.cxx
index 68f3828..6eb8009 100644
--- a/dbaccess/source/filter/xml/xmlConnectionResource.cxx
+++ b/dbaccess/source/filter/xml/xmlConnectionResource.cxx
@@ -34,7 +34,7 @@ namespace dbaxml
DBG_NAME(OXMLConnectionResource)
OXMLConnectionResource::OXMLConnectionResource( ODBFilter& rImport,
sal_uInt16 nPrfx, const ::rtl::OUString& _sLocalName,
sal_uInt16 nPrfx, const OUString& _sLocalName,
const Reference< XAttributeList > & _xAttrList) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
{
@@ -51,12 +51,12 @@ OXMLConnectionResource::OXMLConnectionResource( ODBFilter& rImport,
const sal_Int16 nLength = (xDataSource.is() && _xAttrList.is()) ? _xAttrList->getLength() : 0;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
const rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
const OUString sAttrName = _xAttrList->getNameByIndex( i );
const sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
const rtl::OUString sValue = _xAttrList->getValueByIndex( i );
const OUString sValue = _xAttrList->getValueByIndex( i );
aProperty.Name = ::rtl::OUString();
aProperty.Name = OUString();
aProperty.Value = Any();
switch( rTokenMap.Get( nPrefix, sLocalName ) )
@@ -75,10 +75,10 @@ OXMLConnectionResource::OXMLConnectionResource( ODBFilter& rImport,
aProperty.Name = PROPERTY_TYPE;
break;
case XML_TOK_SHOW:
aProperty.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Show"));
aProperty.Name = OUString("Show");
break;
case XML_TOK_ACTUATE:
aProperty.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Actuate"));
aProperty.Name = OUString("Actuate");
break;
}
if ( !aProperty.Name.isEmpty() )
diff --git a/dbaccess/source/filter/xml/xmlDataSource.cxx b/dbaccess/source/filter/xml/xmlDataSource.cxx
index ba45e38..9b62d4d 100644
--- a/dbaccess/source/filter/xml/xmlDataSource.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSource.cxx
@@ -40,7 +40,7 @@ namespace dbaxml
DBG_NAME(OXMLDataSource)
OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
sal_uInt16 nPrfx, const ::rtl::OUString& _sLocalName,
sal_uInt16 nPrfx, const OUString& _sLocalName,
const Reference< XAttributeList > & _xAttrList, const UsedFor _eUsedFor ) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
{
@@ -59,15 +59,15 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
bool bFoundSuppressVersionColumns = false;
const sal_Int16 nLength = (xDataSource.is() && _xAttrList.is()) ? _xAttrList->getLength() : 0;
static const ::rtl::OUString s_sTRUE = ::xmloff::token::GetXMLToken(XML_TRUE);
static const OUString s_sTRUE = ::xmloff::token::GetXMLToken(XML_TRUE);
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
aProperty.Name = ::rtl::OUString();
aProperty.Name = OUString();
aProperty.Value = Any();
switch( rTokenMap.Get( nPrefix, sLocalName ) )
@@ -156,7 +156,7 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
aProperty.Value <<= sValue.toInt32();
break;
case XML_TOK_JAVA_CLASSPATH:
aProperty.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("JavaDriverClassPath"));
aProperty.Name = OUString("JavaDriverClassPath");
break;
}
if ( !aProperty.Name.isEmpty() )
@@ -210,7 +210,7 @@ OXMLDataSource::~OXMLDataSource()
SvXMLImportContext* OXMLDataSource::CreateChildContext(
sal_uInt16 nPrefix,
const ::rtl::OUString& rLocalName,
const OUString& rLocalName,
const Reference< XAttributeList > & xAttrList )
{
SvXMLImportContext *pContext = 0;
diff --git a/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx b/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
index eb20f5c..1a0704b 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
@@ -37,7 +37,7 @@ DBG_NAME(OXMLDataSourceInfo)
OXMLDataSourceInfo::OXMLDataSourceInfo( ODBFilter& rImport
,sal_uInt16 nPrfx
,const ::rtl::OUString& _sLocalName
,const OUString& _sLocalName
,const Reference< XAttributeList > & _xAttrList
,const sal_uInt16 _nToken) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
@@ -55,12 +55,12 @@ OXMLDataSourceInfo::OXMLDataSourceInfo( ODBFilter& rImport
::std::vector< sal_uInt16 > aTokens;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
aProperty.Name = ::rtl::OUString();
aProperty.Name = OUString();
sal_uInt16 nToken = rTokenMap.Get( nPrefix, sLocalName );
aTokens.push_back(nToken);
@@ -112,20 +112,20 @@ OXMLDataSourceInfo::OXMLDataSourceInfo( ODBFilter& rImport
if ( !bFoundField )
{
aProperty.Name = INFO_FIELDDELIMITER;
aProperty.Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(";"));
aProperty.Value <<= OUString(";");
rImport.addInfo(aProperty);
}
if ( !bFoundThousand )
{
aProperty.Name = INFO_THOUSANDSDELIMITER;
aProperty.Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(","));
aProperty.Value <<= OUString(",");
rImport.addInfo(aProperty);
}
}
if ( XML_TOK_FONT_CHARSET == _nToken && !bFoundCharset )
{
aProperty.Name = INFO_CHARSET;
aProperty.Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("utf8"));
aProperty.Value <<= OUString("utf8");
rImport.addInfo(aProperty);
}
}
diff --git a/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx b/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
index 37a14e8a..15e1254 100644
--- a/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
+++ b/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
@@ -42,11 +42,11 @@ DBG_NAME(OXMLHierarchyCollection)
OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
,sal_uInt16 nPrfx
,const ::rtl::OUString& _sLocalName
,const OUString& _sLocalName
,const Reference< XAttributeList > & _xAttrList
,const Reference< XNameAccess >& _xParentContainer
,const ::rtl::OUString& _sCollectionServiceName
,const ::rtl::OUString& _sComponentServiceName) :
,const OUString& _sCollectionServiceName
,const OUString& _sComponentServiceName) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
,m_xParentContainer(_xParentContainer)
,m_sCollectionServiceName(_sCollectionServiceName)
@@ -60,10 +60,10 @@ OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
sal_Int16 nLength = (_xAttrList.is()) ? _xAttrList->getLength() : 0;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
switch( rTokenMap.Get( nPrefix, sLocalName ) )
{
@@ -79,11 +79,11 @@ OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
Sequence< Any > aArguments(2);
PropertyValue aValue;
// set as folder
aValue.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
aValue.Name = OUString("Name");
aValue.Value <<= m_sName;
aArguments[0] <<= aValue;
//parent
aValue.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Parent"));
aValue.Name = OUString("Parent");
aValue.Value <<= _xParentContainer;
aArguments[1] <<= aValue;
@@ -105,7 +105,7 @@ OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
// -----------------------------------------------------------------------------
OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
,sal_uInt16 nPrfx
,const ::rtl::OUString& _sLocalName
,const OUString& _sLocalName
,const Reference< XNameAccess >& _xContainer
,const Reference< XPropertySet >& _xTable
) :
@@ -125,7 +125,7 @@ OXMLHierarchyCollection::~OXMLHierarchyCollection()
// -----------------------------------------------------------------------------
SvXMLImportContext* OXMLHierarchyCollection::CreateChildContext(
sal_uInt16 nPrefix,
const ::rtl::OUString& rLocalName,
const OUString& rLocalName,
const Reference< XAttributeList > & xAttrList )
{
SvXMLImportContext *pContext = 0;
diff --git a/dbaccess/source/filter/xml/xmlLogin.cxx b/dbaccess/source/filter/xml/xmlLogin.cxx
index 1fb841a..eb0503f 100644
--- a/dbaccess/source/filter/xml/xmlLogin.cxx
+++ b/dbaccess/source/filter/xml/xmlLogin.cxx
@@ -37,7 +37,7 @@ namespace dbaxml
DBG_NAME(OXMLLogin)
OXMLLogin::OXMLLogin( ODBFilter& rImport,
sal_uInt16 nPrfx, const ::rtl::OUString& _sLocalName,
sal_uInt16 nPrfx, const OUString& _sLocalName,
const Reference< XAttributeList > & _xAttrList ) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
{
@@ -50,14 +50,14 @@ OXMLLogin::OXMLLogin( ODBFilter& rImport,
Reference<XPropertySet> xDataSource(rImport.getDataSource());
const sal_Int16 nLength = (xDataSource.is() && _xAttrList.is()) ? _xAttrList->getLength() : 0;
static const ::rtl::OUString s_sTRUE = ::xmloff::token::GetXMLToken(XML_TRUE);
static const OUString s_sTRUE = ::xmloff::token::GetXMLToken(XML_TRUE);
bool bUserFound = false;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
try
{
@@ -92,7 +92,7 @@ OXMLLogin::OXMLLogin( ODBFilter& rImport,
{
bUserFound = true;
PropertyValue aProperty;
aProperty.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UseSystemUser"));
aProperty.Name = OUString("UseSystemUser");
aProperty.Value <<= (sValue == s_sTRUE ? sal_True : sal_False);
rImport.addInfo(aProperty);
}
diff --git a/dbaccess/source/filter/xml/xmlServerDatabase.cxx b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
index 3daafca..dec5d0e 100644
--- a/dbaccess/source/filter/xml/xmlServerDatabase.cxx
+++ b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
@@ -34,7 +34,7 @@ namespace dbaxml
DBG_NAME(OXMLServerDatabase)
OXMLServerDatabase::OXMLServerDatabase( ODBFilter& rImport,
sal_uInt16 nPrfx, const ::rtl::OUString& _sLocalName,
sal_uInt16 nPrfx, const OUString& _sLocalName,
const Reference< XAttributeList > & _xAttrList) :
SvXMLImportContext( rImport, nPrfx, _sLocalName )
{
@@ -49,13 +49,13 @@ OXMLServerDatabase::OXMLServerDatabase( ODBFilter& rImport,
PropertyValue aProperty;
const sal_Int16 nLength = (xDataSource.is() && _xAttrList.is()) ? _xAttrList->getLength() : 0;
::rtl::OUString sType,sHostName,sPortNumber,sDatabaseName;
OUString sType,sHostName,sPortNumber,sDatabaseName;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
const rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
const OUString sAttrName = _xAttrList->getNameByIndex( i );
const sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
const rtl::OUString sValue = _xAttrList->getValueByIndex( i );
const OUString sValue = _xAttrList->getValueByIndex( i );
switch( rTokenMap.Get( nPrefix, sLocalName ) )
{
@@ -69,7 +69,7 @@ OXMLServerDatabase::OXMLServerDatabase( ODBFilter& rImport,
sPortNumber = sValue;
break;
case XML_TOK_LOCAL_SOCKET:
aProperty.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LocalSocket"));
aProperty.Name = OUString("LocalSocket");
aProperty.Value <<= sValue;
rImport.addInfo(aProperty);
break;
diff --git a/dbaccess/source/filter/xml/xmlStyleImport.cxx b/dbaccess/source/filter/xml/xmlStyleImport.cxx
index e1b0177..b1a2792 100644
--- a/dbaccess/source/filter/xml/xmlStyleImport.cxx
+++ b/dbaccess/source/filter/xml/xmlStyleImport.cxx
@@ -60,11 +60,11 @@ TYPEINIT1( OTableStylesContext, SvXMLStylesContext );
DBG_NAME(OTableStyleContext)
OTableStyleContext::OTableStyleContext( ODBFilter& rImport,
sal_uInt16 nPrfx, const ::rtl::OUString& rLName,
sal_uInt16 nPrfx, const OUString& rLName,
const Reference< XAttributeList > & xAttrList,
SvXMLStylesContext& rStyles, sal_uInt16 nFamily, sal_Bool bDefaultStyle )
:XMLPropStyleContext( rImport, nPrfx, rLName, xAttrList, rStyles, nFamily, bDefaultStyle )
,sNumberFormat(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NumberFormat")))
,sNumberFormat(OUString("NumberFormat"))
,pStyles(&rStyles)
,m_nNumberFormat(-1)
{
@@ -138,8 +138,8 @@ void OTableStyleContext::AddProperty(const sal_Int16 nContextID, const uno::Any&
}
// -----------------------------------------------------------------------------
void OTableStyleContext::SetAttribute( sal_uInt16 nPrefixKey,
const ::rtl::OUString& rLocalName,
const ::rtl::OUString& rValue )
const OUString& rLocalName,
const OUString& rValue )
{
// TODO: use a map here
if( IsXMLToken(rLocalName, XML_DATA_STYLE_NAME ) )
@@ -159,13 +159,13 @@ DBG_NAME(OTableStylesContext)
OTableStylesContext::OTableStylesContext( SvXMLImport& rImport,
sal_uInt16 nPrfx ,
const ::rtl::OUString& rLName ,
const OUString& rLName ,
const Reference< XAttributeList > & xAttrList,
const sal_Bool bTempAutoStyles ) :
SvXMLStylesContext( rImport, nPrfx, rLName, xAttrList ),
sTableStyleServiceName( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_NAME ))),
sColumnStyleServiceName( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_NAME ))),
sCellStyleServiceName( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_CELL_STYLES_NAME ))),
sTableStyleServiceName( OUString( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_NAME )),
sColumnStyleServiceName( OUString( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_NAME )),
sCellStyleServiceName( OUString( XML_STYLE_FAMILY_TABLE_CELL_STYLES_NAME )),
m_nNumberFormatIndex(-1),
bAutoStyles(bTempAutoStyles)
{
@@ -229,7 +229,7 @@ UniReference < SvXMLImportPropertyMapper >
}
// ----------------------------------------------------------------------------
SvXMLStyleContext *OTableStylesContext::CreateStyleStyleChildContext(
sal_uInt16 nFamily, sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
sal_uInt16 nFamily, sal_uInt16 nPrefix, const OUString& rLocalName,
const Reference< xml::sax::XAttributeList > & xAttrList )
{
SvXMLStyleContext *pStyle = SvXMLStylesContext::CreateStyleStyleChildContext( nFamily, nPrefix,
@@ -259,9 +259,9 @@ Reference < XNameContainer >
}
// -----------------------------------------------------------------------------
::rtl::OUString OTableStylesContext::GetServiceName( sal_uInt16 nFamily ) const
OUString OTableStylesContext::GetServiceName( sal_uInt16 nFamily ) const
{
rtl::OUString sServiceName = SvXMLStylesContext::GetServiceName(nFamily);
OUString sServiceName = SvXMLStylesContext::GetServiceName(nFamily);
if (sServiceName.isEmpty())
{
switch( nFamily )
diff --git a/dbaccess/source/filter/xml/xmlTable.cxx b/dbaccess/source/filter/xml/xmlTable.cxx
index 994d1cf..bac9efb 100644
--- a/dbaccess/source/filter/xml/xmlTable.cxx
+++ b/dbaccess/source/filter/xml/xmlTable.cxx
@@ -42,10 +42,10 @@ DBG_NAME(OXMLTable)
OXMLTable::OXMLTable( ODBFilter& _rImport
,sal_uInt16 nPrfx
,const ::rtl::OUString& _sLocalName
,const OUString& _sLocalName
,const uno::Reference< XAttributeList > & _xAttrList
,const uno::Reference< ::com::sun::star::container::XNameAccess >& _xParentContainer
,const ::rtl::OUString& _sServiceName
,const OUString& _sServiceName
)
:SvXMLImportContext( _rImport, nPrfx, _sLocalName )
,m_xParentContainer(_xParentContainer)
@@ -62,10 +62,10 @@ OXMLTable::OXMLTable( ODBFilter& _rImport
sal_Int16 nLength = (_xAttrList.is()) ? _xAttrList->getLength() : 0;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
switch( rTokenMap.Get( nPrefix, sLocalName ) )
{
@@ -92,11 +92,11 @@ OXMLTable::OXMLTable( ODBFilter& _rImport
Sequence< Any > aArguments(2);
PropertyValue aValue;
// set as folder
aValue.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
aValue.Name = OUString("Name");
aValue.Value <<= m_sName;
aArguments[0] <<= aValue;
//parent
aValue.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Parent"));
aValue.Name = OUString("Parent");
aValue.Value <<= m_xParentContainer;
aArguments[1] <<= aValue;
m_xTable.set(
@@ -113,7 +113,7 @@ OXMLTable::~OXMLTable()
// -----------------------------------------------------------------------------
SvXMLImportContext* OXMLTable::CreateChildContext(
sal_uInt16 nPrefix,
const ::rtl::OUString& rLocalName,
const OUString& rLocalName,
const uno::Reference< XAttributeList > & xAttrList )
{
SvXMLImportContext *pContext = 0;
@@ -124,14 +124,14 @@ SvXMLImportContext* OXMLTable::CreateChildContext(
case XML_TOK_FILTER_STATEMENT:
{
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
::rtl::OUString s1,s2,s3;
OUString s1,s2,s3;
fillAttributes(nPrefix, rLocalName,xAttrList,m_sFilterStatement,s1,s2,s3);
}
break;
case XML_TOK_ORDER_STATEMENT:
{
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
::rtl::OUString s1,s2,s3;
OUString s1,s2,s3;
fillAttributes(nPrefix, rLocalName,xAttrList,m_sOrderStatement,s1,s2,s3);
}
break;
@@ -217,12 +217,12 @@ void OXMLTable::EndElement()
}
// -----------------------------------------------------------------------------
void OXMLTable::fillAttributes(sal_uInt16 /*nPrfx*/
,const ::rtl::OUString& /*_sLocalName*/
,const OUString& /*_sLocalName*/
,const uno::Reference< XAttributeList > & _xAttrList
, ::rtl::OUString& _rsCommand
,::rtl::OUString& _rsTableName
,::rtl::OUString& _rsTableSchema
,::rtl::OUString& _rsTableCatalog
,OUString& _rsCommand
,OUString& _rsTableName
,OUString& _rsTableSchema
,OUString& _rsTableCatalog
)
{
OSL_ENSURE(_xAttrList.is(),"Attribute list is NULL!");
@@ -232,10 +232,10 @@ void OXMLTable::fillAttributes(sal_uInt16 /*nPrfx*/
sal_Int16 nLength = (_xAttrList.is()) ? _xAttrList->getLength() : 0;
for(sal_Int16 i = 0; i < nLength; ++i)
{
::rtl::OUString sLocalName;
rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
OUString sLocalName;
OUString sAttrName = _xAttrList->getNameByIndex( i );
sal_uInt16 nPrefix = rMap.GetKeyByAttrName( sAttrName,&sLocalName );
rtl::OUString sValue = _xAttrList->getValueByIndex( i );
OUString sValue = _xAttrList->getValueByIndex( i );
switch( rTokenMap.Get( nPrefix, sLocalName ) )
{
diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx b/dbaccess/source/filter/xml/xmlfilter.cxx
index 183d58b..2fcca35 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -126,7 +126,7 @@ namespace dbaxml
try
{
uno::Reference<frame::XDesktop2> xDesktop = frame::Desktop::create( m_xContext );
const ::rtl::OUString sTarget(RTL_CONSTASCII_USTRINGPARAM("_blank"));
const OUString sTarget("_blank");
sal_Int32 nFrameSearchFlag = frame::FrameSearchFlag::TASKS | frame::FrameSearchFlag::CREATE;
uno::Reference< frame::XFrame> xFrame = xDesktop->findFrame(sTarget,nFrameSearchFlag);
uno::Reference<frame::XComponentLoader> xFrameLoad(xFrame,uno::UNO_QUERY);
@@ -135,20 +135,20 @@ namespace dbaxml
{
uno::Sequence < beans::PropertyValue > aArgs( 3);
sal_Int32 nLen = 0;
aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AsTemplate"));
aArgs[nLen].Name = OUString("AsTemplate");
aArgs[nLen++].Value <<= sal_False;
aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ReadOnly"));
aArgs[nLen].Name = OUString("ReadOnly");
aArgs[nLen++].Value <<= sal_True;
aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Hidden"));
aArgs[nLen].Name = OUString("Hidden");
aArgs[nLen++].Value <<= sal_True;
::comphelper::MimeConfigurationHelper aHelper( m_xContext );
SvtModuleOptions aModuleOptions;
uno::Reference< frame::XModel > xModel(xFrameLoad->loadComponentFromURL(
aModuleOptions.GetFactoryEmptyDocumentURL( aModuleOptions.ClassifyFactoryByServiceName( aHelper.GetDocServiceNameFromMediaType(MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET) )),
::rtl::OUString(), // empty frame name
OUString(), // empty frame name
0,
aArgs
),uno::UNO_QUERY);
@@ -180,7 +180,7 @@ namespace dbaxml
// XPropertyChangeListener
virtual void SAL_CALL propertyChange( const beans::PropertyChangeEvent& _rEvent ) throw (uno::RuntimeException)
{
::rtl::OUString sURL;
OUString sURL;
_rEvent.NewValue >>= sURL;
FastLoader* pCreatorThread = NULL;
@@ -252,9 +252,9 @@ sal_Int32 ReadThroughComponent(
catch (const SAXParseException& r)
{
#if OSL_DEBUG_LEVEL > 1
::rtl::OStringBuffer aError(RTL_CONSTASCII_STRINGPARAM(
"SAX parse exception catched while importing:\n"));
aError.append(rtl::OUStringToOString(r.Message,
OStringBuffer aError(
"SAX parse exception catched while importing:\n");
aError.append(OUStringToOString(r.Message,
RTL_TEXTENCODING_ASCII_US));
aError.append(r.LineNumber);
aError.append(',');
@@ -302,7 +302,7 @@ sal_Int32 ReadThroughComponent(
try
{
// open stream (and set parser input)
::rtl::OUString sStreamName = ::rtl::OUString::createFromAscii(pStreamName);
OUString sStreamName = OUString::createFromAscii(pStreamName);
if ( !xStorage->hasByName( sStreamName ) || !xStorage->isStreamElement( sStreamName ) )
{
// stream name not found! Then try the compatibility name.
@@ -313,7 +313,7 @@ sal_Int32 ReadThroughComponent(
return 0;
// if so, does the stream exist?
sStreamName = ::rtl::OUString::createFromAscii(pCompatibilityStreamName);
sStreamName = OUString::createFromAscii(pCompatibilityStreamName);
if ( !xStorage->hasByName( sStreamName ) || !xStorage->isStreamElement( sStreamName ) )
return 0;
}
@@ -322,7 +322,7 @@ sal_Int32 ReadThroughComponent(
xDocStream = xStorage->openStreamElement( sStreamName, embed::ElementModes::READ );
uno::Reference< beans::XPropertySet > xProps( xDocStream, uno::UNO_QUERY_THROW );
uno::Any aAny = xProps->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("Encrypted") ) );
uno::Any aAny = xProps->getPropertyValue( OUString("Encrypted" ) );
aAny >>= bEncrypted;
}
catch (const packages::WrongPasswordException&)
@@ -365,11 +365,11 @@ ODBFilter::ODBFilter( const uno::Reference< XComponentContext >& _rxContext )
GetMM100UnitConverter().SetCoreMeasureUnit(util::MeasureUnit::MM_10TH);
GetMM100UnitConverter().SetXMLMeasureUnit(util::MeasureUnit::CM);
GetNamespaceMap().Add( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( sXML_np__db) ),
GetNamespaceMap().Add( OUString ( sXML_np__db ),
GetXMLToken(XML_N_DB),
XML_NAMESPACE_DB );
GetNamespaceMap().Add( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( sXML_np___db) ),
GetNamespaceMap().Add( OUString ( sXML_np___db ),
GetXMLToken(XML_N_DB_OASIS),
XML_NAMESPACE_DB );
}
@@ -424,10 +424,10 @@ sal_Bool SAL_CALL ODBFilter::filter( const Sequence< PropertyValue >& rDescripto
sal_Bool ODBFilter::implImport( const Sequence< PropertyValue >& rDescriptor )
throw (RuntimeException)
{
::rtl::OUString sFileName;
OUString sFileName;
::comphelper::NamedValueCollection aMediaDescriptor( rDescriptor );
if ( aMediaDescriptor.has( "URL" ) )
sFileName = aMediaDescriptor.getOrDefault( "URL", ::rtl::OUString() );
sFileName = aMediaDescriptor.getOrDefault( "URL", OUString() );
if ( sFileName.isEmpty() && aMediaDescriptor.has( "FileName" ) )
sFileName = aMediaDescriptor.getOrDefault( "FileName", sFileName );
@@ -450,7 +450,7 @@ sal_Bool ODBFilter::implImport( const Sequence< PropertyValue >& rDescriptor )
Any aError = ::cppu::getCaughtException();
if ( aError.isExtractableTo( ::cppu::UnoType< RuntimeException >::get() ) )
throw;
throw lang::WrappedTargetRuntimeException( ::rtl::OUString(), *this, aError );
throw lang::WrappedTargetRuntimeException( OUString(), *this, aError );
}
uno::Reference<sdb::XOfficeDatabaseDocument> xOfficeDoc(GetModel(),UNO_QUERY_THROW);
@@ -508,7 +508,7 @@ sal_Bool ODBFilter::implImport( const Sequence< PropertyValue >& rDescriptor )
}
// -----------------------------------------------------------------------------
SvXMLImportContext* ODBFilter::CreateContext( sal_uInt16 nPrefix,
const ::rtl::OUString& rLocalName,
const OUString& rLocalName,
const uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList )
{
SvXMLImportContext *pContext = 0;
@@ -827,7 +827,7 @@ const SvXMLTokenMap& ODBFilter::GetColumnElemTokenMap() const
return *m_pColumnElemTokenMap;
}
// -----------------------------------------------------------------------------
SvXMLImportContext* ODBFilter::CreateStylesContext(sal_uInt16 _nPrefix,const ::rtl::OUString& rLocalName,
SvXMLImportContext* ODBFilter::CreateStylesContext(sal_uInt16 _nPrefix,const OUString& rLocalName,
const uno::Reference< XAttributeList>& xAttrList, sal_Bool bIsAutoStyle )
{
SvXMLImportContext *pContext = NULL;
@@ -842,7 +842,7 @@ SvXMLImportContext* ODBFilter::CreateStylesContext(sal_uInt16 _nPrefix,const ::r
return pContext;
}
// -----------------------------------------------------------------------------
SvXMLImportContext* ODBFilter::CreateScriptContext( const ::rtl::OUString& _rLocalName )
SvXMLImportContext* ODBFilter::CreateScriptContext( const OUString& _rLocalName )
{
return new XMLScriptContext( *this, XML_NAMESPACE_OFFICE, _rLocalName, GetModel() );
}
@@ -881,7 +881,7 @@ void ODBFilter::setPropertyInfo()
return;
::connectivity::DriversConfig aDriverConfig(GetComponentContext());
const ::rtl::OUString sURL = ::comphelper::getString(xDataSource->getPropertyValue(PROPERTY_URL));
const OUString sURL = ::comphelper::getString(xDataSource->getPropertyValue(PROPERTY_URL));
::comphelper::NamedValueCollection aDataSourceSettings = aDriverConfig.getProperties( sURL );
Sequence<PropertyValue> aInfo;
diff --git a/dbaccess/source/sdbtools/connection/connectiontools.cxx b/dbaccess/source/sdbtools/connection/connectiontools.cxx
index 330a86c..29798ee 100644
--- a/dbaccess/source/sdbtools/connection/connectiontools.cxx
+++ b/dbaccess/source/sdbtools/connection/connectiontools.cxx
@@ -90,7 +90,7 @@ namespace sdbtools
return new DataSourceMetaData( getContext(), getConnection() );
}
//--------------------------------------------------------------------
Reference< container::XNameAccess > SAL_CALL ConnectionTools::getFieldsByCommandDescriptor( ::sal_Int32 commandType, const ::rtl::OUString& command, Reference< lang::XComponent >& keepFieldsAlive ) throw (sdbc::SQLException, RuntimeException)
Reference< container::XNameAccess > SAL_CALL ConnectionTools::getFieldsByCommandDescriptor( ::sal_Int32 commandType, const OUString& command, Reference< lang::XComponent >& keepFieldsAlive ) throw (sdbc::SQLException, RuntimeException)
{
EntryGuard aGuard( *this );
::dbtools::SQLExceptionInfo aErrorInfo;
@@ -100,7 +100,7 @@ namespace sdbtools
return xRet;
}
//--------------------------------------------------------------------
Reference< sdb::XSingleSelectQueryComposer > SAL_CALL ConnectionTools::getComposer( ::sal_Int32 commandType, const ::rtl::OUString& command ) throw (::com::sun::star::uno::RuntimeException)
Reference< sdb::XSingleSelectQueryComposer > SAL_CALL ConnectionTools::getComposer( ::sal_Int32 commandType, const OUString& command ) throw (::com::sun::star::uno::RuntimeException)
{
EntryGuard aGuard( *this );
dbtools::StatementComposer aComposer(getConnection(), command, commandType, sal_True );
@@ -109,37 +109,37 @@ namespace sdbtools
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL ConnectionTools::getImplementationName() throw (RuntimeException)
OUString SAL_CALL ConnectionTools::getImplementationName() throw (RuntimeException)
{
return getImplementationName_static();
}
//--------------------------------------------------------------------
::sal_Bool SAL_CALL ConnectionTools::supportsService(const ::rtl::OUString & _ServiceName) throw (RuntimeException)
::sal_Bool SAL_CALL ConnectionTools::supportsService(const OUString & _ServiceName) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSupported( getSupportedServiceNames() );
const ::rtl::OUString* begin = aSupported.getConstArray();
const ::rtl::OUString* end = aSupported.getConstArray() + aSupported.getLength();
Sequence< OUString > aSupported( getSupportedServiceNames() );
const OUString* begin = aSupported.getConstArray();
const OUString* end = aSupported.getConstArray() + aSupported.getLength();
return ::std::find( begin, end, _ServiceName ) != end;
}
//--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ConnectionTools::getSupportedServiceNames() throw (RuntimeException)
Sequence< OUString > SAL_CALL ConnectionTools::getSupportedServiceNames() throw (RuntimeException)
{
return getSupportedServiceNames_static();
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL ConnectionTools::getImplementationName_static()
OUString SAL_CALL ConnectionTools::getImplementationName_static()
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dbaccess.ConnectionTools" ) );
return OUString( "com.sun.star.comp.dbaccess.ConnectionTools" );
}
//--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ConnectionTools::getSupportedServiceNames_static()
Sequence< OUString > SAL_CALL ConnectionTools::getSupportedServiceNames_static()
{
Sequence< ::rtl::OUString > aSupported( 1 );
aSupported[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.tools.ConnectionTools" ) );
Sequence< OUString > aSupported( 1 );
aSupported[0] = OUString( "com.sun.star.sdb.tools.ConnectionTools" );
return aSupported;
}
diff --git a/dbaccess/source/sdbtools/connection/objectnames.cxx b/dbaccess/source/sdbtools/connection/objectnames.cxx
index edad066..05c1db0 100644
--- a/dbaccess/source/sdbtools/connection/objectnames.cxx
+++ b/dbaccess/source/sdbtools/connection/objectnames.cxx
@@ -71,8 +71,8 @@ namespace sdbtools
class INameValidation
{
public:
virtual bool validateName( const ::rtl::OUString& _rName ) = 0;
virtual void validateName_throw( const ::rtl::OUString& _rName ) = 0;
virtual bool validateName( const OUString& _rName ) = 0;
virtual void validateName_throw( const OUString& _rName ) = 0;
virtual ~INameValidation() { }
};
@@ -98,12 +98,12 @@ namespace sdbtools
}
// INameValidation
virtual bool validateName( const ::rtl::OUString& _rName )
virtual bool validateName( const OUString& _rName )
{
return !m_xContainer->hasByName( _rName );
}
virtual void validateName_throw( const ::rtl::OUString& _rName )
virtual void validateName_throw( const OUString& _rName )
{
if ( validateName( _rName ) )
return;
@@ -115,7 +115,7 @@ namespace sdbtools
if ( aMeta.supportsSubqueriesInFrom() )
{
String sNeedDistinctNames( SdbtRes( STR_QUERY_AND_TABLE_DISTINCT_NAMES ) );
aError.NextException <<= SQLException( sNeedDistinctNames, m_xConnection, ::rtl::OUString(), 0, Any() );
aError.NextException <<= SQLException( sNeedDistinctNames, m_xConnection, OUString(), 0, Any() );
}
throw aError;
@@ -137,17 +137,17 @@ namespace sdbtools
{
}
virtual bool validateName( const ::rtl::OUString& _rName )
virtual bool validateName( const OUString& _rName )
{
::dbtools::DatabaseMetaData aMeta( m_xConnection );
if ( !aMeta.restrictIdentifiersToSQL92() )
return true;
::rtl::OUString sCatalog, sSchema, sName;
OUString sCatalog, sSchema, sName;
::dbtools::qualifiedNameComponents(
m_xConnection->getMetaData(), _rName, sCatalog, sSchema, sName, ::dbtools::eInTableDefinitions );
::rtl::OUString sExtraNameCharacters( m_xConnection->getMetaData()->getExtraNameCharacters() );
OUString sExtraNameCharacters( m_xConnection->getMetaData()->getExtraNameCharacters() );
if ( ( !sCatalog.isEmpty() && !::dbtools::isValidSQLName( sCatalog, sExtraNameCharacters ) )
|| ( !sSchema.isEmpty() && !::dbtools::isValidSQLName( sSchema, sExtraNameCharacters ) )
|| ( !sName.isEmpty() && !::dbtools::isValidSQLName( sName, sExtraNameCharacters ) )
@@ -157,7 +157,7 @@ namespace sdbtools
return true;
}
virtual void validateName_throw( const ::rtl::OUString& _rName )
virtual void validateName_throw( const OUString& _rName )
{
if ( validateName( _rName ) )
return;
@@ -182,7 +182,7 @@ namespace sdbtools
{
}
inline ::connectivity::ErrorCondition validateName_getErrorCondition( const ::rtl::OUString& _rName )
inline ::connectivity::ErrorCondition validateName_getErrorCondition( const OUString& _rName )
{
if ( ( _rName.indexOf( (sal_Unicode)34 ) >= 0 ) // "
|| ( _rName.indexOf( (sal_Unicode)39 ) >= 0 ) // '
@@ -199,14 +199,14 @@ namespace sdbtools
return 0;
}
virtual bool validateName( const ::rtl::OUString& _rName )
virtual bool validateName( const OUString& _rName )
{
if ( validateName_getErrorCondition( _rName ) != 0 )
return false;
return true;
}
virtual void validateName_throw( const ::rtl::OUString& _rName )
virtual void validateName_throw( const OUString& _rName )
{
::connectivity::ErrorCondition nErrorCondition = validateName_getErrorCondition( _rName );
if ( nErrorCondition != 0 )
@@ -235,12 +235,12 @@ namespace sdbtools
}
// INameValidation
virtual bool validateName( const ::rtl::OUString& _rName )
virtual bool validateName( const OUString& _rName )
{
return m_pPrimary->validateName( _rName ) && m_pSecondary->validateName( _rName );
}
virtual void validateName_throw( const ::rtl::OUString& _rName )
virtual void validateName_throw( const OUString& _rName )
{
m_pPrimary->validateName_throw( _rName );
m_pSecondary->validateName_throw( _rName );
@@ -369,7 +369,7 @@ namespace sdbtools
catch( const Exception& )
{
throw IllegalArgumentException(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "The connection could not provide its database's meta data." ) ),
OUString( "The connection could not provide its database's meta data." ),
NULL,
0
);
@@ -407,7 +407,7 @@ namespace sdbtools
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL ObjectNames::suggestName( ::sal_Int32 _CommandType, const ::rtl::OUString& _BaseName ) throw (IllegalArgumentException, RuntimeException)
OUString SAL_CALL ObjectNames::suggestName( ::sal_Int32 _CommandType, const OUString& _BaseName ) throw (IllegalArgumentException, RuntimeException)
{
EntryGuard aGuard( *this );
@@ -422,11 +422,11 @@ namespace sdbtools
sBaseName = String( SdbtRes( STR_BASENAME_QUERY ) );
}
::rtl::OUString sName( sBaseName );
OUString sName( sBaseName );
sal_Int32 i = 1;
while ( !pNameCheck->validateName( sName ) )
{
::rtl::OUStringBuffer aNameBuffer;
OUStringBuffer aNameBuffer;
aNameBuffer.append( sBaseName );
aNameBuffer.appendAscii( " " );
aNameBuffer.append( (sal_Int32)++i );
@@ -437,7 +437,7 @@ namespace sdbtools
}
//--------------------------------------------------------------------
::rtl::OUString SAL_CALL ObjectNames::convertToSQLName( const ::rtl::OUString& Name ) throw (RuntimeException)
OUString SAL_CALL ObjectNames::convertToSQLName( const OUString& Name ) throw (RuntimeException)
{
EntryGuard aGuard( *this );
Reference< XDatabaseMetaData > xMeta( getConnection()->getMetaData(), UNO_QUERY_THROW );
@@ -445,7 +445,7 @@ namespace sdbtools
}
//--------------------------------------------------------------------
::sal_Bool SAL_CALL ObjectNames::isNameUsed( ::sal_Int32 _CommandType, const ::rtl::OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
::sal_Bool SAL_CALL ObjectNames::isNameUsed( ::sal_Int32 _CommandType, const OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
{
EntryGuard aGuard( *this );
@@ -454,7 +454,7 @@ namespace sdbtools
}
//--------------------------------------------------------------------
::sal_Bool SAL_CALL ObjectNames::isNameValid( ::sal_Int32 _CommandType, const ::rtl::OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
::sal_Bool SAL_CALL ObjectNames::isNameValid( ::sal_Int32 _CommandType, const OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
{
EntryGuard aGuard( *this );
@@ -463,7 +463,7 @@ namespace sdbtools
}
//--------------------------------------------------------------------
void SAL_CALL ObjectNames::checkNameForCreate( ::sal_Int32 _CommandType, const ::rtl::OUString& _Name ) throw (SQLException, RuntimeException)
void SAL_CALL ObjectNames::checkNameForCreate( ::sal_Int32 _CommandType, const OUString& _Name ) throw (SQLException, RuntimeException)
{
EntryGuard aGuard( *this );
diff --git a/dbaccess/source/ui/app/AppController.cxx b/dbaccess/source/ui/app/AppController.cxx
index c21c161..ef62c6a 100644
--- a/dbaccess/source/ui/app/AppController.cxx
+++ b/dbaccess/source/ui/app/AppController.cxx
@@ -984,8 +984,8 @@ namespace
Reference< XInteractionHandler > xHandler( aArgs.getOrDefault( "InteractionHandler", Reference< XInteractionHandler >() ) );
if ( xHandler.is() )
{
::rtl::Reference< ::comphelper::OInteractionRequest > pRequest( new ::comphelper::OInteractionRequest( _rException ) );
::rtl::Reference< ::comphelper::OInteractionApprove > pApprove( new ::comphelper::OInteractionApprove );
Reference< ::comphelper::OInteractionRequest > pRequest( new ::comphelper::OInteractionRequest( _rException ) );
Reference< ::comphelper::OInteractionApprove > pApprove( new ::comphelper::OInteractionApprove );
pRequest->addContinuation( pApprove.get() );
try
diff --git a/dbaccess/source/ui/app/AppControllerGen.cxx b/dbaccess/source/ui/app/AppControllerGen.cxx
index 9014532..6bc7640 100644
--- a/dbaccess/source/ui/app/AppControllerGen.cxx
+++ b/dbaccess/source/ui/app/AppControllerGen.cxx
@@ -125,7 +125,7 @@ public:
};
// -----------------------------------------------------------------------------
void OApplicationController::convertToView(const ::rtl::OUString& _sName)
void OApplicationController::convertToView(const OUString& _sName)
{
try
{
@@ -147,14 +147,14 @@ void OApplicationController::convertToView(const ::rtl::OUString& _sName)
OSaveAsDlg aDlg( getView(), CommandType::TABLE, getORB(), xConnection, aDefaultName, aNameChecker );
if ( aDlg.Execute() == RET_OK )
{
::rtl::OUString sName = aDlg.getName();
::rtl::OUString sCatalog = aDlg.getCatalog();
::rtl::OUString sSchema = aDlg.getSchema();
::rtl::OUString sNewName(
OUString sName = aDlg.getName();
OUString sCatalog = aDlg.getCatalog();
OUString sSchema = aDlg.getSchema();
OUString sNewName(
::dbtools::composeTableName( xMeta, sCatalog, sSchema, sName, sal_False, ::dbtools::eInTableDefinitions ) );
Reference<XPropertySet> xView = ::dbaui::createView(sNewName,xConnection,xSourceObject);
if ( !xView.is() )
throw SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*this,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")) ,0,Any());
throw SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*this,OUString("S1000") ,0,Any());
getContainer()->elementAdded(E_TABLE,sNewName,makeAny(xView));
}
}
@@ -193,11 +193,11 @@ void OApplicationController::pasteFormat(sal_uInt32 _nFormatId)
// -----------------------------------------------------------------------------
void OApplicationController::openDataSourceAdminDialog()
{
openDialog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.DatasourceAdministrationDialog" ) ) );
openDialog( OUString( "com.sun.star.sdb.DatasourceAdministrationDialog" ) );
}
// -----------------------------------------------------------------------------
void OApplicationController::openDialog( const ::rtl::OUString& _sServiceName )
void OApplicationController::openDialog( const OUString& _sServiceName )
{
try
{
@@ -216,19 +216,19 @@ void OApplicationController::openDialog( const ::rtl::OUString& _sServiceName )
xWindow = VCLUnoHelper::GetInterface(getView()->Window::GetParent());
}
// the parent window
aArgs[nArgPos++] <<= PropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ParentWindow")),
aArgs[nArgPos++] <<= PropertyValue( OUString("ParentWindow"),
0,
makeAny(xWindow),
PropertyState_DIRECT_VALUE);
// the initial selection
::rtl::OUString sInitialSelection;
OUString sInitialSelection;
if ( getContainer() )
sInitialSelection = getDatabaseName();
if ( !sInitialSelection.isEmpty() )
{
aArgs[ nArgPos++ ] <<= PropertyValue(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "InitialSelection" ) ), 0,
OUString( "InitialSelection" ), 0,
makeAny( sInitialSelection ), PropertyState_DIRECT_VALUE );
}
@@ -259,7 +259,7 @@ void OApplicationController::openDialog( const ::rtl::OUString& _sServiceName )
// -----------------------------------------------------------------------------
void OApplicationController::openTableFilterDialog()
{
openDialog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.TableFilterDialog" ) ) );
openDialog( OUString( "com.sun.star.sdb.TableFilterDialog" ) );
}
// -----------------------------------------------------------------------------
@@ -311,7 +311,7 @@ void SAL_CALL OApplicationController::propertyChange( const PropertyChangeEvent&
const ElementType eType = getContainer()->getElementType();
if ( eType == E_FORM || eType == E_REPORT )
{
::rtl::OUString sOldName,sNewName;
OUString sOldName,sNewName;
evt.OldValue >>= sOldName;
evt.NewValue >>= sNewName;
@@ -325,7 +325,7 @@ void SAL_CALL OApplicationController::propertyChange( const PropertyChangeEvent&
{
Reference<XContent> xContent(xChild->getParent(),UNO_QUERY);
if ( xContent.is() )
sOldName = xContent->getIdentifier()->getContentIdentifier() + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sOldName;
sOldName = xContent->getIdentifier()->getContentIdentifier() + OUString("/") + sOldName;
}
getContainer()->elementReplaced( eType , sOldName, sNewName );
@@ -397,22 +397,22 @@ void SAL_CALL OApplicationController::connect( ) throw (SQLException, RuntimeEx
}
// -----------------------------------------------------------------------------
beans::Pair< ::sal_Int32, ::rtl::OUString > SAL_CALL OApplicationController::identifySubComponent( const Reference< XComponent >& i_rSubComponent ) throw (IllegalArgumentException, RuntimeException)
beans::Pair< ::sal_Int32, OUString > SAL_CALL OApplicationController::identifySubComponent( const Reference< XComponent >& i_rSubComponent ) throw (IllegalArgumentException, RuntimeException)
{
::osl::MutexGuard aGuard( getMutex() );
sal_Int32 nType = -1;
::rtl::OUString sName;
OUString sName;
if ( !m_pSubComponentManager->lookupSubComponent( i_rSubComponent, sName, nType ) )
throw IllegalArgumentException( ::rtl::OUString(), *this, 1 );
throw IllegalArgumentException( OUString(), *this, 1 );
if ( nType == SID_DB_APP_DSRELDESIGN )
// this is somewhat hacky ... we're expected to return a DatabaseObject value. However, there is no such
// value for the relation design. /me thinks we should change the API definition here ...
nType = -1;
return beans::Pair< ::sal_Int32, ::rtl::OUString >( nType, sName );
return beans::Pair< ::sal_Int32, OUString >( nType, sName );
}
// -----------------------------------------------------------------------------
@@ -445,7 +445,7 @@ namespace
}
// -----------------------------------------------------------------------------
void OApplicationController::impl_validateObjectTypeAndName_throw( const sal_Int32 _nObjectType, const ::boost::optional< ::rtl::OUString >& i_rObjectName )
void OApplicationController::impl_validateObjectTypeAndName_throw( const sal_Int32 _nObjectType, const ::boost::optional< OUString >& i_rObjectName )
{
// ensure we're connected
if ( !isConnected() )
@@ -460,7 +460,7 @@ void OApplicationController::impl_validateObjectTypeAndName_throw( const sal_Int
&& ( _nObjectType != DatabaseObject::FORM )
&& ( _nObjectType != DatabaseObject::REPORT )
)
throw IllegalArgumentException( ::rtl::OUString(), *this, 1 );
throw IllegalArgumentException( OUString(), *this, 1 );
if ( !i_rObjectName )
return;
@@ -470,7 +470,7 @@ void OApplicationController::impl_validateObjectTypeAndName_throw( const sal_Int
if ( !xContainer.is() )
// all possible reasons for this (e.g. not being connected currently) should
// have been handled before
throw RuntimeException( ::rtl::OUString(), *this );
throw RuntimeException( OUString(), *this );
bool bExistentObject = false;
switch ( _nObjectType )
@@ -494,14 +494,14 @@ void OApplicationController::impl_validateObjectTypeAndName_throw( const sal_Int
// -----------------------------------------------------------------------------
Reference< XComponent > SAL_CALL OApplicationController::loadComponent( ::sal_Int32 _ObjectType,
const ::rtl::OUString& _ObjectName, ::sal_Bool _ForEditing ) throw (IllegalArgumentException, NoSuchElementException, SQLException, RuntimeException)
const OUString& _ObjectName, ::sal_Bool _ForEditing ) throw (IllegalArgumentException, NoSuchElementException, SQLException, RuntimeException)
{
return loadComponentWithArguments( _ObjectType, _ObjectName, _ForEditing, Sequence< PropertyValue >() );
}
// -----------------------------------------------------------------------------
Reference< XComponent > SAL_CALL OApplicationController::loadComponentWithArguments( ::sal_Int32 _ObjectType,
const ::rtl::OUString& _ObjectName, ::sal_Bool _ForEditing, const Sequence< PropertyValue >& _Arguments ) throw (IllegalArgumentException, NoSuchElementException, SQLException, RuntimeException)
const OUString& _ObjectName, ::sal_Bool _ForEditing, const Sequence< PropertyValue >& _Arguments ) throw (IllegalArgumentException, NoSuchElementException, SQLException, RuntimeException)
{
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
@@ -531,7 +531,7 @@ Reference< XComponent > SAL_CALL OApplicationController::createComponentWithArgu
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
impl_validateObjectTypeAndName_throw( i_nObjectType, ::boost::optional< ::rtl::OUString >() );
impl_validateObjectTypeAndName_throw( i_nObjectType, ::boost::optional< OUString >() );
Reference< XComponent > xComponent( newElement(
lcl_objectType2ElementType( i_nObjectType ),
@@ -615,9 +615,9 @@ void OApplicationController::askToReconnect()
}
// -----------------------------------------------------------------------------
::rtl::OUString OApplicationController::getDatabaseName() const
OUString OApplicationController::getDatabaseName() const
{
::rtl::OUString sDatabaseName;
OUString sDatabaseName;
try
{
if ( m_xDataSource.is() )
@@ -633,14 +633,14 @@ void OApplicationController::askToReconnect()
}
// -----------------------------------------------------------------------------
::rtl::OUString OApplicationController::getStrippedDatabaseName() const
OUString OApplicationController::getStrippedDatabaseName() const
{
::rtl::OUString sDatabaseName;
OUString sDatabaseName;
return ::dbaui::getStrippedDatabaseName( m_xDataSource, sDatabaseName );
}
// -----------------------------------------------------------------------------
void OApplicationController::onDocumentOpened( const ::rtl::OUString& _rName, const sal_Int32 _nType,
void OApplicationController::onDocumentOpened( const OUString& _rName, const sal_Int32 _nType,
const ElementOpenMode _eMode, const Reference< XComponent >& _xDocument, const Reference< XComponent >& _rxDefinition )
{
if ( !_xDocument.is() )
@@ -695,7 +695,7 @@ sal_Bool OApplicationController::isRenameDeleteAllowed(ElementType _eType,sal_Bo
bCompareRes = getContainer()->getSelectionCount() == 1;
if ( bEnabled && bCompareRes && E_TABLE == eType )
{
::std::vector< ::rtl::OUString> aList;
::std::vector< OUString> aList;
getSelectionElementNames(aList);
try
@@ -722,7 +722,7 @@ void OApplicationController::onLoadedMenu(const Reference< ::com::sun::star::fra
if ( _xLayoutManager.is() )
{
static ::rtl::OUString s_sStatusbar(RTL_CONSTASCII_USTRINGPARAM("private:resource/statusbar/statusbar"));
static OUString s_sStatusbar("private:resource/statusbar/statusbar");
_xLayoutManager->createElement( s_sStatusbar );
_xLayoutManager->requestElement( s_sStatusbar );
@@ -752,7 +752,7 @@ void OApplicationController::onLoadedMenu(const Reference< ::com::sun::star::fra
// -----------------------------------------------------------------------------
void OApplicationController::doAction(sal_uInt16 _nId ,ElementOpenMode _eOpenMode)
{
::std::vector< ::rtl::OUString> aList;
::std::vector< OUString> aList;
getSelectionElementNames(aList);
ElementType eType = getContainer()->getElementType();
::comphelper::NamedValueCollection aArguments;
@@ -763,16 +763,16 @@ void OApplicationController::doAction(sal_uInt16 _nId ,ElementOpenMode _eOpenMod
eOpenMode = E_OPEN_NORMAL;
}
::std::vector< ::std::pair< ::rtl::OUString ,Reference< XModel > > > aCompoments;
::std::vector< ::rtl::OUString>::iterator aEnd = aList.end();
for (::std::vector< ::rtl::OUString>::iterator aIter = aList.begin(); aIter != aEnd; ++aIter)
::std::vector< ::std::pair< OUString ,Reference< XModel > > > aCompoments;
::std::vector< OUString>::iterator aEnd = aList.end();
for (::std::vector< OUString>::iterator aIter = aList.begin(); aIter != aEnd; ++aIter)
{
if ( SID_DB_APP_CONVERTTOVIEW == _nId )
convertToView(*aIter);
else
{
Reference< XModel > xModel( openElementWithArguments( *aIter, eType, eOpenMode, _nId,aArguments ), UNO_QUERY );
aCompoments.push_back( ::std::pair< ::rtl::OUString, Reference< XModel > >( *aIter, xModel ) );
aCompoments.push_back( ::std::pair< OUString, Reference< XModel > >( *aIter, xModel ) );
}
}
@@ -780,9 +780,9 @@ void OApplicationController::doAction(sal_uInt16 _nId ,ElementOpenMode _eOpenMod
if ( _eOpenMode == E_OPEN_FOR_MAIL )
{
::std::vector< ::std::pair< ::rtl::OUString ,Reference< XModel > > >::iterator componentIter = aCompoments.begin();
::std::vector< ::std::pair< ::rtl::OUString ,Reference< XModel > > >::iterator componentEnd = aCompoments.end();
::rtl::OUString aDocTypeString;
::std::vector< ::std::pair< OUString ,Reference< XModel > > >::iterator componentIter = aCompoments.begin();
::std::vector< ::std::pair< OUString ,Reference< XModel > > >::iterator componentEnd = aCompoments.end();
OUString aDocTypeString;
SfxMailModel aSendMail;
SfxMailModel::SendMailResult eResult = SfxMailModel::SEND_MAIL_OK;
for (; componentIter != componentEnd && SfxMailModel::SEND_MAIL_OK == eResult; ++componentIter)
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index 946b243..4f1d87f 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -89,7 +89,7 @@ namespace dbaui
namespace
{
SvTreeListEntry* lcl_findEntry_impl(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvTreeListEntry* _pFirst)
SvTreeListEntry* lcl_findEntry_impl(DBTreeListBox& rTree,const OUString& _rName,SvTreeListEntry* _pFirst)
{
SvTreeListEntry* pReturn = NULL;
sal_Int32 nIndex = 0;
@@ -116,10 +116,10 @@ namespace
}
return pReturn;
}
SvTreeListEntry* lcl_findEntry(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvTreeListEntry* _pFirst)
SvTreeListEntry* lcl_findEntry(DBTreeListBox& rTree,const OUString& _rName,SvTreeListEntry* _pFirst)
{
sal_Int32 nIndex = 0;
::rtl::OUString sErase = _rName.getToken(0,'/',nIndex); // we don't want to have the "private:forms" part
OUString sErase = _rName.getToken(0,'/',nIndex); // we don't want to have the "private:forms" part
return (nIndex != -1 ? lcl_findEntry_impl(rTree,_rName.copy(sErase.getLength() + 1),_pFirst) : NULL);
}
//==================================================================
@@ -320,7 +320,7 @@ void OAppDetailPageHelper::sortUp()
sort(nPos,SortAscending);
}
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::getSelectionElementNames( ::std::vector< ::rtl::OUString>& _rNames ) const
void OAppDetailPageHelper::getSelectionElementNames( ::std::vector< OUString>& _rNames ) const
{
int nPos = getVisibleControlIndex();
if ( nPos < E_ELEMENT_TYPE_COUNT )
@@ -339,11 +339,11 @@ void OAppDetailPageHelper::getSelectionElementNames( ::std::vector< ::rtl::OUStr
}
else
{
::rtl::OUString sName = rTree.GetEntryText(pEntry);
OUString sName = rTree.GetEntryText(pEntry);
SvTreeListEntry* pParent = rTree.GetParent(pEntry);
while(pParent)
{
sName = rTree.GetEntryText(pParent) + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sName;
sName = rTree.GetEntryText(pParent) + OUString("/") + sName;
pParent = rTree.GetParent(pParent);
}
_rNames.push_back(sName);
@@ -400,11 +400,11 @@ void OAppDetailPageHelper::describeCurrentSelectionForType( const ElementType _e
case E_FORM:
case E_REPORT:
{
::rtl::OUString sName = pList->GetEntryText(pEntry);
OUString sName = pList->GetEntryText(pEntry);
SvTreeListEntry* pParent = pList->GetParent(pEntry);
while ( pParent )
{
::rtl::OUStringBuffer buffer;
OUStringBuffer buffer;
buffer.append( pList->GetEntryText( pParent ) );
buffer.append( sal_Unicode( '/' ) );
buffer.append( sName );
@@ -438,15 +438,15 @@ void OAppDetailPageHelper::describeCurrentSelectionForType( const ElementType _e
}
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNames)
void OAppDetailPageHelper::selectElements(const Sequence< OUString>& _aNames)
{
int nPos = getVisibleControlIndex();
if ( nPos < E_ELEMENT_TYPE_COUNT )
{
DBTreeListBox& rTree = *m_pLists[nPos];
rTree.SelectAll(sal_False);
const ::rtl::OUString* pIter = _aNames.getConstArray();
const ::rtl::OUString* pEnd = pIter + _aNames.getLength();
const OUString* pIter = _aNames.getConstArray();
const OUString* pEnd = pIter + _aNames.getLength();
for(;pIter != pEnd;++pIter)
{
SvTreeListEntry* pEntry = rTree.GetEntryPosByName(*pIter);
@@ -456,10 +456,10 @@ void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNa
}
}
// -----------------------------------------------------------------------------
::rtl::OUString OAppDetailPageHelper::getQualifiedName( SvTreeListEntry* _pEntry ) const
OUString OAppDetailPageHelper::getQualifiedName( SvTreeListEntry* _pEntry ) const
{
int nPos = getVisibleControlIndex();
::rtl::OUString sComposedName;
OUString sComposedName;
if ( nPos >= E_ELEMENT_TYPE_COUNT )
return sComposedName;
@@ -485,7 +485,7 @@ void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNa
SvTreeListEntry* pParent = rTree.GetParent(pEntry);
while(pParent)
{
sComposedName = rTree.GetEntryText(pParent) + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sComposedName;
sComposedName = rTree.GetEntryText(pParent) + OUString("/") + sComposedName;
pParent = rTree.GetParent(pParent);
}
}
@@ -655,7 +655,7 @@ void OAppDetailPageHelper::createPage(ElementType _eType,const Reference< XNameA
OSL_ENSURE(E_TABLE != _eType,"E_TABLE isn't allowed.");
sal_uInt16 nImageId = 0;
rtl::OString sHelpId;
OString sHelpId;
ImageProvider aImageProvider;
Image aFolderImage;
switch( _eType )
@@ -748,9 +748,9 @@ void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContaine
{
const sal_Int32 nFolderIndicator = lcl_getFolderIndicatorForType( _eType );
Sequence< ::rtl::OUString> aSeq = _xContainer->getElementNames();
const ::rtl::OUString* pIter = aSeq.getConstArray();
const ::rtl::OUString* pEnd = pIter + aSeq.getLength();
Sequence< OUString> aSeq = _xContainer->getElementNames();
const OUString* pIter = aSeq.getConstArray();
const OUString* pEnd = pIter + aSeq.getLength();
for(;pIter != pEnd;++pIter)
{
SvTreeListEntry* pEntry = NULL;
@@ -773,7 +773,7 @@ void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContaine
}
}
// -----------------------------------------------------------------------------
DBTreeListBox* OAppDetailPageHelper::createSimpleTree( const rtl::OString& _sHelpId, const Image& _rImage)
DBTreeListBox* OAppDetailPageHelper::createSimpleTree( const OString& _sHelpId, const Image& _rImage)
{
DBTreeListBox* pTreeView = new DBTreeListBox(this,
WB_HASLINES | WB_SORT | WB_HASBUTTONS | WB_HSCROLL |WB_HASBUTTONSATROOT | WB_TABSTOP);
@@ -828,13 +828,13 @@ sal_Bool OAppDetailPageHelper::isFilled() const
}
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::elementReplaced(ElementType _eType
,const ::rtl::OUString& _rOldName
,const ::rtl::OUString& _rNewName )
,const OUString& _rOldName
,const OUString& _rNewName )
{
DBTreeListBox* pTreeView = getCurrentView();
if ( pTreeView )
{
::rtl::OUString sNewName = _rNewName;
OUString sNewName = _rNewName;
SvTreeListEntry* pEntry = NULL;
switch( _eType )
{
@@ -861,7 +861,7 @@ void OAppDetailPageHelper::elementReplaced(ElementType _eType
}
}
// -----------------------------------------------------------------------------
SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const OUString& _rName, const Any& _rObject )
{
SvTreeListEntry* pRet = NULL;
DBTreeListBox* pTreeView = m_pLists[_eType];
@@ -879,7 +879,7 @@ SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::r
Reference<XContent> xContent(xChild->getParent(),UNO_QUERY);
if ( xContent.is() )
{
::rtl::OUString sName = xContent->getIdentifier()->getContentIdentifier();
OUString sName = xContent->getIdentifier()->getContentIdentifier();
pEntry = lcl_findEntry(*pTreeView,sName,pTreeView->First());
}
}
@@ -905,7 +905,7 @@ SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::r
return pRet;
}
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::elementRemoved( ElementType _eType,const ::rtl::OUString& _rName )
void OAppDetailPageHelper::elementRemoved( ElementType _eType,const OUString& _rName )
{
DBTreeListBox* pTreeView = getCurrentView();
if ( pTreeView )
@@ -1080,9 +1080,9 @@ void OAppDetailPageHelper::showPreview(const Reference< XContent >& _xContent)
{
com::sun::star::ucb::Command aCommand;
if ( m_ePreviewMode == E_DOCUMENT )
aCommand.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("preview"));
aCommand.Name = OUString("preview");
else
aCommand.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("getDocumentInfo"));
aCommand.Name = OUString("getDocumentInfo");
Any aPreview = xContent->execute(aCommand,xContent->createCommandIdentifier(),Reference< XCommandEnvironment >());
if ( m_ePreviewMode == E_DOCUMENT )
@@ -1127,8 +1127,8 @@ void OAppDetailPageHelper::showPreview(const Reference< XContent >& _xContent)
}
}
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::showPreview( const ::rtl::OUString& _sDataSourceName,
const ::rtl::OUString& _sName,
void OAppDetailPageHelper::showPreview( const OUString& _sDataSourceName,
const OUString& _sName,
sal_Bool _bTable)
{
if ( isPreviewEnabled() )
@@ -1141,14 +1141,14 @@ void OAppDetailPageHelper::showPreview( const ::rtl::OUString& _sDataSourceName,
{
try
{
m_xFrame = Reference < XFrame > ( getBorderWin().getView()->getORB()->getServiceManager()->createInstanceWithContext( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Frame")), getBorderWin().getView()->getORB() ), UNO_QUERY );
m_xFrame = Reference < XFrame > ( getBorderWin().getView()->getORB()->getServiceManager()->createInstanceWithContext( OUString("com.sun.star.frame.Frame"), getBorderWin().getView()->getORB() ), UNO_QUERY );
m_xFrame->initialize( m_xWindow );
// no layout manager (and thus no toolbars) in the preview
// Must be called after initialize ... but before any other call to this frame.
// Otherwise frame throws "life time exceptions" as e.g. NON_INITIALIZED
Reference< XPropertySet > xFrameProps( m_xFrame, UNO_QUERY_THROW );
xFrameProps->setPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ) ), makeAny(Reference< XLayoutManager >()) );
xFrameProps->setPropertyValue( OUString( "LayoutManager" ), makeAny(Reference< XLayoutManager >()) );
Reference<XFramesSupplier> xSup(getBorderWin().getView()->getAppController().getXController()->getFrame(),UNO_QUERY);
if ( xSup.is() )
@@ -1175,7 +1175,7 @@ void OAppDetailPageHelper::showPreview( const ::rtl::OUString& _sDataSourceName,
aArgs.put( "Preview", sal_True );
aArgs.put( "ReadOnly", sal_True );
aArgs.put( "AsTemplate", sal_False );
aArgs.put( (::rtl::OUString)PROPERTY_SHOWMENU, sal_False );
aArgs.put( (OUString)PROPERTY_SHOWMENU, sal_False );
Reference< XController > xPreview( pDispatcher->openExisting( makeAny( _sDataSourceName ), _sName, aArgs ), UNO_QUERY );
sal_Bool bClearPreview = !xPreview.is();
diff --git a/dbaccess/source/ui/app/AppDetailView.cxx b/dbaccess/source/ui/app/AppDetailView.cxx
index d33d0e7..cddaf10 100644
--- a/dbaccess/source/ui/app/AppDetailView.cxx
+++ b/dbaccess/source/ui/app/AppDetailView.cxx
@@ -64,7 +64,7 @@ using ::com::sun::star::sdb::application::NamedDatabaseObject;
// -----------------------------------------------------------------------------
TaskEntry::TaskEntry( const sal_Char* _pAsciiUNOCommand, sal_uInt16 _nHelpID, sal_uInt16 _nTitleResourceID, bool _bHideWhenDisabled )
:sUNOCommand( ::rtl::OUString::createFromAscii( _pAsciiUNOCommand ) )
:sUNOCommand( OUString::createFromAscii( _pAsciiUNOCommand ) )
,nHelpID( _nHelpID )
,sTitle( ModuleRes( _nTitleResourceID ) )
,bHideWhenDisabled( _bHideWhenDisabled )
@@ -480,13 +480,13 @@ void OTasksWindow::fillTaskEntryList( const TaskEntryList& _rList )
Reference< XModuleUIConfigurationManagerSupplier > xModuleCfgMgrSupplier =
ModuleUIConfigurationManagerSupplier::create( getDetailView()->getBorderWin().getView()->getORB() );
Reference< XUIConfigurationManager > xUIConfigMgr = xModuleCfgMgrSupplier->getUIConfigurationManager(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OfficeDatabaseDocument" ) )
OUString( "com.sun.star.sdb.OfficeDatabaseDocument" )
);
Reference< XImageManager > xImageMgr( xUIConfigMgr->getImageManager(), UNO_QUERY );
// copy the commands so we can use them with the config managers
Sequence< ::rtl::OUString > aCommands( _rList.size() );
::rtl::OUString* pCommands = aCommands.getArray();
Sequence< OUString > aCommands( _rList.size() );
OUString* pCommands = aCommands.getArray();
TaskEntryList::const_iterator aEnd = _rList.end();
for ( TaskEntryList::const_iterator pCopyTask = _rList.begin(); pCopyTask != aEnd; ++pCopyTask, ++pCommands )
*pCommands = pCopyTask->sUNOCommand;
@@ -766,7 +766,7 @@ void OApplicationDetailView::impl_fillTaskPaneData( ElementType _eType, TaskPane
}
// -----------------------------------------------------------------------------
::rtl::OUString OApplicationDetailView::getQualifiedName( SvTreeListEntry* _pEntry ) const
OUString OApplicationDetailView::getQualifiedName( SvTreeListEntry* _pEntry ) const
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->getQualifiedName( _pEntry );
@@ -835,7 +835,7 @@ sal_Int32 OApplicationDetailView::getElementCount()
}
// -----------------------------------------------------------------------------
void OApplicationDetailView::getSelectionElementNames( ::std::vector< ::rtl::OUString>& _rNames ) const
void OApplicationDetailView::getSelectionElementNames( ::std::vector< OUString>& _rNames ) const
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
m_pControlHelper->getSelectionElementNames( _rNames );
@@ -853,7 +853,7 @@ void OApplicationDetailView::describeCurrentSelectionForType( const ElementType
m_pControlHelper->describeCurrentSelectionForType( _eType, _out_rSelectedObjects );
}
// -----------------------------------------------------------------------------
void OApplicationDetailView::selectElements(const Sequence< ::rtl::OUString>& _aNames)
void OApplicationDetailView::selectElements(const Sequence< OUString>& _aNames)
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
m_pControlHelper->selectElements( _aNames );
@@ -884,21 +884,21 @@ void OApplicationDetailView::paste()
m_pControlHelper->paste();
}
// -----------------------------------------------------------------------------
SvTreeListEntry* OApplicationDetailView::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
SvTreeListEntry* OApplicationDetailView::elementAdded(ElementType _eType,const OUString& _rName, const Any& _rObject )
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->elementAdded(_eType,_rName, _rObject );
}
// -----------------------------------------------------------------------------
void OApplicationDetailView::elementRemoved(ElementType _eType,const ::rtl::OUString& _rName )
void OApplicationDetailView::elementRemoved(ElementType _eType,const OUString& _rName )
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
m_pControlHelper->elementRemoved(_eType,_rName );
}
// -----------------------------------------------------------------------------
void OApplicationDetailView::elementReplaced(ElementType _eType
,const ::rtl::OUString& _rOldName
,const ::rtl::OUString& _rNewName )
,const OUString& _rOldName
,const OUString& _rNewName )
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
m_pControlHelper->elementReplaced( _eType, _rOldName, _rNewName );
@@ -928,8 +928,8 @@ void OApplicationDetailView::showPreview(const Reference< XContent >& _xContent)
m_pControlHelper->showPreview(_xContent);
}
// -----------------------------------------------------------------------------
void OApplicationDetailView::showPreview( const ::rtl::OUString& _sDataSourceName,
const ::rtl::OUString& _sName,
void OApplicationDetailView::showPreview( const OUString& _sDataSourceName,
const OUString& _sName,
sal_Bool _bTable)
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
diff --git a/dbaccess/source/ui/app/subcomponentmanager.cxx b/dbaccess/source/ui/app/subcomponentmanager.cxx
index c32cb38..803a4b5 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.cxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.cxx
@@ -81,7 +81,7 @@ namespace dbaui
struct SubComponentDescriptor
{
/// the name of the sub component, empty if it is yet unsaved
::rtl::OUString sName;
OUString sName;
/// type of the component - an ElementType value, except for relation design
sal_Int32 nComponentType;
/// the mode in which the sub component has been opened
@@ -107,7 +107,7 @@ namespace dbaui
{
}
SubComponentDescriptor( const ::rtl::OUString& i_rName, const sal_Int32 i_nComponentType,
SubComponentDescriptor( const OUString& i_rName, const sal_Int32 i_nComponentType,
const ElementOpenMode i_eOpenMode, const Reference< XComponent >& i_rComponent )
:sName( i_rName )
,nComponentType( i_nComponentType )
@@ -120,7 +120,7 @@ namespace dbaui
Reference< XComponentSupplier > xCompSupp( i_rComponent, UNO_QUERY_THROW );
Reference< XComponent > xComponent( xCompSupp->getComponent(), UNO_QUERY_THROW );
if ( !impl_constructFrom( xComponent ) )
throw RuntimeException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Illegal component type." ) ), NULL );
throw RuntimeException( OUString( "Illegal component type." ), NULL );
xComponentCommandProcessor.set( i_rComponent, UNO_QUERY_THROW );
xDocumentDefinitionProperties.set( i_rComponent, UNO_QUERY_THROW );
}
@@ -185,7 +185,7 @@ namespace dbaui
struct SubComponentMatch : public ::std::unary_function< SubComponentDescriptor, bool >
{
public:
SubComponentMatch( const ::rtl::OUString& i_rName, const sal_Int32 i_nComponentType,
SubComponentMatch( const OUString& i_rName, const sal_Int32 i_nComponentType,
const ElementOpenMode i_eOpenMode )
:m_sName( i_rName )
,m_nComponentType( i_nComponentType )
@@ -200,7 +200,7 @@ namespace dbaui
&& ( m_eOpenMode == i_rCompareWith.eOpenMode );
}
private:
const ::rtl::OUString m_sName;
const OUString m_sName;
const sal_Int32 m_nComponentType;
const ElementOpenMode m_eOpenMode;
};
@@ -296,7 +296,7 @@ namespace dbaui
sal_Int32 nCommandIdentifier = xCommandProcessor->createCommandIdentifier();
Command aCommand;
aCommand.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "close" ) );
aCommand.Name = OUString( "close" );
xCommandProcessor->execute( aCommand, nCommandIdentifier, NULL );
bSuccess = true;
}
@@ -343,7 +343,7 @@ namespace dbaui
{
Reference< XDocumentEventBroadcaster > xBroadcaster( _rData.m_rController.getModel(), UNO_QUERY_THROW );
xBroadcaster->notifyDocumentEvent(
::rtl::OUString::createFromAscii( _pAsciiEventName ),
OUString::createFromAscii( _pAsciiEventName ),
&_rData.m_rController,
makeAny( _rComponent.xFrame )
);
@@ -371,12 +371,12 @@ namespace dbaui
if ( comp->xDocumentDefinitionProperties != i_rEvent.Source )
continue;
::rtl::OUString sNewName;
OUString sNewName;
OSL_VERIFY( i_rEvent.NewValue >>= sNewName );
#if OSL_DEBUG_LEVEL > 0
::rtl::OUString sOldKnownName( comp->sName );
::rtl::OUString sOldName;
OUString sOldKnownName( comp->sName );
OUString sOldName;
OSL_VERIFY( i_rEvent.OldValue >>= sOldName );
OSL_ENSURE( sOldName == sOldKnownName, "SubComponentManager::propertyChange: inconsistency in the old names!" );
#endif
@@ -483,7 +483,7 @@ namespace dbaui
}
//------------------------------------------------------------------------------------------------------------------
void SubComponentManager::onSubComponentOpened( const ::rtl::OUString& _rName, const sal_Int32 _nComponentType,
void SubComponentManager::onSubComponentOpened( const OUString& _rName, const sal_Int32 _nComponentType,
const ElementOpenMode _eOpenMode, const Reference< XComponent >& _rxComponent )
{
::osl::ClearableMutexGuard aGuard( m_pData->getMutex() );
@@ -519,7 +519,7 @@ namespace dbaui
}
//------------------------------------------------------------------------------------------------------------------
bool SubComponentManager::activateSubFrame( const ::rtl::OUString& _rName, const sal_Int32 _nComponentType,
bool SubComponentManager::activateSubFrame( const OUString& _rName, const sal_Int32 _nComponentType,
const ElementOpenMode _eOpenMode, Reference< XComponent >& o_rComponent ) const
{
::osl::MutexGuard aGuard( m_pData->getMutex() );
@@ -548,7 +548,7 @@ namespace dbaui
}
//------------------------------------------------------------------------------------------------------------------
bool SubComponentManager::closeSubFrames( const ::rtl::OUString& i_rName, const sal_Int32 _nComponentType )
bool SubComponentManager::closeSubFrames( const OUString& i_rName, const sal_Int32 _nComponentType )
{
::osl::MutexGuard aGuard( m_pData->getMutex() );
ENSURE_OR_RETURN_FALSE( !i_rName.isEmpty(), "SubComponentManager::closeSubFrames: illegal name!" );
@@ -571,7 +571,7 @@ namespace dbaui
//------------------------------------------------------------------------------------------------------------------
bool SubComponentManager::lookupSubComponent( const Reference< XComponent >& i_rComponent,
::rtl::OUString& o_rName, sal_Int32& o_rComponentType )
OUString& o_rName, sal_Int32& o_rComponentType )
{
for ( SubComponents::const_iterator comp = m_pData->m_aComponents.begin();
comp != m_pData->m_aComponents.end();