Hi,
I have submitted a patch for review:
https://gerrit.libreoffice.org/2538
To pull it, you can do:
git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/38/2538/1
fdo#38838, String to OUString, in dbaccess/source/ui/browser
Applied fdo#38838 in dbaccess/source/ui/browser, + RTL_CONSTASCII_USTRINGPARAM removals
Change-Id: I8a565cdae7fd9da1de05525c602ce011542ab4d5
---
M dbaccess/source/ui/browser/brwctrlr.cxx
M dbaccess/source/ui/browser/brwview.cxx
M dbaccess/source/ui/browser/dbexchange.cxx
M dbaccess/source/ui/browser/dbloader.cxx
M dbaccess/source/ui/browser/dsEntriesNoExp.cxx
M dbaccess/source/ui/browser/dsbrowserDnD.cxx
M dbaccess/source/ui/browser/exsrcbrw.cxx
M dbaccess/source/ui/browser/formadapter.cxx
M dbaccess/source/ui/browser/genericcontroller.cxx
M dbaccess/source/ui/browser/sbagrid.cxx
M dbaccess/source/ui/browser/unodatbr.cxx
M dbaccess/source/ui/inc/brwctrlr.hxx
M dbaccess/source/ui/inc/brwview.hxx
M dbaccess/source/ui/inc/unodatbr.hxx
M svx/inc/svx/svxdlg.hxx
M svx/source/form/fmshimp.cxx
M svx/source/inc/fmshimp.hxx
17 files changed, 294 insertions(+), 296 deletions(-)
diff --git a/dbaccess/source/ui/browser/brwctrlr.cxx b/dbaccess/source/ui/browser/brwctrlr.cxx
index 0fbfdeb..43e35e7 100644
--- a/dbaccess/source/ui/browser/brwctrlr.cxx
+++ b/dbaccess/source/ui/browser/brwctrlr.cxx
@@ -222,10 +222,10 @@
virtual void SAL_CALL removeParameterListener( const ::com::sun::star::uno::Reference<
::com::sun::star::form::XDatabaseParameterListener >& aListener ) throw
(::com::sun::star::uno::RuntimeException);
// XModeSelector, base of XFormController
- virtual void SAL_CALL setMode( const ::rtl::OUString& aMode ) throw
(::com::sun::star::lang::NoSupportException, ::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getMode( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedModes( )
throw (::com::sun::star::uno::RuntimeException);
- virtual ::sal_Bool SAL_CALL supportsMode( const ::rtl::OUString& aMode ) throw
(::com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL setMode( const OUString& aMode ) throw
(::com::sun::star::lang::NoSupportException, ::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getMode( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedModes( ) throw
(::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Bool SAL_CALL supportsMode( const OUString& aMode ) throw
(::com::sun::star::uno::RuntimeException);
// XTabController, base of XFormController
virtual void SAL_CALL setModel(const ::com::sun::star::uno::Reference<
::com::sun::star::awt::XTabControllerModel > & Model) throw(
::com::sun::star::uno::RuntimeException );
@@ -296,7 +296,7 @@
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addChildController( const Reference<
runtime::XFormController >& /*_ChildController*/ ) throw( RuntimeException,
IllegalArgumentException )
{
// not supported
- throw IllegalArgumentException( ::rtl::OUString(), *this, 1 );
+ throw IllegalArgumentException( OUString(), *this, 1 );
}
//------------------------------------------------------------------
@@ -335,7 +335,7 @@
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setParent( const Reference<
XInterface >& /*Parent*/ ) throw (NoSupportException, RuntimeException)
{
- throw NoSupportException( ::rtl::OUString(), *this );
+ throw NoSupportException( OUString(), *this );
}
//------------------------------------------------------------------
@@ -367,7 +367,7 @@
Any SAL_CALL SbaXDataBrowserController::FormControllerImpl::getByIndex( ::sal_Int32 /*Index*/ )
throw (IndexOutOfBoundsException, WrappedTargetException, RuntimeException)
{
// no sub controllers, never
- throw IndexOutOfBoundsException( ::rtl::OUString(), *this );
+ throw IndexOutOfBoundsException( OUString(), *this );
}
//------------------------------------------------------------------
@@ -462,28 +462,28 @@
}
//------------------------------------------------------------------
-void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setMode( const ::rtl::OUString&
_rMode ) throw (NoSupportException, RuntimeException)
+void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setMode( const OUString& _rMode )
throw (NoSupportException, RuntimeException)
{
if ( !supportsMode( _rMode ) )
throw NoSupportException();
}
//------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXDataBrowserController::FormControllerImpl::getMode( ) throw
(RuntimeException)
+OUString SAL_CALL SbaXDataBrowserController::FormControllerImpl::getMode( ) throw
(RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DataMode" ) );
+ return OUString( "DataMode" );
}
//------------------------------------------------------------------
-Sequence< ::rtl::OUString > SAL_CALL
SbaXDataBrowserController::FormControllerImpl::getSupportedModes( ) throw (RuntimeException)
+Sequence< OUString > SAL_CALL SbaXDataBrowserController::FormControllerImpl::getSupportedModes( )
throw (RuntimeException)
{
- Sequence< ::rtl::OUString > aModes(1);
- aModes[1] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DataMode" ) );
+ Sequence< OUString > aModes(1);
+ aModes[1] = OUString( "DataMode" );
return aModes;
}
//------------------------------------------------------------------
-::sal_Bool SAL_CALL SbaXDataBrowserController::FormControllerImpl::supportsMode( const
::rtl::OUString& aMode ) throw (RuntimeException)
+::sal_Bool SAL_CALL SbaXDataBrowserController::FormControllerImpl::supportsMode( const OUString&
aMode ) throw (RuntimeException)
{
return aMode.compareToAscii( "DataMode" ) == 0;
}
@@ -617,7 +617,7 @@
,m_aAsyncDisplayError( LINK( this, SbaXDataBrowserController, OnAsyncDisplayError ) )
,m_sStateSaveRecord(ModuleRes(RID_STR_SAVE_CURRENT_RECORD))
,m_sStateUndoRecord(ModuleRes(RID_STR_UNDO_MODIFY_RECORD))
- ,m_sModuleIdentifier( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.sdb.DataSourceBrowser" ) ) )
+ ,m_sModuleIdentifier( OUString( "com.sun.star.sdb.DataSourceBrowser" ) )
,m_pFormControllerImpl(NULL)
,m_nFormActionNestingLevel(0)
,m_bLoadCanceled( sal_False )
@@ -734,9 +734,9 @@
for ( sal_Int32 c=0; c<nOrderColumns; ++c )
{
const Reference< XPropertySet > xOrderColumn( xOrderColumns->getByIndex(c),
UNO_QUERY_THROW );
- ::rtl::OUString sColumnName;
+ OUString sColumnName;
OSL_VERIFY( xOrderColumn->getPropertyValue( PROPERTY_NAME ) >>= sColumnName);
- ::rtl::OUString sTableName;
+ OUString sTableName;
OSL_VERIFY( xOrderColumn->getPropertyValue( PROPERTY_TABLENAME ) >>= sTableName);
(void)sColumnName;
(void)sTableName;
@@ -842,8 +842,8 @@
// marry them
Reference< ::com::sun::star::container::XNameContainer > xNameCont(m_xRowSet, UNO_QUERY);
{
- String sText(ModuleRes(STR_DATASOURCE_GRIDCONTROL_NAME));
- xNameCont->insertByName(::rtl::OUString(sText), makeAny(m_xGridModel));
+ OUString sText(ModuleRes(STR_DATASOURCE_GRIDCONTROL_NAME));
+ xNameCont->insertByName(OUString(sText), makeAny(m_xGridModel));
}
// ---------------
@@ -1180,7 +1180,7 @@
}
// -----------------------------------------------------------------------
-void SAL_CALL SbaXDataBrowserController::setIdentifier( const ::rtl::OUString& _Identifier ) throw
(RuntimeException)
+void SAL_CALL SbaXDataBrowserController::setIdentifier( const OUString& _Identifier ) throw
(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com",
"SbaXDataBrowserController::setIdentifier" );
::osl::MutexGuard aGuard( getMutex() );
@@ -1188,7 +1188,7 @@
}
// -----------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXDataBrowserController::getIdentifier( ) throw (RuntimeException)
+OUString SAL_CALL SbaXDataBrowserController::getIdentifier( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com",
"SbaXDataBrowserController::getIdentifier" );
::osl::MutexGuard aGuard( getMutex() );
@@ -1499,7 +1499,7 @@
if (xParam.is())
{
#ifdef DBG_UTIL
- ::rtl::OUString sName;
+ OUString sName;
xParam->getPropertyValue(PROPERTY_NAME) >>= sName;
OSL_ENSURE(sName.equals(pFinalValues->Name),
"SbaXDataBrowserController::approveParameter: suspicious value names!");
#endif
@@ -1591,7 +1591,7 @@
try
{
Reference< XPropertySet > xRowSetProps( getRowSet(), UNO_QUERY_THROW );
- OSL_VERIFY( xRowSetProps->getPropertyValue(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowInserts")) ) >>= bAllowInsertions );
+ OSL_VERIFY( xRowSetProps->getPropertyValue( OUString("AllowInserts") ) >>=
bAllowInsertions );
}
catch( const Exception& )
{
@@ -1610,7 +1610,7 @@
try
{
Reference< XPropertySet > xRowSetProps( getRowSet(), UNO_QUERY_THROW );
- OSL_VERIFY( xRowSetProps->getPropertyValue(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowDeletes")) ) >>= bAllowDeletions );
+ OSL_VERIFY( xRowSetProps->getPropertyValue( OUString("AllowDeletes") ) >>=
bAllowDeletions );
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ROWCOUNT ) >>=
nRowCount );
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ISNEW ) >>=
bInsertionRow );
}
@@ -1727,9 +1727,9 @@
break; // no datasource -> no edit mode
sal_Int32 nDataSourcePrivileges =
::comphelper::getINT32(xDataSourceSet->getPropertyValue(PROPERTY_PRIVILEGES));
- sal_Bool bInsertAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::INSERT) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowInserts"))));
- sal_Bool bUpdateAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::UPDATE) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowUpdates"))));
- sal_Bool bDeleteAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::DELETE) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowDeletes"))));
+ sal_Bool bInsertAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::INSERT) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(OUString("AllowInserts")));
+ sal_Bool bUpdateAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::UPDATE) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(OUString("AllowUpdates")));
+ sal_Bool bDeleteAllowedAndPossible = ((nDataSourcePrivileges &
::com::sun::star::sdbcx::Privilege::DELETE) != 0) &&
::comphelper::getBOOL(xDataSourceSet->getPropertyValue(OUString("AllowDeletes")));
if (!bInsertAllowedAndPossible && !bUpdateAllowedAndPossible &&
!bDeleteAllowedAndPossible)
break; // no insert/update/delete -> no edit mode
@@ -1746,8 +1746,8 @@
{
aReturn.bEnabled = sal_False;
Reference< XPropertySet > xActiveSet(getRowSet(), UNO_QUERY);
- ::rtl::OUString aFilter =
::comphelper::getString(xActiveSet->getPropertyValue(PROPERTY_FILTER));
- ::rtl::OUString aHaving =
::comphelper::getString(xActiveSet->getPropertyValue(PROPERTY_HAVING_CLAUSE));
+ OUString aFilter =
::comphelper::getString(xActiveSet->getPropertyValue(PROPERTY_FILTER));
+ OUString aHaving =
::comphelper::getString(xActiveSet->getPropertyValue(PROPERTY_HAVING_CLAUSE));
if ( !(aFilter.isEmpty() && aHaving.isEmpty()) )
{
xActiveSet->getPropertyValue( PROPERTY_APPLYFILTER ) >>= aReturn.bChecked;
@@ -1773,7 +1773,7 @@
}
//------------------------------------------------------------------------------
-void SbaXDataBrowserController::applyParserOrder(const ::rtl::OUString& _rOldOrder,const
Reference< XSingleSelectQueryComposer >& _xParser)
+void SbaXDataBrowserController::applyParserOrder(const OUString& _rOldOrder,const Reference<
XSingleSelectQueryComposer >& _xParser)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com",
"SbaXDataBrowserController::applyParserOrder" );
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
@@ -1815,7 +1815,7 @@
}
//------------------------------------------------------------------------------
-void SbaXDataBrowserController::applyParserFilter(const ::rtl::OUString& _rOldFilter, sal_Bool
_bOldFilterApplied,const ::rtl::OUString& _sOldHaving,const Reference< XSingleSelectQueryComposer
& _xParser)
+void SbaXDataBrowserController::applyParserFilter(const OUString& _rOldFilter, sal_Bool
_bOldFilterApplied,const ::OUString& _sOldHaving,const Reference< XSingleSelectQueryComposer >&
_xParser)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com",
"SbaXDataBrowserController::applyParserFilter" );
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
@@ -1874,7 +1874,7 @@
xRowSetProps->getPropertyValue( PROPERTY_ACTIVE_CONNECTION ), UNO_QUERY_THROW );
xComposer.set( xFactory->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ),
UNO_QUERY_THROW );
- ::rtl::OUString sActiveCommand;
+ OUString sActiveCommand;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ACTIVECOMMAND ) >>= sActiveCommand );
if ( !sActiveCommand.isEmpty() )
{
@@ -1882,22 +1882,22 @@
}
else
{
- ::rtl::OUString sCommand;
+ OUString sCommand;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_COMMAND ) >>= sCommand );
sal_Int32 nCommandType = CommandType::COMMAND;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_COMMAND_TYPE ) >>= nCommandType );
xComposer->setCommand( sCommand, nCommandType );
}
- ::rtl::OUString sFilter;
+ OUString sFilter;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_FILTER ) >>= sFilter );
xComposer->setFilter( sFilter );
- ::rtl::OUString sHavingClause;
+ OUString sHavingClause;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_HAVING_CLAUSE ) >>= sHavingClause );
xComposer->setHavingClause( sHavingClause );
- ::rtl::OUString sOrder;
+ OUString sOrder;
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ORDER ) >>= sOrder );
xComposer->setOrder( sOrder );
}
@@ -1916,8 +1916,8 @@
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
- const ::rtl::OUString sOldVal = bFilter ? m_xParser->getFilter() : m_xParser->getOrder();
- const ::rtl::OUString sOldHaving = m_xParser->getHavingClause();
+ const OUString sOldVal = bFilter ? m_xParser->getFilter() : m_xParser->getOrder();
+ const OUString sOldHaving = m_xParser->getHavingClause();
Reference< XSingleSelectQueryComposer > xParser = createParser_nothrow();
try
{
@@ -1926,7 +1926,7 @@
if(bFilter)
{
DlgFilterCrit aDlg( getBrowserView(), getORB(), xCon, xParser, xSup->getColumns() );
- String aFilter;
+ OUString aFilter;
if ( !aDlg.Execute() )
return; // if so we don't need to update the grid
aDlg.BuildWherePart();
@@ -1934,7 +1934,7 @@
else
{
DlgOrderCrit aDlg( getBrowserView(),xCon,xParser,xSup->getColumns() );
- String aOrder;
+ OUString aOrder;
if(!aDlg.Execute())
{
return; // if so we don't need to actualize the grid
@@ -1953,14 +1953,14 @@
return;
}
- ::rtl::OUString sNewVal = bFilter ? xParser->getFilter() : xParser->getOrder();
+ OUString sNewVal = bFilter ? xParser->getFilter() : xParser->getOrder();
sal_Bool bOldFilterApplied(sal_False);
if (bFilter)
{
try { bOldFilterApplied =
::comphelper::getBOOL(xFormSet->getPropertyValue(PROPERTY_APPLYFILTER)); } catch(Exception&) { } ;
}
- ::rtl::OUString sNewHaving = xParser->getHavingClause();
+ OUString sNewHaving = xParser->getHavingClause();
if ( sOldVal.equals(sNewVal) && (!bFilter || sOldHaving.equals(sNewHaving)) )
// nothing to be done
return;
@@ -1989,22 +1989,22 @@
sal_Int16 nModelCol = getBrowserView()->View2ModelPos(nViewCol);
Reference< XPropertySet > xCurrentCol(xColumns->getByIndex(nModelCol),UNO_QUERY);
- String sActiveField =
::comphelper::getString(xCurrentCol->getPropertyValue(PROPERTY_CONTROLSOURCE));
+ OUString sActiveField =
::comphelper::getString(xCurrentCol->getPropertyValue(PROPERTY_CONTROLSOURCE));
// the text within the current cell
- String sInitialText;
+ OUString sInitialText;
Reference< ::com::sun::star::container::XIndexAccess > xColControls(xGridPeer, UNO_QUERY);
Reference< XInterface > xCurControl(xColControls->getByIndex(nViewCol),UNO_QUERY);
- ::rtl::OUString aInitialText;
+ OUString aInitialText;
if (IsSearchableControl(xCurControl, &aInitialText))
sInitialText = aInitialText;
// prohibit the synchronization of the grid's display with the cursor's position
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::ExecuteSearch : no model set ?!");
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
::comphelper::makeBoolAny(sal_Bool(sal_False)));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AlwaysShowCursor")),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CursorColor")),
makeAny(sal_Int32(COL_LIGHTRED)));
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"),
::comphelper::makeBoolAny(sal_Bool(sal_False)));
+ xModelSet->setPropertyValue(OUString("AlwaysShowCursor"),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(OUString("CursorColor"), makeAny(sal_Int32(COL_LIGHTRED)));
Reference< ::com::sun::star::util::XNumberFormatsSupplier >
xNFS(::dbtools::getNumberFormats(::dbtools::getConnection(m_xRowSet), sal_True, getORB()));
@@ -2012,8 +2012,8 @@
AbstractFmSearchDialog* pDialog = NULL;
if ( pFact )
{
- ::std::vector< String > aContextNames;
- aContextNames.push_back( rtl::OUString("Standard") );
+ ::std::vector< OUString > aContextNames;
+ aContextNames.push_back( OUString("Standard") );
pDialog = pFact->CreateFmSearchDialog(getBrowserView(), sInitialText, aContextNames, 0,
LINK(this, SbaXDataBrowserController, OnSearchContextRequest));
}
OSL_ENSURE( pDialog, "SbaXDataBrowserController::ExecuteSearch: could not get the search
dialog!" );
@@ -2027,9 +2027,9 @@
}
// restore the grid's normal operating state
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AlwaysShowCursor")),
::comphelper::makeBoolAny(sal_Bool(sal_False)));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CursorColor")),
Any());
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(OUString("AlwaysShowCursor"),
::comphelper::makeBoolAny(sal_Bool(sal_False)));
+ xModelSet->setPropertyValue(OUString("CursorColor"), Any());
}
//------------------------------------------------------------------------------
@@ -2163,10 +2163,10 @@
break;
Reference< XSingleSelectQueryComposer > xParser = createParser_nothrow();
- const ::rtl::OUString sOldSort = xParser->getOrder();
+ const OUString sOldSort = xParser->getOrder();
sal_Bool bParserSuccess = sal_False;
HANDLE_SQL_ERRORS(
- xParser->setOrder(::rtl::OUString()); xParser->appendOrderByColumn(xField,
bSortUp),
+ xParser->setOrder(OUString()); xParser->appendOrderByColumn(xField, bSortUp),
bParserSuccess,
ModuleRes(SBA_BROWSER_SETTING_ORDER).toString(),
"SbaXDataBrowserController::Execute : caught an exception while composing the new
filter !"
@@ -2191,21 +2191,21 @@
// check if the column is a aggregate function
sal_Bool bHaving = sal_False;
- ::rtl::OUString sName;
+ OUString sName;
xField->getPropertyValue(PROPERTY_NAME) >>= sName;
Reference< XColumnsSupplier > xColumnsSupplier(m_xParser, UNO_QUERY);
Reference< ::com::sun::star::container::XNameAccess > xCols = xColumnsSupplier.is() ?
xColumnsSupplier->getColumns() : Reference< ::com::sun::star::container::XNameAccess > ();
if ( xCols.is() && xCols->hasByName(sName) )
{
Reference<XPropertySet> xProp(xCols->getByName(sName),UNO_QUERY);
- static ::rtl::OUString sAgg(RTL_CONSTASCII_USTRINGPARAM("AggregateFunction"));
+ static OUString sAgg("AggregateFunction");
if ( xProp->getPropertySetInfo()->hasPropertyByName(sAgg) )
xProp->getPropertyValue(sAgg) >>= bHaving;
}
Reference< XSingleSelectQueryComposer > xParser = createParser_nothrow();
- const ::rtl::OUString sOldFilter = xParser->getFilter();
- const ::rtl::OUString sOldHaving = xParser->getHavingClause();
+ const OUString sOldFilter = xParser->getFilter();
+ const OUString sOldHaving = xParser->getHavingClause();
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
sal_Bool bApplied =
::comphelper::getBOOL(xFormSet->getPropertyValue(PROPERTY_APPLYFILTER));
@@ -2213,7 +2213,7 @@
// -> completely overwrite it, else append one
if (!bApplied)
{
- DO_SAFE( (bHaving ? xParser->setHavingClause(::rtl::OUString()) :
xParser->setFilter(::rtl::OUString())), "SbaXDataBrowserController::Execute : caught an exception
while resetting the new filter !" );
+ DO_SAFE( (bHaving ? xParser->setHavingClause(OUString()) :
xParser->setFilter(::OUString())), "SbaXDataBrowserController::Execute : caught an exception while
resetting the new filter !" );
}
sal_Bool bParserSuccess = sal_False;
@@ -2267,9 +2267,9 @@
Reference< XPropertySet > xSet(getRowSet(), UNO_QUERY);
if ( xSet.is() )
{
- xSet->setPropertyValue(PROPERTY_FILTER,makeAny(::rtl::OUString()));
- xSet->setPropertyValue(PROPERTY_HAVING_CLAUSE,makeAny(::rtl::OUString()));
- xSet->setPropertyValue(PROPERTY_ORDER,makeAny(::rtl::OUString()));
+ xSet->setPropertyValue(PROPERTY_FILTER,makeAny(OUString()));
+ xSet->setPropertyValue(PROPERTY_HAVING_CLAUSE,makeAny(OUString()));
+ xSet->setPropertyValue(PROPERTY_ORDER,makeAny(OUString()));
}
try
{
@@ -2522,7 +2522,7 @@
// the case 'no columns' should be indicated with an empty container, I think ...
OSL_ENSURE(xModelColumns->getCount() >= xPeerContainer->getCount(),
"SbaXDataBrowserController::OnSearchContextRequest : impossible : have more view than model columns
!");
- String sFieldList;
+ OUString sFieldList;
for (sal_Int32 nViewPos=0; nViewPos<xPeerContainer->getCount(); ++nViewPos)
{
Reference< XInterface > xCurrentColumn(xPeerContainer->getByIndex(nViewPos),UNO_QUERY);
@@ -2535,10 +2535,10 @@
sal_uInt16 nModelPos = getBrowserView()->View2ModelPos((sal_uInt16)nViewPos);
Reference< XPropertySet >
xCurrentColModel(xModelColumns->getByIndex(nModelPos),UNO_QUERY);
- String aName =
::comphelper::getString(xCurrentColModel->getPropertyValue(PROPERTY_CONTROLSOURCE));
+ OUString aName =
::comphelper::getString(xCurrentColModel->getPropertyValue(PROPERTY_CONTROLSOURCE));
sFieldList += aName;
- sFieldList += ';';
+ sFieldList += OUString(";");
pContext->arrFields.push_back(xCurrentColumn);
}
@@ -2571,9 +2571,9 @@
// let the grid snyc it's display with the cursor
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::OnFoundData : no model set ?!");
- Any aOld =
xModelSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
aOld);
+ Any aOld = xModelSet->getPropertyValue(OUString("DisplayIsSynchron"));
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"), aOld);
// and move to the field
Reference< ::com::sun::star::container::XIndexAccess >
aColumnControls(getBrowserView()->getGridControl()->getPeer(), UNO_QUERY);
@@ -2618,9 +2618,9 @@
// let the grid snyc its display with the cursor
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::OnCanceledNotFound : no model set
?!");
- Any aOld =
xModelSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")));
-
xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
-
xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")),
aOld);
+ Any aOld = xModelSet->getPropertyValue(OUString("DisplayIsSynchron"));
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"),
::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(OUString("DisplayIsSynchron"), aOld);
}
catch( const Exception& )
{
diff --git a/dbaccess/source/ui/browser/brwview.cxx b/dbaccess/source/ui/browser/brwview.cxx
index c29ea1d..4b523fc 100644
--- a/dbaccess/source/ui/browser/brwview.cxx
+++ b/dbaccess/source/ui/browser/brwview.cxx
@@ -175,9 +175,9 @@
}
}
// -------------------------------------------------------------------------
-void UnoDataBrowserView::showStatus( const String& _rStatus )
+void UnoDataBrowserView::showStatus( const OUString& _rStatus )
{
- if (0 == _rStatus.Len())
+ if (0 == _rStatus.getLength())
hideStatus();
else
{
@@ -341,7 +341,7 @@
DBG_NAME(BrowserViewStatusDisplay)
// -----------------------------------------------------------------------------
-BrowserViewStatusDisplay::BrowserViewStatusDisplay( UnoDataBrowserView* _pView, const String&
_rStatus )
+BrowserViewStatusDisplay::BrowserViewStatusDisplay( UnoDataBrowserView* _pView, const OUString&
_rStatus )
:m_pView(_pView)
{
DBG_CTOR(BrowserViewStatusDisplay,NULL);
@@ -354,7 +354,7 @@
BrowserViewStatusDisplay::~BrowserViewStatusDisplay( )
{
if (m_pView)
- m_pView->showStatus(String());
+ m_pView->showStatus(OUString());
DBG_DTOR(BrowserViewStatusDisplay,NULL);
}
diff --git a/dbaccess/source/ui/browser/dbexchange.cxx b/dbaccess/source/ui/browser/dbexchange.cxx
index a9c1940..0d048ac 100644
--- a/dbaccess/source/ui/browser/dbexchange.cxx
+++ b/dbaccess/source/ui/browser/dbexchange.cxx
@@ -62,13 +62,13 @@
// -----------------------------------------------------------------------------
ODataClipboard::ODataClipboard(
- const ::rtl::OUString& _rDatasource,
+ const OUString& _rDatasource,
const sal_Int32 _nCommandType,
- const ::rtl::OUString& _rCommand,
+ const OUString& _rCommand,
const Reference< XConnection >& _rxConnection,
const Reference< XNumberFormatter >& _rxFormatter,
const Reference< XComponentContext >& _rxORB)
- :ODataAccessObjectTransferable( _rDatasource,::rtl::OUString(), _nCommandType,
_rCommand, _rxConnection )
+ :ODataAccessObjectTransferable( _rDatasource,OUString(), _nCommandType,
_rCommand, _rxConnection )
,m_pHtml(NULL)
,m_pRtf(NULL)
{
@@ -83,12 +83,12 @@
// -----------------------------------------------------------------------------
ODataClipboard::ODataClipboard(
- const ::rtl::OUString& _rDatasource,
+ const OUString& _rDatasource,
const sal_Int32 _nCommandType,
- const ::rtl::OUString& _rCommand,
+ const OUString& _rCommand,
const Reference< XNumberFormatter >& _rxFormatter,
const Reference< XComponentContext >& _rxORB)
- :ODataAccessObjectTransferable( _rDatasource, ::rtl::OUString(),_nCommandType, _rCommand)
+ :ODataAccessObjectTransferable( _rDatasource, OUString(),_nCommandType, _rCommand)
,m_pHtml(NULL)
,m_pRtf(NULL)
{
diff --git a/dbaccess/source/ui/browser/dbloader.cxx b/dbaccess/source/ui/browser/dbloader.cxx
index 1f4a3be..4f9d37e 100644
--- a/dbaccess/source/ui/browser/dbloader.cxx
+++ b/dbaccess/source/ui/browser/dbloader.cxx
@@ -64,7 +64,7 @@
class DBContentLoader : public ::cppu::WeakImplHelper2< XFrameLoader, XServiceInfo>
{
private:
- ::rtl::OUString m_aURL;
+ OUString m_aURL;
Sequence< PropertyValue> m_aArgs;
Reference< XLoadEventListener > m_xListener;
Reference< XFrame > m_xFrame;
@@ -74,21 +74,21 @@
~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.dbu.DBContentLoader"));
+ return OUString("org.openoffice.comp.dbu.DBContentLoader");
}
- 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();
@@ -121,18 +121,18 @@
}
// -------------------------------------------------------------------------
// 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;
@@ -140,17 +140,17 @@
}
// -------------------------------------------------------------------------
// 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( 2 );
- aSNS.getArray()[0] =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.FrameLoader"));
- aSNS.getArray()[1] =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ContentLoader"));
+ Sequence< OUString > aSNS( 2 );
+ aSNS.getArray()[0] = OUString("com.sun.star.frame.FrameLoader");
+ aSNS.getArray()[1] = OUString("com.sun.star.sdb.ContentLoader");
return aSNS;
}
// -------------------------------------------------------------------------
@@ -159,21 +159,21 @@
Reference< XRegistryKey> xKey(reinterpret_cast< XRegistryKey*>(pRegistryKey));
// register content loader for dispatch
- ::rtl::OUString aImpl(RTL_CONSTASCII_USTRINGPARAM("/"));
+ OUString aImpl("/");
aImpl += 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(".component:DB*")) );
+ xNewKey = xLoaderKey->createKey( OUString("Pattern") );
+ xNewKey->setAsciiValue( OUString(".component:DB*") );
}
// -----------------------------------------------------------------------
-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)
{
@@ -203,13 +203,13 @@
INetURLObject aParser( rURL );
Reference< XController2 > xController;
- const ::rtl::OUString sComponentURL( aParser.GetMainURL( INetURLObject::DECODE_TO_IURI ) );
+ const OUString sComponentURL( aParser.GetMainURL( INetURLObject::DECODE_TO_IURI ) );
for ( size_t i=0; i < sizeof( aImplementations ) / sizeof( aImplementations[0] ); ++i )
{
if ( sComponentURL.equalsAscii( aImplementations[i].pAsciiServiceName ) )
{
xController.set( m_xContext->getServiceManager()->
- createInstanceWithContext( ::rtl::OUString::createFromAscii(
aImplementations[i].pAsciiImplementationName ), m_xContext), UNO_QUERY_THROW );
+ createInstanceWithContext( OUString::createFromAscii(
aImplementations[i].pAsciiImplementationName ), m_xContext), UNO_QUERY_THROW );
break;
}
}
@@ -222,14 +222,14 @@
if ( sComponentURL == URL_COMPONENT_DATASOURCEBROWSER )
{
sal_Bool bDisableBrowser = ( sal_False == aLoadArgs.getOrDefault( "ShowTreeViewButton",
sal_True ) ) // compatibility name
- || ( sal_False == aLoadArgs.getOrDefault(
(::rtl::OUString)PROPERTY_ENABLE_BROWSER, sal_True ) );
+ || ( sal_False == aLoadArgs.getOrDefault(
(OUString)PROPERTY_ENABLE_BROWSER, sal_True ) );
if ( bDisableBrowser )
{
try
{
Reference< XModule > xModule( xController, UNO_QUERY_THROW );
- xModule->setIdentifier( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.sdb.TableDataView" ) ) );
+ xModule->setIdentifier( OUString( "com.sun.star.sdb.TableDataView" ) );
}
catch( const Exception& )
{
@@ -262,7 +262,7 @@
if ( bSuccess )
{
Reference< XDataSource > xDataSource ( aLoadArgs.getOrDefault( "DataSource",
Reference< XDataSource >() ) );
- ::rtl::OUString sDataSourceName( aLoadArgs.getOrDefault( "DataSourceName",
::rtl::OUString() ) );
+ OUString sDataSourceName( aLoadArgs.getOrDefault( "DataSourceName", OUString()
) );
Reference< XConnection > xConnection ( aLoadArgs.getOrDefault( "ActiveConnection",
Reference< XConnection >() ) );
if ( xDataSource.is() )
{
@@ -290,7 +290,7 @@
try
{
Reference<XInitialization > xIni(xController,UNO_QUERY);
- PropertyValue
aFrame(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Frame")),0,makeAny(rFrame),PropertyState_DIRECT_VALUE);
+ PropertyValue aFrame(OUString("Frame"),0,makeAny(rFrame),PropertyState_DIRECT_VALUE);
Sequence< Any > aInitArgs(m_aArgs.getLength()+1);
Any* pBegin = aInitArgs.getArray();
diff --git a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
index 8e02c7a..b701465 100644
--- a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
+++ b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
@@ -54,7 +54,7 @@
}
// -----------------------------------------------------------------------------
-String SbaTableQueryBrowser::GetEntryText( SvTreeListEntry* _pEntry ) const
+OUString SbaTableQueryBrowser::GetEntryText( SvTreeListEntry* _pEntry ) const
{
return m_pTreeView->getListBox().GetEntryText(_pEntry);
}
@@ -71,7 +71,7 @@
SvTreeListEntry* pQueries = m_pTreeView->getListBox().GetEntry(pRootEntry,
CONTAINER_QUERIES);
#ifdef DBG_UTIL
- String sTest;
+ OUString sTest;
if (pTables) sTest = m_pTreeView->getListBox().GetEntryText(pTables);
if (pQueries) sTest = m_pTreeView->getListBox().GetEntryText(pQueries);
#endif
diff --git a/dbaccess/source/ui/browser/dsbrowserDnD.cxx
b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
index c177474..9f3f298 100644
--- a/dbaccess/source/ui/browser/dsbrowserDnD.cxx
+++ b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
@@ -68,8 +68,8 @@
{
try
{
- ::rtl::OUString aName = GetEntryText( _pApplyTo );
- ::rtl::OUString aDSName = getDataSourceAcessor(
m_pTreeView->getListBox().GetRootLevelParent( _pApplyTo ) );
+ OUString aName = GetEntryText( _pApplyTo );
+ OUString aDSName = getDataSourceAcessor( m_pTreeView->getListBox().GetRootLevelParent(
_pApplyTo ) );
ODataClipboard* pData = NULL;
SharedConnection xConnection;
@@ -146,7 +146,7 @@
m_aAsyncDrop.bError = sal_False;
m_aAsyncDrop.bHtml = sal_False;
m_aAsyncDrop.pDroppedAt = NULL;
- m_aAsyncDrop.aUrl = ::rtl::OUString();
+ m_aAsyncDrop.aUrl = OUString();
// loop through the available formats and see what we can do ...
diff --git a/dbaccess/source/ui/browser/exsrcbrw.cxx b/dbaccess/source/ui/browser/exsrcbrw.cxx
index e3b0c17..9d85be1 100644
--- a/dbaccess/source/ui/browser/exsrcbrw.cxx
+++ b/dbaccess/source/ui/browser/exsrcbrw.cxx
@@ -85,15 +85,15 @@
return getSupportedServiceNames_Static();
}
// -------------------------------------------------------------------------
-::rtl::OUString SbaExternalSourceBrowser::getImplementationName_Static() throw(RuntimeException)
+OUString SbaExternalSourceBrowser::getImplementationName_Static() throw(RuntimeException)
{
- return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.OFormGridView"));
+ return OUString("org.openoffice.comp.dbu.OFormGridView");
}
//-------------------------------------------------------------------------
::comphelper::StringSequence SbaExternalSourceBrowser::getSupportedServiceNames_Static()
throw(RuntimeException)
{
::comphelper::StringSequence aSupported(1);
- aSupported.getArray()[0] =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.FormGridView"));
+ aSupported.getArray()[0] = OUString("com.sun.star.sdb.FormGridView");
return aSupported;
}
//-------------------------------------------------------------------------
@@ -102,7 +102,7 @@
return *(new SbaExternalSourceBrowser( comphelper::getComponentContext(_rxFactory)));
}
//-------------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaExternalSourceBrowser::getImplementationName() throw(RuntimeException)
+OUString SAL_CALL SbaExternalSourceBrowser::getImplementationName() throw(RuntimeException)
{
return getImplementationName_Static();
}
@@ -147,7 +147,7 @@
if ( aURL.Complete == ".uno:FormSlots/AddGridColumn" )
{
// search the argument describing the column to create
- ::rtl::OUString sControlType;
+ OUString sControlType;
sal_Int32 nControlPos = -1;
Sequence< ::com::sun::star::beans::PropertyValue> aControlProps;
sal_uInt16 i;
@@ -155,7 +155,7 @@
{
if ( pArguments->Name == "ColumnType" )
{
- sal_Bool bCorrectType =
pArguments->Value.getValueType().equals(::getCppuType((const ::rtl::OUString*)0));
+ sal_Bool bCorrectType =
pArguments->Value.getValueType().equals(::getCppuType((const OUString*)0));
OSL_ENSURE(bCorrectType, "invalid type for argument \"ColumnType\" !");
if (bCorrectType)
sControlType = ::comphelper::getString(pArguments->Value);
@@ -175,12 +175,12 @@
aControlProps = *(Sequence<
::com::sun::star::beans::PropertyValue>*)pArguments->Value.getValue();
}
else
- OSL_FAIL(rtl::OStringBuffer("SbaExternalSourceBrowser::dispatch(AddGridColumn) :
unknown argument (").append(rtl::OUStringToOString(pArguments->Name,
osl_getThreadTextEncoding())).append(") !").getStr());
+ OSL_FAIL(rtl::OStringBuffer("SbaExternalSourceBrowser::dispatch(AddGridColumn) :
unknown argument (").append(OUStringToOString(pArguments->Name,
osl_getThreadTextEncoding())).append(") !").getStr());
}
if (sControlType.isEmpty())
{
OSL_FAIL("SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument
(ColumnType) !");
- sControlType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TextField"));
+ sControlType = OUString("TextField");
}
OSL_ENSURE(aControlProps.getLength(), "SbaExternalSourceBrowser::dispatch(AddGridColumn) :
missing argument (ColumnProperties) !");
@@ -203,7 +203,7 @@
}
catch (const Exception&)
{
-
OSL_FAIL(rtl::OStringBuffer(RTL_CONSTASCII_STRINGPARAM("SbaExternalSourceBrowser::dispatch : could
not set a column property (")).append(rtl::OUStringToOString(pControlProps->Name,
RTL_TEXTENCODING_ASCII_US)).append(RTL_CONSTASCII_STRINGPARAM(")!")).getStr());
+ OSL_FAIL(rtl::OStringBuffer("SbaExternalSourceBrowser::dispatch : could not
set a column property (").append(OUStringToOString(pControlProps->Name,
RTL_TEXTENCODING_ASCII_US)).append(")!").getStr());
}
}
}
@@ -251,7 +251,7 @@
}
//------------------------------------------------------------------
-Reference< ::com::sun::star::frame::XDispatch > SAL_CALL
SbaExternalSourceBrowser::queryDispatch(const ::com::sun::star::util::URL& aURL, const
::rtl::OUString& aTargetFrameName, sal_Int32 nSearchFlags) throw( RuntimeException )
+Reference< ::com::sun::star::frame::XDispatch > SAL_CALL
SbaExternalSourceBrowser::queryDispatch(const ::com::sun::star::util::URL& aURL, const OUString&
aTargetFrameName, sal_Int32 nSearchFlags) throw( RuntimeException )
{
Reference< ::com::sun::star::frame::XDispatch > xReturn;
if (m_bInQueryDispatch)
@@ -284,7 +284,7 @@
m_xUrlTransformer->parseStrict( aNewUrl );
// set a new mark
- aNewUrl.Mark = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DB/FormGridView"));
+ aNewUrl.Mark = OUString("DB/FormGridView");
// this controller is instantiated when somebody dispatches the
".component:DB/FormGridView" in any
// frame, so we use "FormGridView" as mark that a dispatch request came from this view
diff --git a/dbaccess/source/ui/browser/formadapter.cxx b/dbaccess/source/ui/browser/formadapter.cxx
index fde5f2c..9132873 100644
--- a/dbaccess/source/ui/browser/formadapter.cxx
+++ b/dbaccess/source/ui/browser/formadapter.cxx
@@ -164,7 +164,7 @@
if (m_aPropertiesChangeListeners.getLength())
{
Reference< ::com::sun::star::beans::XMultiPropertySet > xBroadcaster(m_xMainForm,
UNO_QUERY);
- ::rtl::OUString sEmpty;
+ OUString sEmpty;
if (xBroadcaster.is())
xBroadcaster->addPropertiesChangeListener(::comphelper::StringSequence(&sEmpty, 1),
&m_aPropertiesChangeListeners);
}
@@ -240,7 +240,7 @@
// ::com::sun::star::sdbc::XColumnLocate
// -------------------------------------------------------------------------
-sal_Int32 SAL_CALL SbaXFormAdapter::findColumn(const ::rtl::OUString& columnName) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
+sal_Int32 SAL_CALL SbaXFormAdapter::findColumn(const OUString& columnName) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
{
Reference< ::com::sun::star::sdbc::XColumnLocate > xIface(m_xMainForm, UNO_QUERY);
if (xIface.is())
@@ -268,12 +268,12 @@
return sal_True;
}
// -------------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXFormAdapter::getString(sal_Int32 columnIndex) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
+OUString SAL_CALL SbaXFormAdapter::getString(sal_Int32 columnIndex) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
{
Reference< ::com::sun::star::sdbc::XRow > xIface(m_xMainForm, UNO_QUERY);
if (xIface.is())
return xIface->getString(columnIndex);
- return ::rtl::OUString();
+ return OUString();
}
// -------------------------------------------------------------------------
sal_Bool SAL_CALL SbaXFormAdapter::getBoolean(sal_Int32 columnIndex) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
@@ -530,7 +530,7 @@
xIface->updateDouble(columnIndex, x);
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::updateString(sal_Int32 columnIndex, const ::rtl::OUString& x)
throw( ::com::sun::star::sdbc::SQLException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::updateString(sal_Int32 columnIndex, const OUString& x) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
{
Reference< ::com::sun::star::sdbc::XRowUpdate > xIface(m_xMainForm, UNO_QUERY);
if (xIface.is())
@@ -860,7 +860,7 @@
xIface->setNull(parameterIndex, sqlType);
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setObjectNull(sal_Int32 parameterIndex, sal_Int32 sqlType, const
::rtl::OUString& typeName) throw( ::com::sun::star::sdbc::SQLException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::setObjectNull(sal_Int32 parameterIndex, sal_Int32 sqlType, const
OUString& typeName) throw( ::com::sun::star::sdbc::SQLException, RuntimeException )
{
Reference< ::com::sun::star::sdbc::XParameters > xIface(m_xMainForm, UNO_QUERY);
if (xIface.is())
@@ -916,7 +916,7 @@
xIface->setDouble(parameterIndex, x);
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setString(sal_Int32 parameterIndex, const ::rtl::OUString& x)
throw( ::com::sun::star::sdbc::SQLException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::setString(sal_Int32 parameterIndex, const OUString& x) throw(
::com::sun::star::sdbc::SQLException, RuntimeException )
{
Reference< ::com::sun::star::sdbc::XParameters > xIface(m_xMainForm, UNO_QUERY);
if (xIface.is())
@@ -1091,7 +1091,7 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setGroup(const Sequence< Reference<
::com::sun::star::awt::XControlModel > >& /*_rGroup*/, const ::rtl::OUString& /*GroupName*/)
throw( RuntimeException )
+void SAL_CALL SbaXFormAdapter::setGroup(const Sequence< Reference<
::com::sun::star::awt::XControlModel > >& /*_rGroup*/, const OUString& /*GroupName*/) throw(
RuntimeException )
{
OSL_FAIL("SAL_CALL SbaXFormAdapter::setGroup : not supported !");
}
@@ -1104,13 +1104,13 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::getGroup(sal_Int32 /*nGroup*/, Sequence< Reference<
::com::sun::star::awt::XControlModel > >& /*_rGroup*/, ::rtl::OUString& /*Name*/) throw(
RuntimeException )
+void SAL_CALL SbaXFormAdapter::getGroup(sal_Int32 /*nGroup*/, Sequence< Reference<
::com::sun::star::awt::XControlModel > >& /*_rGroup*/, OUString& /*Name*/) throw( RuntimeException
)
{
OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroup : not supported !");
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::getGroupByName(const ::rtl::OUString& /*Name*/, Sequence<
Reference< ::com::sun::star::awt::XControlModel > >& /*_rGroup*/) throw( RuntimeException )
+void SAL_CALL SbaXFormAdapter::getGroupByName(const OUString& /*Name*/, Sequence< Reference<
::com::sun::star::awt::XControlModel > >& /*_rGroup*/) throw( RuntimeException )
{
OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroupByName : not supported !");
}
@@ -1220,25 +1220,25 @@
// ::com::sun::star::container::XNamed
// -------------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXFormAdapter::getName() throw( RuntimeException )
+OUString SAL_CALL SbaXFormAdapter::getName() throw( RuntimeException )
{
return ::comphelper::getString(getPropertyValue(PROPERTY_NAME));
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setName(const ::rtl::OUString& aName) throw( RuntimeException )
+void SAL_CALL SbaXFormAdapter::setName(const OUString& aName) throw( RuntimeException )
{
setPropertyValue(PROPERTY_NAME, makeAny(aName));
}
// ::com::sun::star::io::XPersistObject
// -------------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXFormAdapter::getServiceName() throw( RuntimeException )
+OUString SAL_CALL SbaXFormAdapter::getServiceName() throw( RuntimeException )
{
Reference< ::com::sun::star::io::XPersistObject > xPersist(m_xMainForm, UNO_QUERY);
if (xPersist.is())
return xPersist->getServiceName();
- return ::rtl::OUString();
+ return OUString();
}
// -------------------------------------------------------------------------
@@ -1285,7 +1285,7 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setPropertyValues(const Sequence< ::rtl::OUString >& PropertyNames,
const Sequence< Any >& Values) throw( ::com::sun::star::beans::PropertyVetoException,
::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
+void SAL_CALL SbaXFormAdapter::setPropertyValues(const Sequence< OUString >& PropertyNames, const
Sequence< Any >& Values) throw( ::com::sun::star::beans::PropertyVetoException,
::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
{
Reference< ::com::sun::star::beans::XMultiPropertySet > xSet(m_xMainForm, UNO_QUERY);
if (xSet.is())
@@ -1293,7 +1293,7 @@
}
// -------------------------------------------------------------------------
-Sequence< Any > SAL_CALL SbaXFormAdapter::getPropertyValues(const Sequence< ::rtl::OUString >&
aPropertyNames) throw( RuntimeException )
+Sequence< Any > SAL_CALL SbaXFormAdapter::getPropertyValues(const Sequence< OUString >&
aPropertyNames) throw( RuntimeException )
{
Reference< ::com::sun::star::beans::XMultiPropertySet > xSet(m_xMainForm, UNO_QUERY);
if (!xSet.is())
@@ -1302,7 +1302,7 @@
Sequence< Any> aReturn = xSet->getPropertyValues(aPropertyNames);
// search for (and fake) the NAME property
- const ::rtl::OUString* pNames = aPropertyNames.getConstArray();
+ const OUString* pNames = aPropertyNames.getConstArray();
Any* pValues = aReturn.getArray();
OSL_ENSURE(aReturn.getLength() == aPropertyNames.getLength(), "SAL_CALL
SbaXFormAdapter::getPropertyValues : the main form returned an invalid-length sequence !");
for (sal_Int32 i=0; i<aPropertyNames.getLength(); ++i, ++pNames, ++pValues)
@@ -1316,16 +1316,16 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::addPropertiesChangeListener(const Sequence< ::rtl::OUString>&
/*aPropertyNames*/, const Reference< ::com::sun::star::beans::XPropertiesChangeListener >&
xListener) throw( RuntimeException )
+void SAL_CALL SbaXFormAdapter::addPropertiesChangeListener(const Sequence< OUString>&
/*aPropertyNames*/, const Reference< ::com::sun::star::beans::XPropertiesChangeListener >&
xListener) throw( RuntimeException )
{
// we completely ignore the property names, _all_ changes of _all_ properties will be
forwarded to _all_ listeners
m_aPropertiesChangeListeners.addInterface(xListener);
if (m_aPropertiesChangeListeners.getLength() == 1)
{
Reference< ::com::sun::star::beans::XMultiPropertySet > xBroadcaster(m_xMainForm,
UNO_QUERY);
- ::rtl::OUString sEmpty;
+ OUString sEmpty;
if (xBroadcaster.is())
- xBroadcaster->addPropertiesChangeListener(Sequence< ::rtl::OUString>(&sEmpty, 1),
&m_aPropertiesChangeListeners);
+ xBroadcaster->addPropertiesChangeListener(Sequence< OUString>(&sEmpty, 1),
&m_aPropertiesChangeListeners);
}
}
@@ -1342,7 +1342,7 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::firePropertiesChangeEvent(const Sequence< ::rtl::OUString >&
aPropertyNames, const Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener)
throw( RuntimeException )
+void SAL_CALL SbaXFormAdapter::firePropertiesChangeEvent(const Sequence< OUString >&
aPropertyNames, const Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener)
throw( RuntimeException )
{
Reference< ::com::sun::star::beans::XMultiPropertySet > xSet(m_xMainForm, UNO_QUERY);
if (xSet.is())
@@ -1352,7 +1352,7 @@
// ::com::sun::star::beans::XPropertySet
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setPropertyValue(const ::rtl::OUString& aPropertyName, const Any&
aValue) throw( ::com::sun::star::beans::UnknownPropertyException,
::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::setPropertyValue(const OUString& aPropertyName, const Any& aValue)
throw( ::com::sun::star::beans::UnknownPropertyException,
::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertySet > xSet(m_xMainForm, UNO_QUERY);
if (!xSet.is())
@@ -1366,7 +1366,7 @@
}
// -------------------------------------------------------------------------
-Any SAL_CALL SbaXFormAdapter::getPropertyValue(const ::rtl::OUString& PropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
+Any SAL_CALL SbaXFormAdapter::getPropertyValue(const OUString& PropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertySet > xSet(m_xMainForm, UNO_QUERY);
if (!xSet.is())
@@ -1394,7 +1394,7 @@
// ::com::sun::star::beans::XPropertyState
// -------------------------------------------------------------------------
-::com::sun::star::beans::PropertyState SAL_CALL SbaXFormAdapter::getPropertyState(const
::rtl::OUString& PropertyName) throw( ::com::sun::star::beans::UnknownPropertyException,
RuntimeException )
+::com::sun::star::beans::PropertyState SAL_CALL SbaXFormAdapter::getPropertyState(const OUString&
PropertyName) throw( ::com::sun::star::beans::UnknownPropertyException, RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertyState > xState(m_xMainForm, UNO_QUERY);
if (xState.is())
@@ -1403,7 +1403,7 @@
}
// -------------------------------------------------------------------------
-Sequence< ::com::sun::star::beans::PropertyState> SAL_CALL
SbaXFormAdapter::getPropertyStates(const Sequence< ::rtl::OUString >& aPropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, RuntimeException )
+Sequence< ::com::sun::star::beans::PropertyState> SAL_CALL
SbaXFormAdapter::getPropertyStates(const Sequence< OUString >& aPropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertyState > xState(m_xMainForm, UNO_QUERY);
if (xState.is())
@@ -1418,7 +1418,7 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::setPropertyToDefault(const ::rtl::OUString& PropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::setPropertyToDefault(const OUString& PropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertyState > xState(m_xMainForm, UNO_QUERY);
if (xState.is())
@@ -1426,7 +1426,7 @@
}
// -------------------------------------------------------------------------
-Any SAL_CALL SbaXFormAdapter::getPropertyDefault(const ::rtl::OUString& aPropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
+Any SAL_CALL SbaXFormAdapter::getPropertyDefault(const OUString& aPropertyName) throw(
::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
{
Reference< ::com::sun::star::beans::XPropertyState > xState(m_xMainForm, UNO_QUERY);
if (xState.is())
@@ -1447,7 +1447,7 @@
// ::com::sun::star::container::XNameContainer
// -------------------------------------------------------------------------
-void SbaXFormAdapter::implInsert(const Any& aElement, sal_Int32 nIndex, const ::rtl::OUString*
pNewElName) throw( ::com::sun::star::lang::IllegalArgumentException )
+void SbaXFormAdapter::implInsert(const Any& aElement, sal_Int32 nIndex, const OUString*
pNewElName) throw( ::com::sun::star::lang::IllegalArgumentException )
{
// extract the form component
if (aElement.getValueType().getTypeClass() != TypeClass_INTERFACE)
@@ -1467,7 +1467,7 @@
{
throw ::com::sun::star::lang::IllegalArgumentException();
}
- ::rtl::OUString sName;
+ OUString sName;
try
{
if (pNewElName)
@@ -1507,11 +1507,11 @@
}
// -------------------------------------------------------------------------
-sal_Int32 SbaXFormAdapter::implGetPos(const ::rtl::OUString& rName)
+sal_Int32 SbaXFormAdapter::implGetPos(const OUString& rName)
{
- ::std::vector< ::rtl::OUString>::iterator aIter = ::std::find_if( m_aChildNames.begin(),
+ ::std::vector< OUString>::iterator aIter = ::std::find_if( m_aChildNames.begin(),
m_aChildNames.end(),
- ::std::bind2nd(::std::equal_to<
rtl::OUString>(),rName));
+ ::std::bind2nd(::std::equal_to<
OUString>(),rName));
if(aIter != m_aChildNames.end())
return aIter - m_aChildNames.begin();
@@ -1520,13 +1520,13 @@
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::insertByName(const ::rtl::OUString& aName, const Any& aElement)
throw( ::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::container::ElementExistException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
+void SAL_CALL SbaXFormAdapter::insertByName(const OUString& aName, const Any& aElement) throw(
::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::container::ElementExistException, ::com::sun::star::lang::WrappedTargetException,
RuntimeException )
{
implInsert(aElement, m_aChildren.size(), &aName);
}
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::removeByName(const ::rtl::OUString& Name) throw(
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::removeByName(const OUString& Name) throw(
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
sal_Int32 nPos = implGetPos(Name);
if (-1 == nPos)
@@ -1538,7 +1538,7 @@
// ::com::sun::star::container::XNameReplace
// -------------------------------------------------------------------------
-void SAL_CALL SbaXFormAdapter::replaceByName(const ::rtl::OUString& aName, const Any& aElement)
throw( ::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
+void SAL_CALL SbaXFormAdapter::replaceByName(const OUString& aName, const Any& aElement) throw(
::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
sal_Int32 nPos = implGetPos(aName);
if (-1 == nPos)
@@ -1550,7 +1550,7 @@
// ::com::sun::star::container::XNameAccess
// -------------------------------------------------------------------------
-Any SAL_CALL SbaXFormAdapter::getByName(const ::rtl::OUString& aName) throw(
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
+Any SAL_CALL SbaXFormAdapter::getByName(const OUString& aName) throw(
::com::sun::star::container::NoSuchElementException,
::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
sal_Int32 nPos = implGetPos(aName);
if (-1 == nPos)
@@ -1561,14 +1561,14 @@
}
// -------------------------------------------------------------------------
-Sequence< ::rtl::OUString > SAL_CALL SbaXFormAdapter::getElementNames() throw( RuntimeException )
+Sequence< OUString > SAL_CALL SbaXFormAdapter::getElementNames() throw( RuntimeException )
{
- ::rtl::OUString *pChildNames = m_aChildNames.empty() ? 0 : &m_aChildNames[0];
- return Sequence< ::rtl::OUString >(pChildNames, m_aChildNames.size());
+ OUString *pChildNames = m_aChildNames.empty() ? 0 : &m_aChildNames[0];
+ return Sequence< OUString >(pChildNames, m_aChildNames.size());
}
// -------------------------------------------------------------------------
-sal_Bool SAL_CALL SbaXFormAdapter::hasByName(const ::rtl::OUString& aName) throw( RuntimeException
)
+sal_Bool SAL_CALL SbaXFormAdapter::hasByName(const OUString& aName) throw( RuntimeException )
{
return (-1 != implGetPos(aName));
}
@@ -1651,7 +1651,7 @@
{
throw ::com::sun::star::lang::IllegalArgumentException();
}
- ::rtl::OUString sName;
+ OUString sName;
try
{
xElementSet->getPropertyValue(PROPERTY_NAME) >>= sName;
diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx
b/dbaccess/source/ui/browser/genericcontroller.cxx
index c2aa930..71b3c21 100644
--- a/dbaccess/source/ui/browser/genericcontroller.cxx
+++ b/dbaccess/source/ui/browser/genericcontroller.cxx
@@ -86,9 +86,9 @@
// -------------------------------------------------------------------------
-const ::rtl::OUString& getConfirmDeletionURL()
+const OUString& getConfirmDeletionURL()
{
- static const ::rtl::OUString sConfirmDeletionURL( RTL_CONSTASCII_USTRINGPARAM(
".uno:FormSlots/ConfirmDeletion" ) );
+ static const OUString sConfirmDeletionURL( ".uno:FormSlots/ConfirmDeletion" );
return sConfirmDeletionURL;
}
@@ -136,7 +136,7 @@
Reference< XDispatchProvider > xDispatchProvider( xController->getFrame(), UNO_QUERY_THROW
);
Reference< XDispatch > xDispatch( xDispatchProvider->queryDispatch(
_rFeatureURL,
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "_self" ) ),
+ OUString( "_self" ),
FrameSearchFlag::AUTO
) );
@@ -268,7 +268,7 @@
{
OSL_FAIL("OGenericUnoController::Construct: could not create (or start listening at) the
database context!");
// at least notify the user. Though the whole component does not make any sense without
the database context ...
- ShowServiceNotAvailableError(getView(), String("com.sun.star.sdb.DatabaseContext"),
sal_True);
+ ShowServiceNotAvailableError(getView(), OUString("com.sun.star.sdb.DatabaseContext"),
sal_True);
}
return sal_True;
@@ -312,14 +312,14 @@
try
{
if ( !xFrame.is() )
- throw IllegalArgumentException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "need a
frame" ) ), *this, 1 );
+ throw IllegalArgumentException( OUString( "need a frame" ), *this, 1 );
xParent = xFrame->getContainerWindow();
VCLXWindow* pParentComponent = VCLXWindow::GetImplementation(xParent);
Window* pParentWin = pParentComponent ? pParentComponent->GetWindow() : NULL;
if (!pParentWin)
{
- throw IllegalArgumentException( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Parent
window is null")), *this, 1 );
+ throw IllegalArgumentException( OUString( "Parent window is null" ), *this, 1 );
}
m_aInitParameters.assign( aArguments );
@@ -327,7 +327,7 @@
ODataView* pView = getView();
if ( !pView )
- throw RuntimeException( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("unable to create
a view")), *this );
+ throw RuntimeException( OUString( "unable to create a view" ), *this );
if ( m_bReadOnly || m_bPreview )
pView->EnableInput( sal_False );
@@ -398,9 +398,9 @@
}
// -----------------------------------------------------------------------
-::rtl::OUString SAL_CALL OGenericUnoController::getViewControllerName() throw
(::com::sun::star::uno::RuntimeException)
+OUString SAL_CALL OGenericUnoController::getViewControllerName() throw
(::com::sun::star::uno::RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Default" ) );
+ return OUString( "Default" );
}
// -----------------------------------------------------------------------
@@ -486,7 +486,7 @@
}
// -----------------------------------------------------------------------
-void OGenericUnoController::ImplBroadcastFeatureState(const ::rtl::OUString& _rFeature, const
Reference< XStatusListener > & xListener, sal_Bool _bIgnoreCache)
+void OGenericUnoController::ImplBroadcastFeatureState(const OUString& _rFeature, const Reference<
XStatusListener > & xListener, sal_Bool _bIgnoreCache)
{
sal_uInt16 nFeat = m_aSupportedFeatures[ _rFeature ].nFeatureId;
FeatureState aFeatState( GetState( nFeat ) );
@@ -564,7 +564,7 @@
}
// -----------------------------------------------------------------------
-void OGenericUnoController::InvalidateFeature(const ::rtl::OUString& _rURLPath, const Reference<
XStatusListener > & _xListener, sal_Bool _bForceBroadcast)
+void OGenericUnoController::InvalidateFeature(const OUString& _rURLPath, const Reference<
XStatusListener > & _xListener, sal_Bool _bForceBroadcast)
{
ImplInvalidateFeature( m_aSupportedFeatures[ _rURLPath ].nFeatureId, _xListener,
_bForceBroadcast );
}
@@ -691,7 +691,7 @@
}
// -----------------------------------------------------------------------
-Reference< XDispatch > OGenericUnoController::queryDispatch(const URL& aURL, const
::rtl::OUString& aTargetFrameName, sal_Int32 nSearchFlags) throw( RuntimeException )
+Reference< XDispatch > OGenericUnoController::queryDispatch(const URL& aURL, const OUString&
aTargetFrameName, sal_Int32 nSearchFlags) throw( RuntimeException )
{
Reference< XDispatch > xReturn;
@@ -926,7 +926,7 @@
OSL_PRECOND( _nFeatureId < FIRST_USER_DEFINED_FEATURE,
"OGenericUnoController::implDescribeSupportedFeature: invalid feature id!" );
ControllerFeature aFeature;
- aFeature.Command = ::rtl::OUString::createFromAscii( _pAsciiCommandURL );
+ aFeature.Command = OUString::createFromAscii( _pAsciiCommandURL );
aFeature.nFeatureId = _nFeatureId;
aFeature.GroupId = _nCommandGroup;
@@ -1007,7 +1007,7 @@
}
//-------------------------------------------------------------------------
-bool OGenericUnoController::isUserDefinedFeature( const ::rtl::OUString& _rFeatureURL ) const
+bool OGenericUnoController::isUserDefinedFeature( const OUString& _rFeatureURL ) const
{
SupportedFeatures::const_iterator pos = m_aSupportedFeatures.find( _rFeatureURL );
OSL_PRECOND( pos != m_aSupportedFeatures.end(),
@@ -1017,12 +1017,12 @@
}
//-------------------------------------------------------------------------
-sal_Bool SAL_CALL OGenericUnoController::supportsService(const ::rtl::OUString& ServiceName)
throw(RuntimeException)
+sal_Bool SAL_CALL OGenericUnoController::supportsService(const OUString& ServiceName)
throw(RuntimeException)
{
- Sequence< ::rtl::OUString > aSupported(getSupportedServiceNames());
+ Sequence< OUString > aSupported(getSupportedServiceNames());
- const ::rtl::OUString* pArray = aSupported.getConstArray();
- const ::rtl::OUString* pArrayEnd = aSupported.getConstArray() + aSupported.getLength();
+ const OUString* pArray = aSupported.getConstArray();
+ const OUString* pArrayEnd = aSupported.getConstArray() + aSupported.getLength();
for ( ;( pArray != pArrayEnd ) && !pArray->equals( ServiceName ); ++pArray )
;
@@ -1052,15 +1052,15 @@
{
WaitObject aWaitCursor( getView() );
- ODatasourceConnector aConnector( getORB(), getView(), ::rtl::OUString() );
+ ODatasourceConnector aConnector( getORB(), getView(), OUString() );
Reference< XConnection > xConnection = aConnector.connect( _xDataSource, _pErrorInfo );
startConnectionListening( xConnection );
return xConnection;
}
// -----------------------------------------------------------------------------
-Reference< XConnection > OGenericUnoController::connect( const ::rtl::OUString& _rDataSourceName,
- const ::rtl::OUString& _rContextInformation, ::dbtools::SQLExceptionInfo* _pErrorInfo )
+Reference< XConnection > OGenericUnoController::connect( const OUString& _rDataSourceName,
+ const OUString& _rContextInformation, ::dbtools::SQLExceptionInfo* _pErrorInfo )
{
WaitObject aWaitCursor( getView() );
@@ -1085,7 +1085,7 @@
{
try
{
- xLayoutManager.set(xPropSet->getPropertyValue( rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ))),UNO_QUERY);
+ xLayoutManager.set(xPropSet->getPropertyValue( OUString( "LayoutManager" )),UNO_QUERY);
}
catch ( Exception& )
{
@@ -1100,8 +1100,8 @@
if ( xLayoutManager.is() )
{
xLayoutManager->lock();
- xLayoutManager->createElement( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"private:resource/menubar/menubar" )));
- xLayoutManager->createElement( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"private:resource/toolbar/toolbar" )));
+ xLayoutManager->createElement( OUString( "private:resource/menubar/menubar" ));
+ xLayoutManager->createElement( OUString( "private:resource/toolbar/toolbar" ));
xLayoutManager->unlock();
xLayoutManager->doLayout();
}
@@ -1202,7 +1202,7 @@
//------------------------------------------------------------------------------
namespace
{
- ::rtl::OUString lcl_getModuleHelpModuleName( const Reference< XFrame >& _rxFrame )
+ OUString lcl_getModuleHelpModuleName( const Reference< XFrame >& _rxFrame )
{
const sal_Char* pReturn = NULL;
@@ -1231,8 +1231,8 @@
else
{
#if OSL_DEBUG_LEVEL > 0
- Sequence< ::rtl::OUString > sServiceNames = xSI->getSupportedServiceNames();
- const ::rtl::OUString* pLoop = sServiceNames.getConstArray();
+ Sequence< OUString > sServiceNames = xSI->getSupportedServiceNames();
+ const OUString* pLoop = sServiceNames.getConstArray();
for ( sal_Int32 i=0; i<sServiceNames.getLength(); ++i, ++pLoop )
{
sal_Int32 nDummy = 0;
@@ -1260,7 +1260,7 @@
const sal_Char** pHelpModuleName = pTransTable + 1;
for ( sal_Int32 j=0; j<nTableEntries; ++j )
{
- if ( xSI->supportsService( ::rtl::OUString::createFromAscii( *pDocumentService
) ) )
+ if ( xSI->supportsService( OUString::createFromAscii( *pDocumentService ) ) )
{ // found a table entry which matches the model's services
pReturn = *pHelpModuleName;
break;
@@ -1306,16 +1306,16 @@
if ( !pReturn )
pReturn = "swriter";
- return ::rtl::OUString::createFromAscii( pReturn );
+ return OUString::createFromAscii( pReturn );
}
}
// -----------------------------------------------------------------------------
-void OGenericUnoController::openHelpAgent(rtl::OUString const& _suHelpStringURL )
+void OGenericUnoController::openHelpAgent(OUString const& _suHelpStringURL )
{
- rtl::OUString suURL(_suHelpStringURL);
- rtl::OUString sLanguage(RTL_CONSTASCII_USTRINGPARAM("Language="));
+ OUString suURL(_suHelpStringURL);
+ OUString sLanguage( "Language=" );
if (suURL.indexOf(sLanguage) == -1)
{
AppendConfigToken(suURL, sal_False /* sal_False := add '&' */ );
@@ -1343,7 +1343,7 @@
Reference< XDispatchProvider > xDispProv( m_aCurrentFrame.getFrame(), UNO_QUERY );
Reference< XDispatch > xHelpDispatch;
if ( xDispProv.is() )
- xHelpDispatch = xDispProv->queryDispatch(aURL,
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_helpagent")), FrameSearchFlag::PARENT |
FrameSearchFlag::SELF);
+ xHelpDispatch = xDispProv->queryDispatch(aURL, OUString( "_helpagent" ),
FrameSearchFlag::PARENT | FrameSearchFlag::SELF);
OSL_ENSURE(xHelpDispatch.is(), "SbaTableQueryBrowser::openHelpAgent: could not get a
dispatcher!");
if (xHelpDispatch.is())
{
@@ -1398,7 +1398,7 @@
//=============================================================================
// XTitle
-::rtl::OUString SAL_CALL OGenericUnoController::getTitle()
+OUString SAL_CALL OGenericUnoController::getTitle()
throw (RuntimeException)
{
::osl::MutexGuard aGuard( getMutex() );
@@ -1409,7 +1409,7 @@
//=============================================================================
// XTitle
-void SAL_CALL OGenericUnoController::setTitle(const ::rtl::OUString& sTitle)
+void SAL_CALL OGenericUnoController::setTitle(const OUString& sTitle)
throw (RuntimeException)
{
SolarMutexGuard aSolarGuard;
@@ -1480,7 +1480,7 @@
}
// -----------------------------------------------------------------------------
-sal_uInt16 OGenericUnoController::registerCommandURL( const ::rtl::OUString& _rCompleteCommandURL )
+sal_uInt16 OGenericUnoController::registerCommandURL( const OUString& _rCompleteCommandURL )
{
if ( _rCompleteCommandURL.isEmpty() )
return 0;
@@ -1539,7 +1539,7 @@
return aState.bChecked && (sal_Bool)*aState.bChecked;
}
// -----------------------------------------------------------------------------
-sal_Bool OGenericUnoController::isCommandEnabled( const ::rtl::OUString& _rCompleteCommandURL )
const
+sal_Bool OGenericUnoController::isCommandEnabled( const OUString& _rCompleteCommandURL ) const
{
OSL_ENSURE( !_rCompleteCommandURL.isEmpty(), "OGenericUnoController::isCommandEnabled: Empty
command url!" );
diff --git a/dbaccess/source/ui/browser/sbagrid.cxx b/dbaccess/source/ui/browser/sbagrid.cxx
index d1d4198..6b5674c 100644
--- a/dbaccess/source/ui/browser/sbagrid.cxx
+++ b/dbaccess/source/ui/browser/sbagrid.cxx
@@ -129,24 +129,24 @@
//=======================================================================================
//------------------------------------------------------------------------------
-::rtl::OUString SAL_CALL SbaXGridControl::getImplementationName() throw()
+OUString SAL_CALL SbaXGridControl::getImplementationName() throw()
{
return getImplementationName_Static();
}
//------------------------------------------------------------------------------
-::rtl::OUString SbaXGridControl::getImplementationName_Static() throw( RuntimeException )
+OUString SbaXGridControl::getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dbu.SbaXGridControl"));
+ return OUString("com.sun.star.comp.dbu.SbaXGridControl");
}
//------------------------------------------------------------------------------
-Sequence< ::rtl::OUString> SbaXGridControl::getSupportedServiceNames_Static(void) throw(
RuntimeException )
+Sequence< OUString> SbaXGridControl::getSupportedServiceNames_Static(void) throw( RuntimeException
)
{
- Sequence< ::rtl::OUString> aSupported(3);
- aSupported[0] =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.control.InteractionGridControl"));
- aSupported[1] =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.control.GridControl"));
- aSupported[2] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.awt.UnoControl"));
+ Sequence< OUString> aSupported(3);
+ aSupported[0] = OUString("com.sun.star.form.control.InteractionGridControl");
+ aSupported[1] = OUString("com.sun.star.form.control.GridControl");
+ aSupported[2] = OUString("com.sun.star.awt.UnoControl");
return aSupported;
}
DBG_NAME(SbaXGridControl );
@@ -394,7 +394,7 @@
}
//---------------------------------------------------------------------------------------
-Reference< ::com::sun::star::frame::XDispatch > SAL_CALL SbaXGridPeer::queryDispatch(const
::com::sun::star::util::URL& aURL, const ::rtl::OUString& aTargetFrameName, sal_Int32 nSearchFlags)
throw( RuntimeException )
+Reference< ::com::sun::star::frame::XDispatch > SAL_CALL SbaXGridPeer::queryDispatch(const
::com::sun::star::util::URL& aURL, const OUString& aTargetFrameName, sal_Int32 nSearchFlags) throw(
RuntimeException )
{
if ( ( aURL.Complete == ".uno:GridSlots/BrowserAttribs" ) || ( aURL.Complete ==
".uno:GridSlots/RowHeight" )
|| ( aURL.Complete == ".uno:GridSlots/ColumnAttribs" ) || ( aURL.Complete ==
".uno:GridSlots/ColumnWidth" )
@@ -480,17 +480,17 @@
const PropertyValue* pArgs = aArgs.getConstArray();
for (sal_uInt16 i=0; i<aArgs.getLength(); ++i, ++pArgs)
{
- if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnViewPos")))
+ if (pArgs->Name == OUString("ColumnViewPos"))
{
nColId = pGrid->GetColumnIdFromViewPos(::comphelper::getINT16(pArgs->Value));
break;
}
- if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnModelPos")))
+ if (pArgs->Name == OUString("ColumnModelPos"))
{
nColId = pGrid->GetColumnIdFromModelPos(::comphelper::getINT16(pArgs->Value));
break;
}
- if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnId")))
+ if (pArgs->Name == OUString("ColumnId"))
{
nColId = ::comphelper::getINT16(pArgs->Value);
break;
@@ -953,18 +953,18 @@
try
{
PropertyValue aArg;
- aArg.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IntrospectedObject"));
+ aArg.Name = OUString("IntrospectedObject");
aArg.Value <<= xGridModel;
Sequence< Any > aDialogArgs(1);
aDialogArgs[0] <<= aArg;
Reference< XInterface > xDialog = getServiceManager()->createInstanceWithArguments(
- ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.ControlFontDialog")),
+ OUString("com.sun.star.form.ControlFontDialog"),
aDialogArgs
);
if (!xDialog.is())
{
- ShowServiceNotAvailableError(this,
rtl::OUString("com.sun.star.form.ControlFontDialog"), sal_True);
+ ShowServiceNotAvailableError(this, OUString("com.sun.star.form.ControlFontDialog"),
sal_True);
return;
}
@@ -1239,7 +1239,7 @@
Reference< XConnection > xActiveConnection;
// determine the field to drag
- ::rtl::OUString sField;
+ OUString sField;
try
{
xActiveConnection = ::dbtools::getConnection(Reference< XRowSet
(getDataSource(),UNO_QUERY));
@@ -1324,7 +1324,7 @@
// the old implementation copied a SBA_FIELDDATAEXCHANGE_FORMAT, too, (which was rather
expensive to obtain),
// but we have no client for this DnD format anymore (the mail part of SO 5.2 was the only
client)
- ::rtl::OUString sCellText;
+ OUString sCellText;
try
{
Reference< XGridFieldDataSupplier > xFieldData(static_cast< XGridPeer* >(GetPeer()),
UNO_QUERY);
@@ -1500,7 +1500,7 @@
// get the dropped string
TransferableDataHelper aDropped( rEvt.maDropEvent.Transferable );
- String sDropped;
+ OUString sDropped;
if ( !aDropped.GetString( FORMAT_STRING, sDropped ) )
return DND_ACTION_NONE;
@@ -1564,7 +1564,7 @@
BeforeDrop();
if(!pImExport->Read())
{
- String sError = String(ModuleRes(STR_NO_COLUMNNAME_MATCHING));
+ OUString sError = OUString(ModuleRes(STR_NO_COLUMNNAME_MATCHING));
throwGenericSQLException(sError,NULL);
}
AfterDrop();
@@ -1590,13 +1590,13 @@
return 0L;
}
// -------------------------------------------------------------------------
-::rtl::OUString SbaGridControl::GetAccessibleObjectDescription( ::svt::AccessibleBrowseBoxObjType
eObjType,sal_Int32 _nPosition) const
+OUString SbaGridControl::GetAccessibleObjectDescription( ::svt::AccessibleBrowseBoxObjType
eObjType,sal_Int32 _nPosition) const
{
- ::rtl::OUString sRet;
+ OUString sRet;
if ( ::svt::BBTYPE_BROWSEBOX == eObjType )
{
SolarMutexGuard aGuard;
- sRet = String(ModuleRes(STR_DATASOURCE_GRIDCONTROL_DESC));
+ sRet = OUString(ModuleRes(STR_DATASOURCE_GRIDCONTROL_DESC));
}
else
sRet = FmGridControl::GetAccessibleObjectDescription( eObjType,_nPosition);
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index 8f0fdb2..ca8214f 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -1130,7 +1130,7 @@
// -------------------------------------------------------------------------
namespace
{
- bool getDataSourceDisplayName_isURL( const String& _rDS, String& _rDisplayName, String&
_rUniqueId )
+ bool getDataSourceDisplayName_isURL( const OUString& _rDS, OUString& _rDisplayName, OUString&
_rUniqueId )
{
INetURLObject aURL( _rDS );
if ( aURL.GetProtocol() != INET_PROT_NOT_VALID )
@@ -1140,15 +1140,15 @@
return true;
}
_rDisplayName = _rDS;
- _rUniqueId = String();
+ _rUniqueId = OUString();
return false;
}
// .....................................................................
struct FilterByEntryDataId : public IEntryFilter
{
- String sId;
- FilterByEntryDataId( const String& _rId ) : sId( _rId ) { }
+ OUString sId;
+ FilterByEntryDataId( const OUString& _rId ) : sId( _rId ) { }
virtual ~FilterByEntryDataId() {}
@@ -1163,14 +1163,14 @@
}
// -------------------------------------------------------------------------
-String SbaTableQueryBrowser::getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const
+OUString SbaTableQueryBrowser::getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const
{
OSL_ENSURE( _pDataSourceEntry, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry!" );
DBTreeListUserData* pData = static_cast< DBTreeListUserData* >(
_pDataSourceEntry->GetUserData() );
OSL_ENSURE( pData, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry data!" );
OSL_ENSURE( pData->eType == etDatasource, "SbaTableQueryBrowser::getDataSourceAcessor: entry
does not denote a data source!" );
- return pData->sAccessor.Len() ? pData->sAccessor : GetEntryText( _pDataSourceEntry );
+ return ((OUString)pData->sAccessor).getLength() ? (OUString)pData->sAccessor : GetEntryText(
_pDataSourceEntry );
}
// -------------------------------------------------------------------------
@@ -1187,7 +1187,7 @@
if ( m_pTreeView )
{
// look for the data source entry
- String sDisplayName, sDataSourceId;
+ OUString sDisplayName, sDataSourceId;
bool bIsDataSourceURL = getDataSourceDisplayName_isURL( _rDataSource, sDisplayName,
sDataSourceId );
// the display name may differ from the URL for readability reasons
// #i33699#
@@ -1838,23 +1838,22 @@
Reference<XPropertySet> xProp(getRowSet(),UNO_QUERY);
sal_Int32 nCommandType = CommandType::TABLE;
xProp->getPropertyValue(PROPERTY_COMMAND_TYPE) >>= nCommandType;
- String sTitle;
+ OUString sTitle;
switch (nCommandType)
{
case CommandType::TABLE:
- sTitle = String(ModuleRes(STR_TBL_TITLE)); break;
+ sTitle = OUString(ModuleRes(STR_TBL_TITLE)); break;
case CommandType::QUERY:
case CommandType::COMMAND:
- sTitle = String(ModuleRes(STR_QRY_TITLE)); break;
+ sTitle = OUString(ModuleRes(STR_QRY_TITLE)); break;
default:
OSL_FAIL("SbaTableQueryBrowser::GetState: unknown command type!");
}
OUString aName;
xProp->getPropertyValue(PROPERTY_COMMAND) >>= aName;
- String sObject(aName);
+ OUString sObject(aName);
- sTitle.SearchAndReplace(OUString('#'), sObject);
- aReturn.sTitle = sTitle;
+ aReturn.sTitle = sTitle.replaceFirst(OUString('#'), sObject);
aReturn.bEnabled = sal_True;
}
break;
@@ -2084,24 +2083,24 @@
}
// -------------------------------------------------------------------------
-void SbaTableQueryBrowser::implAddDatasource( const String& _rDataSourceName, const
SharedConnection& _rxConnection )
+void SbaTableQueryBrowser::implAddDatasource( const OUString& _rDataSourceName, const
SharedConnection& _rxConnection )
{
Image a, b, c;
- String d, e;
+ OUString d, e;
implAddDatasource( _rDataSourceName, a, d, b, e, c, _rxConnection );
}
// -------------------------------------------------------------------------
-void SbaTableQueryBrowser::implAddDatasource(const String& _rDbName, Image& _rDbImage,
- String& _rQueryName, Image& _rQueryImage, String& _rTableName, Image& _rTableImage,
+void SbaTableQueryBrowser::implAddDatasource(const OUString& _rDbName, Image& _rDbImage,
+ OUString& _rQueryName, Image& _rQueryImage, OUString& _rTableName, Image& _rTableImage,
const SharedConnection& _rxConnection)
{
SolarMutexGuard aGuard;
// initialize the names/images if necessary
- if (!_rQueryName.Len())
- _rQueryName = String(ModuleRes(RID_STR_QUERIES_CONTAINER));
- if (!_rTableName.Len())
- _rTableName = String(ModuleRes(RID_STR_TABLES_CONTAINER));
+ if (!_rQueryName.getLength())
+ _rQueryName = OUString(ModuleRes(RID_STR_QUERIES_CONTAINER));
+ if (!_rTableName.getLength())
+ _rTableName = OUString(ModuleRes(RID_STR_TABLES_CONTAINER));
ImageProvider aImageProvider;
if (!_rQueryImage)
@@ -2115,7 +2114,7 @@
// add the entry for the data source
// special handling for data sources denoted by URLs - we do not want to display this ugly
URL, do we?
// #i33699#
- String sDSDisplayName, sDataSourceId;
+ OUString sDSDisplayName, sDataSourceId;
getDataSourceDisplayName_isURL( _rDbName, sDSDisplayName, sDataSourceId );
SvTreeListEntry* pDatasourceEntry = m_pTreeView->getListBox().InsertEntry( sDSDisplayName,
_rDbImage, _rDbImage, NULL, sal_False );
@@ -2152,7 +2151,7 @@
if (m_xDatabaseContext.is())
{
Image aDBImage, aQueriesImage, aTablesImage;
- String sQueriesName, sTablesName;
+ OUString sQueriesName, sTablesName;
// fill the model with the names of the registered datasources
Sequence< OUString > aDatasources = m_xDatabaseContext->getElementNames();
@@ -2199,7 +2198,7 @@
}
//------------------------------------------------------------------------------
-SvTreeListEntry* SbaTableQueryBrowser::implAppendEntry( SvTreeListEntry* _pParent, const String&
_rName, void* _pUserData, EntryType _eEntryType )
+SvTreeListEntry* SbaTableQueryBrowser::implAppendEntry( SvTreeListEntry* _pParent, const OUString&
_rName, void* _pUserData, EntryType _eEntryType )
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
::std::auto_ptr< ImageProvider > pImageProvider( getImageProviderFor( _pParent ) );
@@ -2694,8 +2693,8 @@
}
break;
}
- String sStatus(ModuleRes( CommandType::TABLE == nCommandType ? STR_LOADING_TABLE :
STR_LOADING_QUERY ));
- sStatus.SearchAndReplaceAscii("$name$", aName);
+ OUString sStatus(ModuleRes( CommandType::TABLE == nCommandType ? STR_LOADING_TABLE :
STR_LOADING_QUERY ));
+ sStatus = sStatus.replaceFirst("$name$", aName);
BrowserViewStatusDisplay aShowStatus(static_cast<UnoDataBrowserView*>(getView()),
sStatus);
@@ -2730,11 +2729,10 @@
Reference<XParametersSupplier>
xParSup(xAnalyzer,UNO_QUERY);
if ( xParSup->getParameters()->getCount() > 0 )
{
- String sFilter = OUString(" WHERE ");
+ OUString sFilter = OUString(" WHERE ");
sFilter = sFilter + xAnalyzer->getFilter();
- String sReplace(sSql);
- sReplace.SearchAndReplace(sFilter,String());
- xAnalyzer->setQuery(sReplace);
+ OUString sReplace(sSql);
+
xAnalyzer->setQuery(sReplace.replaceFirst(sFilter,OUString()));
Reference<XSingleSelectQueryComposer>
xComposer(xAnalyzer,UNO_QUERY);
xComposer->setFilter(OUString("0=1"));
aName = xAnalyzer->getQuery();
@@ -2753,7 +2751,7 @@
}
}
- String sDataSourceName( getDataSourceAcessor( pConnection ) );
+ OUString sDataSourceName( getDataSourceAcessor( pConnection ) );
bSuccess = implLoadAnything( sDataSourceName, aName, nCommandType, bEscapeProcessing,
pConData->xConnection );
if ( !bSuccess )
{ // clean up
@@ -2850,7 +2848,7 @@
SbaXDataBrowserController::elementInserted(_rEvent);
}
// -------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const String& _sName,SvTreeListEntry*
_pContainer)
+sal_Bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const OUString& _sName,SvTreeListEntry*
_pContainer)
{
return m_pCurrentlyDisplayed
&& getEntryType(m_pCurrentlyDisplayed) == getChildType(_pContainer)
@@ -2868,7 +2866,7 @@
SvTreeListEntry* pContainer = getEntryFromContainer(xNames);
if ( pContainer )
{ // a query or table has been removed
- String aName = ::comphelper::getString(_rEvent.Accessor);
+ OUString aName = ::comphelper::getString(_rEvent.Accessor);
if ( isCurrentlyDisplayedChanged( aName, pContainer) )
{ // the element displayed currently has been replaced
@@ -2919,7 +2917,7 @@
SvTreeListEntry* pContainer = getEntryFromContainer(xNames);
if ( pContainer )
{ // a table or query as been replaced
- String aName = ::comphelper::getString(_rEvent.Accessor);
+ OUString aName = ::comphelper::getString(_rEvent.Accessor);
if ( isCurrentlyDisplayedChanged( aName, pContainer) )
{ // the element displayed currently has been replaced
@@ -3418,13 +3416,13 @@
if ( !_rConnection.is() && pTreeListData )
{
// show the "connecting to ..." status
- String sConnecting(ModuleRes(STR_CONNECTING_DATASOURCE));
- sConnecting.SearchAndReplaceAscii("$name$", aDSName);
+ OUString sConnecting(ModuleRes(STR_CONNECTING_DATASOURCE));
+ sConnecting = sConnecting.replaceFirst("$name$", aDSName);
BrowserViewStatusDisplay aShowStatus(static_cast<UnoDataBrowserView*>(getView()),
sConnecting);
// build a string showing context information in case of error
- String sConnectingContext( ModuleRes( STR_COULDNOTCONNECT_DATASOURCE ) );
- sConnectingContext.SearchAndReplaceAscii("$name$", aDSName);
+ OUString sConnectingContext( ModuleRes( STR_COULDNOTCONNECT_DATASOURCE ) );
+ sConnectingContext = sConnectingContext.replaceFirst("$name$", aDSName);
// connect
_rConnection.reset(
@@ -3458,12 +3456,12 @@
// every other container should be placed _before_ the bookmark container
return -1;
- const String sLeft =
m_pTreeView->getListBox().GetEntryText(const_cast<SvTreeListEntry*>(pLHS));
+ const OUString sLeft =
m_pTreeView->getListBox().GetEntryText(const_cast<SvTreeListEntry*>(pLHS));
EntryType eLeft = etTableContainer;
- if (String(ModuleRes(RID_STR_TABLES_CONTAINER)) == sLeft)
+ if (OUString(ModuleRes(RID_STR_TABLES_CONTAINER)) == sLeft)
eLeft = etTableContainer;
- else if (String(ModuleRes(RID_STR_QUERIES_CONTAINER)) == sLeft)
+ else if (OUString(ModuleRes(RID_STR_QUERIES_CONTAINER)) == sLeft)
eLeft = etQueryContainer;
if ( eLeft == eRight )
@@ -3483,8 +3481,8 @@
const SvLBoxString* pRightTextItem = static_cast<const
SvLBoxString*>(pRHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
OSL_ENSURE(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid
text items!");
- String sLeftText = pLeftTextItem->GetText();
- String sRightText = pRightTextItem->GetText();
+ OUString sLeftText = pLeftTextItem->GetText();
+ OUString sRightText = pRightTextItem->GetText();
sal_Int32 nCompareResult = 0; // equal by default
@@ -3500,7 +3498,7 @@
}
else
// default behaviour if we do not have a collator -> do the simple string compare
- nCompareResult = sLeftText.CompareTo(sRightText);
+ nCompareResult = sLeftText.compareTo(sRightText);
return nCompareResult;
}
@@ -3837,7 +3835,7 @@
}
//------------------------------------------------------------------------------
-void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const String& _rDataSourceName )
+void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const OUString& _rDataSourceName )
{
// get the top-level representing the removed data source
SvTreeListEntry* pDataSourceEntry = m_pTreeView->getListBox().FirstChild( NULL );
diff --git a/dbaccess/source/ui/inc/brwctrlr.hxx b/dbaccess/source/ui/inc/brwctrlr.hxx
index 6fa6097..7f782fb 100644
--- a/dbaccess/source/ui/inc/brwctrlr.hxx
+++ b/dbaccess/source/ui/inc/brwctrlr.hxx
@@ -106,7 +106,7 @@
String m_sStateSaveRecord;
String m_sStateUndoRecord;
- ::rtl::OUString m_sModuleIdentifier;
+ OUString m_sModuleIdentifier;
// members for asynchronous load operations
FormControllerImpl* m_pFormControllerImpl; // implementing the XFormController
@@ -176,8 +176,8 @@
virtual void SAL_CALL propertyChange( const ::com::sun::star::beans::PropertyChangeEvent&
evt ) throw (::com::sun::star::uno::RuntimeException);
// XModule
- virtual void SAL_CALL setIdentifier( const ::rtl::OUString& Identifier ) throw
(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getIdentifier( ) throw
(::com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL setIdentifier( const OUString& Identifier ) throw
(::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getIdentifier( ) throw
(::com::sun::star::uno::RuntimeException);
// ::com::sun::star::awt::XFocusListener
virtual void SAL_CALL focusGained(const ::com::sun::star::awt::FocusEvent& e) throw(
::com::sun::star::uno::RuntimeException );
@@ -329,8 +329,8 @@
void ExecuteSearch();
void initializeParser() const; // changes the mutable member m_xParser
- void applyParserFilter(const ::rtl::OUString& _rOldFilter, sal_Bool
_bOldFilterApplied,const ::rtl::OUString& _sOldHaving,const ::com::sun::star::uno::Reference<
::com::sun::star::sdb::XSingleSelectQueryComposer >& _xParser);
- void applyParserOrder(const ::rtl::OUString& _rOldOrder,const
::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer >& _xParser);
+ void applyParserFilter(const OUString& _rOldFilter, sal_Bool
_bOldFilterApplied,const ::OUString& _sOldHaving,const ::com::sun::star::uno::Reference<
::com::sun::star::sdb::XSingleSelectQueryComposer >& _xParser);
+ void applyParserOrder(const OUString& _rOldOrder,const
::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer >& _xParser);
sal_Int16 getCurrentColumnPosition();
void setCurrentColumnPosition( sal_Int16 _nPos );
diff --git a/dbaccess/source/ui/inc/brwview.hxx b/dbaccess/source/ui/inc/brwview.hxx
index 049227c..d844711 100644
--- a/dbaccess/source/ui/inc/brwview.hxx
+++ b/dbaccess/source/ui/inc/brwview.hxx
@@ -77,7 +77,7 @@
void setSplitter(Splitter* _pSplitter);
void setTreeView(DBTreeView* _pTreeView);
- void showStatus( const String& _rStatus );
+ void showStatus( const OUString& _rStatus );
void hideStatus();
::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlContainer >
getContainer() { return m_xMe; }
@@ -98,7 +98,7 @@
UnoDataBrowserView* m_pView;
public:
- BrowserViewStatusDisplay( UnoDataBrowserView* _pView, const String& _rStatus );
+ BrowserViewStatusDisplay( UnoDataBrowserView* _pView, const OUString& _rStatus );
~BrowserViewStatusDisplay( );
};
}
diff --git a/dbaccess/source/ui/inc/unodatbr.hxx b/dbaccess/source/ui/inc/unodatbr.hxx
index e0b64fa..7a61ec1 100644
--- a/dbaccess/source/ui/inc/unodatbr.hxx
+++ b/dbaccess/source/ui/inc/unodatbr.hxx
@@ -288,16 +288,16 @@
<p>The given names and images may be empty, in this case they're filled with the
correct
values. This way they may be reused for the next call, which saves some resource
manager calls.</p>
*/
- void implAddDatasource(const String& _rDbName, Image& _rDbImage,
- String& _rQueryName, Image& _rQueryImage,
- String& _rTableName, Image& _rTableImage,
+ void implAddDatasource(const OUString& _rDbName, Image& _rDbImage,
+ OUString& _rQueryName, Image& _rQueryImage,
+ OUString& _rTableName, Image& _rTableImage,
const SharedConnection& _rxConnection
);
- void implAddDatasource( const String& _rDataSourceName, const SharedConnection&
_rxConnection );
+ void implAddDatasource( const OUString& _rDataSourceName, const SharedConnection&
_rxConnection );
/// removes (and cleans up) the entry for the given data source
- void impl_cleanupDataSourceEntry( const String& _rDataSourceName );
+ void impl_cleanupDataSourceEntry( const OUString& _rDataSourceName );
/// clears the tree list box
void clearTreeModel();
@@ -352,7 +352,7 @@
sal_Bool ensureEntryObject( SvTreeListEntry* _pEntry );
// get the display text of the entry given
- String GetEntryText( SvTreeListEntry* _pEntry ) const;
+ OUString GetEntryText( SvTreeListEntry* _pEntry ) const;
// is called when a table or a query was selected
DECL_LINK( OnSelectionChange, void* );
@@ -383,7 +383,7 @@
/// inserts an entry into the tree
SvTreeListEntry* implAppendEntry(
SvTreeListEntry* _pParent,
- const String& _rName,
+ const OUString& _rName,
void* _pUserData,
EntryType _eEntryType
);
@@ -448,7 +448,7 @@
#endif
/// retrieves the data source URL/name for the given entry representing a data source
- String getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const;
+ OUString getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const;
/** get the signature (command/escape processing) of the query the form is based on
<p>If the for is not based on a query or not even loaded, nothing happens and <FALSE/>
is returned.</p>
@@ -470,7 +470,7 @@
@return
<TRUE/> if it is the currently displayed otherwise <FALSE/>
*/
- sal_Bool isCurrentlyDisplayedChanged(const String& _sName,SvTreeListEntry* _pContainer);
+ sal_Bool isCurrentlyDisplayedChanged(const OUString& _sName,SvTreeListEntry* _pContainer);
/** called whenever the content of the browser is used for preview, as the very last action
of the load process
diff --git a/svx/inc/svx/svxdlg.hxx b/svx/inc/svx/svxdlg.hxx
index fd1d676..b66d9f6 100644
--- a/svx/inc/svx/svxdlg.hxx
+++ b/svx/inc/svx/svxdlg.hxx
@@ -421,7 +421,7 @@
sal_uInt32 nResId)=0;
virtual AbstractFmSearchDialog* CreateFmSearchDialog(Window* pParent, //add for FmSearchDialog
const OUString& strInitialText,
- const ::std::vector< String >& _rContexts,
+ const ::std::vector< OUString >&
_rContexts,
sal_Int16 nInitialContext,
const Link& lnkContextSupplier)=0;
virtual AbstractGraphicFilterDialog * CreateGraphicFilterEmboss (Window* pParent, //add for
GraphicFilterEmboss
diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx
index b71785a..53c2519 100644
--- a/svx/source/form/fmshimp.cxx
+++ b/svx/source/form/fmshimp.cxx
@@ -1516,7 +1516,7 @@
// eine Sammlung aller (logischen) Formulare
FmFormArray aEmpty;
m_aSearchForms.swap( aEmpty );
- ::std::vector< String > aContextNames;
+ ::std::vector< OUString > aContextNames;
impl_collectFormSearchContexts_nothrow( m_pShell->GetCurPage()->GetForms(), ::rtl::OUString(),
m_aSearchForms, aContextNames );
OSL_POSTCOND( m_aSearchForms.size() == aContextNames.size(),
"FmXFormShell::ExecuteSearch: nonsense!" );
@@ -1526,9 +1526,9 @@
// filter out the forms which do not contain valid controls at all
{
FmFormArray aValidForms;
- ::std::vector< String > aValidContexts;
+ ::std::vector< OUString > aValidContexts;
FmFormArray::const_iterator form = m_aSearchForms.begin();
- ::std::vector< String >::const_iterator contextName = aContextNames.begin();
+ ::std::vector< OUString >::const_iterator contextName = aContextNames.begin();
for ( ; form != m_aSearchForms.end(); ++form, ++contextName )
{
FmSearchContext aTestContext;
@@ -2949,7 +2949,7 @@
//------------------------------------------------------------------------------
void FmXFormShell::impl_collectFormSearchContexts_nothrow( const Reference< XInterface>&
_rxStartingPoint,
- const ::rtl::OUString& _rCurrentLevelPrefix, FmFormArray& _out_rForms, ::std::vector< String
& _out_rNames )
+ const ::rtl::OUString& _rCurrentLevelPrefix, FmFormArray& _out_rForms, ::std::vector< OUString
& _out_rNames )
{
try
{
diff --git a/svx/source/inc/fmshimp.hxx b/svx/source/inc/fmshimp.hxx
index 9a4a96a..142a6d4 100644
--- a/svx/source/inc/fmshimp.hxx
+++ b/svx/source/inc/fmshimp.hxx
@@ -345,7 +345,7 @@
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface>&
_rxStartingPoint,
const ::rtl::OUString& _rCurrentLevelPrefix,
FmFormArray& _out_rForms,
- ::std::vector< String >& _out_rNames );
+ ::std::vector< OUString >& _out_rNames );
/** checks whether the instance is already disposed, if so, this is reported as assertion
error (debug
builds only) and <TRUE/> is returned.
--
To view, visit https://gerrit.libreoffice.org/2538
To unsubscribe, visit https://gerrit.libreoffice.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I8a565cdae7fd9da1de05525c602ce011542ab4d5
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Gergő Mocsi <gmocsi91@gmail.com>
Context
- [PATCH] fdo#38838, String to OUString, in dbaccess/source/ui/browser · via Code Review
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.