summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-11-06 09:35:25 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-11-06 09:35:25 +0100
commitadd39c3cc170004915eccc17e3101fe1b25556b7 (patch)
tree8df1f45fb7e007c554682969da54eb50218b2403 /dbaccess
parent5de01333b62544c36702dab9e44764272794bc7f (diff)
loplugin:stringconstant: elide explicit ctor usage (automatic rewrite)
Change-Id: I14bdbad2469d05eb25514d7ab995acb8c6ef7bd1
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/source/core/api/KeySet.cxx2
-rw-r--r--dbaccess/source/core/dataaccess/databasecontext.cxx2
-rw-r--r--dbaccess/source/core/misc/DatabaseDataProvider.cxx2
-rw-r--r--dbaccess/source/filter/xml/xmlfilter.cxx4
-rw-r--r--dbaccess/source/ui/app/AppController.cxx8
-rw-r--r--dbaccess/source/ui/app/AppControllerGen.cxx4
-rw-r--r--dbaccess/source/ui/browser/dbloader.cxx2
-rw-r--r--dbaccess/source/ui/browser/genericcontroller.cxx2
-rw-r--r--dbaccess/source/ui/browser/unodatbr.cxx24
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx2
-rw-r--r--dbaccess/source/ui/control/opendoccontrols.cxx2
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx2
-rw-r--r--dbaccess/source/ui/dlg/DbAdminImpl.cxx2
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.cxx2
-rw-r--r--dbaccess/source/ui/dlg/dbwizsetup.cxx8
-rw-r--r--dbaccess/source/ui/dlg/generalpage.cxx6
-rw-r--r--dbaccess/source/ui/misc/UITools.cxx2
-rw-r--r--dbaccess/source/ui/misc/WTypeSelect.cxx2
-rw-r--r--dbaccess/source/ui/misc/databaseobjectview.cxx2
-rw-r--r--dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx2
-rw-r--r--dbaccess/source/ui/misc/linkeddocuments.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/querycontroller.cxx16
-rw-r--r--dbaccess/source/ui/tabledesign/TableController.cxx4
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx4
26 files changed, 58 insertions, 58 deletions
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index a01028ffbbc4..2cd0f9b92722 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -765,7 +765,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQ
if(!sMaxStmt.isEmpty())
{
- sMaxStmt = sMaxStmt.replaceAt(sMaxStmt.getLength()-1,1,OUString(" "));
+ sMaxStmt = sMaxStmt.replaceAt(sMaxStmt.getLength()-1,1," ");
OUString sStmt = "SELECT " + sMaxStmt + "FROM ";
OUString sCatalog,sSchema,sTable;
::dbtools::qualifiedNameComponents(m_xConnection->getMetaData(),m_sUpdateTableName,sCatalog,sSchema,sTable,::dbtools::eInDataManipulation);
diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx b/dbaccess/source/core/dataaccess/databasecontext.cxx
index fa3f8611c577..e35263c7311f 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -251,7 +251,7 @@ Reference< XInterface > SAL_CALL ODatabaseContext::createInstance( ) throw (Exc
Reference< XInterface > SAL_CALL ODatabaseContext::createInstanceWithArguments( const Sequence< Any >& _rArguments ) throw (Exception, RuntimeException, std::exception)
{
::comphelper::NamedValueCollection aArgs( _rArguments );
- OUString sURL = aArgs.getOrDefault( OUString(INFO_POOLURL), OUString() );
+ OUString sURL = aArgs.getOrDefault( INFO_POOLURL, OUString() );
Reference< XInterface > xDataSource;
if ( !sURL.isEmpty() )
diff --git a/dbaccess/source/core/misc/DatabaseDataProvider.cxx b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
index 48f3fa11c4a8..57eb40a2fada 100644
--- a/dbaccess/source/core/misc/DatabaseDataProvider.cxx
+++ b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
@@ -449,7 +449,7 @@ uno::Sequence< OUString > SAL_CALL DatabaseDataProvider::getMasterFields() throw
void SAL_CALL DatabaseDataProvider::setMasterFields(const uno::Sequence< OUString > & the_value) throw (uno::RuntimeException, std::exception)
{
impl_invalidateParameter_nothrow();
- set(OUString("MasterFields"),the_value,m_MasterFields);
+ set("MasterFields",the_value,m_MasterFields);
}
uno::Sequence< OUString > SAL_CALL DatabaseDataProvider::getDetailFields() throw (uno::RuntimeException, std::exception)
diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx b/dbaccess/source/filter/xml/xmlfilter.cxx
index 14e2db16179d..e870a37397eb 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -210,11 +210,11 @@ ODBFilter::ODBFilter( const uno::Reference< XComponentContext >& _rxContext )
GetMM100UnitConverter().SetCoreMeasureUnit(util::MeasureUnit::MM_10TH);
GetMM100UnitConverter().SetXMLMeasureUnit(util::MeasureUnit::CM);
- GetNamespaceMap().Add( OUString ( sXML_np__db ),
+ GetNamespaceMap().Add( sXML_np__db,
GetXMLToken(XML_N_DB),
XML_NAMESPACE_DB );
- GetNamespaceMap().Add( OUString ( sXML_np___db ),
+ GetNamespaceMap().Add( sXML_np___db,
GetXMLToken(XML_N_DB_OASIS),
XML_NAMESPACE_DB );
}
diff --git a/dbaccess/source/ui/app/AppController.cxx b/dbaccess/source/ui/app/AppController.cxx
index c992a5572792..def970574e1b 100644
--- a/dbaccess/source/ui/app/AppController.cxx
+++ b/dbaccess/source/ui/app/AppController.cxx
@@ -1314,7 +1314,7 @@ void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyVa
{
SharedConnection xConnection( ensureConnection() );
if ( xConnection.is() )
- openDialog(OUString("com.sun.star.sdb.UserAdministrationDialog"));
+ openDialog("com.sun.star.sdb.UserAdministrationDialog");
}
break;
case SID_DB_APP_TABLEFILTER:
@@ -1329,11 +1329,11 @@ void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyVa
askToReconnect();
break;
case SID_DB_APP_DSADVANCED_SETTINGS:
- openDialog(OUString("com.sun.star.sdb.AdvancedDatabaseSettingsDialog"));
+ openDialog("com.sun.star.sdb.AdvancedDatabaseSettingsDialog");
askToReconnect();
break;
case SID_DB_APP_DSCONNECTION_TYPE:
- openDialog(OUString("com.sun.star.sdb.DataSourceTypeChangeDialog"));
+ openDialog("com.sun.star.sdb.DataSourceTypeChangeDialog");
askToReconnect();
break;
case ID_DIRECT_SQL:
@@ -2694,7 +2694,7 @@ sal_Bool SAL_CALL OApplicationController::attachModel(const Reference< XModel >
::comphelper::NamedValueCollection aLayoutInfo( m_xDataSource->getPropertyValue( PROPERTY_LAYOUTINFORMATION ) );
if ( aLayoutInfo.has( OUString(INFO_PREVIEW) ) )
{
- const sal_Int32 nPreviewMode( aLayoutInfo.getOrDefault( OUString(INFO_PREVIEW), (sal_Int32)0 ) );
+ const sal_Int32 nPreviewMode( aLayoutInfo.getOrDefault( INFO_PREVIEW, (sal_Int32)0 ) );
m_ePreviewMode = static_cast< PreviewMode >( nPreviewMode );
if ( getView() )
getContainer()->switchPreview( m_ePreviewMode );
diff --git a/dbaccess/source/ui/app/AppControllerGen.cxx b/dbaccess/source/ui/app/AppControllerGen.cxx
index 9516a481eb14..df9e1c3909ff 100644
--- a/dbaccess/source/ui/app/AppControllerGen.cxx
+++ b/dbaccess/source/ui/app/AppControllerGen.cxx
@@ -160,7 +160,7 @@ void OApplicationController::pasteFormat(SotClipboardFormatId _nFormatId)
void OApplicationController::openDataSourceAdminDialog()
{
- openDialog( OUString( "com.sun.star.sdb.DatasourceAdministrationDialog" ) );
+ openDialog( "com.sun.star.sdb.DatasourceAdministrationDialog" );
}
void OApplicationController::openDialog( const OUString& _sServiceName )
@@ -225,7 +225,7 @@ void OApplicationController::openDialog( const OUString& _sServiceName )
void OApplicationController::openTableFilterDialog()
{
- openDialog( OUString( "com.sun.star.sdb.TableFilterDialog" ) );
+ openDialog( "com.sun.star.sdb.TableFilterDialog" );
}
void OApplicationController::refreshTables()
diff --git a/dbaccess/source/ui/browser/dbloader.cxx b/dbaccess/source/ui/browser/dbloader.cxx
index 626ecb1f7be2..fbd33ce972db 100644
--- a/dbaccess/source/ui/browser/dbloader.cxx
+++ b/dbaccess/source/ui/browser/dbloader.cxx
@@ -192,7 +192,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const OU
if ( sComponentURL == URL_COMPONENT_DATASOURCEBROWSER )
{
bool bDisableBrowser = !aLoadArgs.getOrDefault( "ShowTreeViewButton", sal_True ) // compatibility name
- || !aLoadArgs.getOrDefault( OUString(PROPERTY_ENABLE_BROWSER), sal_True );
+ || !aLoadArgs.getOrDefault( PROPERTY_ENABLE_BROWSER, sal_True );
if ( bDisableBrowser )
{
diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx b/dbaccess/source/ui/browser/genericcontroller.cxx
index 99b6f2f232ca..6f2b3526f2e6 100644
--- a/dbaccess/source/ui/browser/genericcontroller.cxx
+++ b/dbaccess/source/ui/browser/genericcontroller.cxx
@@ -245,7 +245,7 @@ bool OGenericUnoController::Construct(vcl::Window* /*pParent*/)
{
SAL_WARN("dbaccess.ui","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(), OUString("com.sun.star.sdb.DatabaseContext"), true);
+ ShowServiceNotAvailableError(getView(), "com.sun.star.sdb.DatabaseContext", true);
}
return true;
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index d0c36b004f01..d994894ace88 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -1703,7 +1703,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
else if ( nId == ID_TREE_EDIT_DATABASE )
{
::utl::OConfigurationTreeRoot aConfig( ::utl::OConfigurationTreeRoot::createWithComponentContext( getORB(),
- OUString( "/org.openoffice.Office.DataAccess/Policies/Features/Common" ) ) );
+ "/org.openoffice.Office.DataAccess/Policies/Features/Common" ) );
bool bHaveEditDatabase( true );
OSL_VERIFY( aConfig.getNodeValue( "EditDatabaseFromDataSourceView" ) >>= bHaveEditDatabase );
aReturn.bEnabled = getORB().is() && ( pDataSourceEntry != NULL ) && bHaveEditDatabase;
@@ -3094,21 +3094,21 @@ void SbaTableQueryBrowser::impl_initialize()
const NamedValueCollection& rArguments( getInitParams() );
- rArguments.get_ensureType( OUString(PROPERTY_DATASOURCENAME), sInitialDataSourceName );
- rArguments.get_ensureType( OUString(PROPERTY_COMMAND_TYPE), nInitialDisplayCommandType );
- rArguments.get_ensureType( OUString(PROPERTY_COMMAND), sInitialCommand );
- rArguments.get_ensureType( OUString(PROPERTY_ACTIVE_CONNECTION), xForeignConnection );
- rArguments.get_ensureType( OUString(PROPERTY_UPDATE_CATALOGNAME), aCatalogName );
- rArguments.get_ensureType( OUString(PROPERTY_UPDATE_SCHEMANAME), aSchemaName );
- rArguments.get_ensureType( OUString(PROPERTY_UPDATE_TABLENAME), aTableName );
- rArguments.get_ensureType( OUString(PROPERTY_ESCAPE_PROCESSING), bEscapeProcessing );
+ rArguments.get_ensureType( PROPERTY_DATASOURCENAME, sInitialDataSourceName );
+ rArguments.get_ensureType( PROPERTY_COMMAND_TYPE, nInitialDisplayCommandType );
+ rArguments.get_ensureType( PROPERTY_COMMAND, sInitialCommand );
+ rArguments.get_ensureType( PROPERTY_ACTIVE_CONNECTION, xForeignConnection );
+ rArguments.get_ensureType( PROPERTY_UPDATE_CATALOGNAME, aCatalogName );
+ rArguments.get_ensureType( PROPERTY_UPDATE_SCHEMANAME, aSchemaName );
+ rArguments.get_ensureType( PROPERTY_UPDATE_TABLENAME, aTableName );
+ rArguments.get_ensureType( PROPERTY_ESCAPE_PROCESSING, bEscapeProcessing );
rArguments.get_ensureType( "Frame", xFrame );
- rArguments.get_ensureType( OUString(PROPERTY_SHOWMENU), m_bShowMenu );
+ rArguments.get_ensureType( PROPERTY_SHOWMENU, m_bShowMenu );
// disable the browser if either of ShowTreeViewButton (compatibility name) or EnableBrowser
// is present and set to FALSE
bool bDisableBrowser = !rArguments.getOrDefault( "ShowTreeViewButton", sal_True ) // compatibility name
- || !rArguments.getOrDefault( OUString(PROPERTY_ENABLE_BROWSER), sal_True );
+ || !rArguments.getOrDefault( PROPERTY_ENABLE_BROWSER, sal_True );
OSL_ENSURE( !rArguments.has( "ShowTreeViewButton" ),
"SbaTableQueryBrowser::impl_initialize: ShowTreeViewButton is superseded by EnableBrowser!" );
m_bEnableBrowser = !bDisableBrowser;
@@ -3116,7 +3116,7 @@ void SbaTableQueryBrowser::impl_initialize()
// hide the tree view it is disabled in general, or if the settings tell to hide it initially
bool bHideTreeView = ( !m_bEnableBrowser )
|| !rArguments.getOrDefault( "ShowTreeView", sal_True ) // compatibility name
- || !rArguments.getOrDefault( OUString(PROPERTY_SHOW_BROWSER), sal_True );
+ || !rArguments.getOrDefault( PROPERTY_SHOW_BROWSER, sal_True );
OSL_ENSURE( !rArguments.has( "ShowTreeView" ),
"SbaTableQueryBrowser::impl_initialize: ShowTreeView is superseded by ShowBrowser!" );
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index 086b57a841ad..fbcbeb5272d4 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -1659,7 +1659,7 @@ OUString OFieldDescControl::getControlDefault( const OFieldDescription* _pFieldD
if ( !bTextFormat )
{
Locale aLocale;
- ::comphelper::getNumberFormatProperty(xNumberFormatter,nFormatKey,OUString("Locale")) >>= aLocale;
+ ::comphelper::getNumberFormatProperty(xNumberFormatter,nFormatKey,"Locale") >>= aLocale;
sal_Int32 nNumberFormat = ::comphelper::getNumberFormatType(xNumberFormatter,nFormatKey);
if( (nNumberFormat & css::util::NumberFormat::DATE) == css::util::NumberFormat::DATE
diff --git a/dbaccess/source/ui/control/opendoccontrols.cxx b/dbaccess/source/ui/control/opendoccontrols.cxx
index ca7ef2df077f..caa0e1c6049d 100644
--- a/dbaccess/source/ui/control/opendoccontrols.cxx
+++ b/dbaccess/source/ui/control/opendoccontrols.cxx
@@ -219,7 +219,7 @@ namespace dbaui
::comphelper::SequenceAsHashMap aFilterProperties( aProps );
OUString sDocumentService = aFilterProperties.getUnpackedValueOrDefault(
- OUString( "DocumentService" ), OUString() );
+ "DocumentService", OUString() );
if ( sDocumentService.equalsAscii( _pAsciiModuleName ) )
{
// yes, it's a Base document
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index d0b1f69da861..8719315b9203 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -189,7 +189,7 @@ using namespace ::com::sun::star;
OSL_ENSURE(pCollection, "OLDAPConnectionPageSetup::FillItemSet : really need a DSN type collection !");
if (pCollection)
{
- OUString sUrl = pCollection->getPrefix( OUString("sdbc:address:ldap:"));
+ OUString sUrl = pCollection->getPrefix( "sdbc:address:ldap:");
sUrl += m_pETHostServer->GetText();
_rSet->Put(SfxStringItem(DSID_CONNECTURL, sUrl));
bChangedSomething = true;
diff --git a/dbaccess/source/ui/dlg/DbAdminImpl.cxx b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
index 29b056f9da7f..8455001ff916 100644
--- a/dbaccess/source/ui/dlg/DbAdminImpl.cxx
+++ b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
@@ -206,7 +206,7 @@ ODbDataSourceAdministrationHelper::ODbDataSourceAdministrationHelper(const Refer
}
catch(const Exception&)
{
- ShowServiceNotAvailableError(_pParent->GetParent(), OUString("com.sun.star.sdb.DatabaseContext"), true);
+ ShowServiceNotAvailableError(_pParent->GetParent(), "com.sun.star.sdb.DatabaseContext", true);
}
}
diff --git a/dbaccess/source/ui/dlg/dbfindex.cxx b/dbaccess/source/ui/dlg/dbfindex.cxx
index 8665b977d1d5..760f82b917cb 100644
--- a/dbaccess/source/ui/dlg/dbfindex.cxx
+++ b/dbaccess/source/ui/dlg/dbfindex.cxx
@@ -481,7 +481,7 @@ void OTableInfo::WriteInfFile( const OUString& rDSN ) const
try
{
::ucbhelper::Content aContent(aURL.GetURLNoPass(),Reference<XCommandEnvironment>(), comphelper::getProcessComponentContext());
- aContent.executeCommand( OUString("delete"), makeAny( true ) );
+ aContent.executeCommand( "delete", makeAny( true ) );
}
catch (const Exception& e )
{
diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index ba5e6d65f7fd..7263981da244 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -321,7 +321,7 @@ void ODbTypeWizDialogSetup::activateDatabasePath()
{
sal_Int32 nCreateNewDBIndex = m_pCollection->getIndexOf( m_pGeneralPage->GetSelectedType() );
if ( nCreateNewDBIndex == -1 )
- nCreateNewDBIndex = m_pCollection->getIndexOf( OUString("sdbc:dbase:") );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( "sdbc:dbase:" );
OSL_ENSURE( nCreateNewDBIndex != -1, "ODbTypeWizDialogSetup::activateDatabasePath: the GeneralPage should have prevented this!" );
activatePath( static_cast< PathId >( nCreateNewDBIndex + 1 ), true );
@@ -506,16 +506,16 @@ VclPtr<TabPage> ODbTypeWizDialogSetup::createPage(WizardState _nState)
break;
case PAGE_DBSETUPWIZARD_MYSQL_ODBC:
- m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix(OUString("sdbc:mysql:odbc:"))));
+ m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix("sdbc:mysql:odbc:")));
pPage = OConnectionTabPageSetup::CreateODBCTabPage( this, *m_pOutSet);
break;
case PAGE_DBSETUPWIZARD_MYSQL_JDBC:
- m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix(OUString("sdbc:mysql:jdbc:"))));
+ m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix("sdbc:mysql:jdbc:")));
pPage = OGeneralSpecialJDBCConnectionPageSetup::CreateMySQLJDBCTabPage( this, *m_pOutSet);
break;
case PAGE_DBSETUPWIZARD_MYSQL_NATIVE:
- m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix(OUString("sdbc:mysql:mysqlc:"))));
+ m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, m_pCollection->getPrefix("sdbc:mysql:mysqlc:")));
pPage = MySQLNativeSetupPage::Create( this, *m_pOutSet);
break;
diff --git a/dbaccess/source/ui/dlg/generalpage.cxx b/dbaccess/source/ui/dlg/generalpage.cxx
index 1b3f373e3ef2..a2681aeaa329 100644
--- a/dbaccess/source/ui/dlg/generalpage.cxx
+++ b/dbaccess/source/ui/dlg/generalpage.cxx
@@ -512,13 +512,13 @@ namespace dbaui
// If no driver for embedded DBs is installed, and no dBase driver, then hide the "Create new database" option
sal_Int32 nCreateNewDBIndex = m_pCollection->getIndexOf( m_pCollection->getEmbeddedDatabase() );
if ( nCreateNewDBIndex == -1 )
- nCreateNewDBIndex = m_pCollection->getIndexOf( OUString( "sdbc:dbase:" ) );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( "sdbc:dbase:" );
bool bHideCreateNew = ( nCreateNewDBIndex == -1 );
// also, if our application policies tell us to hide the option, do it
::utl::OConfigurationTreeRoot aConfig( ::utl::OConfigurationTreeRoot::createWithComponentContext(
::comphelper::getProcessComponentContext(),
- OUString( "/org.openoffice.Office.DataAccess/Policies/Features/Base" )
+ "/org.openoffice.Office.DataAccess/Policies/Features/Base"
) );
bool bAllowCreateLocalDatabase( true );
OSL_VERIFY( aConfig.getNodeValue( "CreateLocalDatabase" ) >>= bAllowCreateLocalDatabase );
@@ -619,7 +619,7 @@ namespace dbaui
{
// Sets jdbc as the default selected databse on startup.
if (m_pRB_CreateDatabase->IsChecked() )
- return m_pCollection->getTypeDisplayName( OUString( "jdbc:" ) );
+ return m_pCollection->getTypeDisplayName( "jdbc:" );
return OGeneralPage::getDatasourceName( _rSet );
}
diff --git a/dbaccess/source/ui/misc/UITools.cxx b/dbaccess/source/ui/misc/UITools.cxx
index 20704cab1133..e58a6f2ae6d7 100644
--- a/dbaccess/source/ui/misc/UITools.cxx
+++ b/dbaccess/source/ui/misc/UITools.cxx
@@ -900,7 +900,7 @@ bool callColumnFormatDialog(vcl::Window* _pParent,
const SfxFilter* getStandardDatabaseFilter()
{
- const SfxFilter* pFilter = SfxFilter::GetFilterByName(OUString("StarOffice XML (Base)"));
+ const SfxFilter* pFilter = SfxFilter::GetFilterByName("StarOffice XML (Base)");
OSL_ENSURE(pFilter,"Filter: StarOffice XML (Base) could not be found!");
return pFilter;
}
diff --git a/dbaccess/source/ui/misc/WTypeSelect.cxx b/dbaccess/source/ui/misc/WTypeSelect.cxx
index 7b04c4913a10..ba9e35ebb0b3 100644
--- a/dbaccess/source/ui/misc/WTypeSelect.cxx
+++ b/dbaccess/source/ui/misc/WTypeSelect.cxx
@@ -243,7 +243,7 @@ OWizTypeSelect::OWizTypeSelect( vcl::Window* pParent, SvStream* _pStream )
m_pTypeControl->Show();
m_pTypeControl->Init();
- m_pAutoEt->SetText(OUString("10"));
+ m_pAutoEt->SetText("10");
m_pAutoEt->SetDecimalDigits(0);
m_pAutoPb->SetClickHdl(LINK(this,OWizTypeSelect,ButtonClickHdl));
m_pColumnNames->EnableMultiSelection(true);
diff --git a/dbaccess/source/ui/misc/databaseobjectview.cxx b/dbaccess/source/ui/misc/databaseobjectview.cxx
index e6b9e0f79366..c4441a46d350 100644
--- a/dbaccess/source/ui/misc/databaseobjectview.cxx
+++ b/dbaccess/source/ui/misc/databaseobjectview.cxx
@@ -188,7 +188,7 @@ namespace dbaui
DatabaseObjectView::fillDispatchArgs( i_rDispatchArgs, _aDataSource, _rObjectName );
const bool bIncludeQueryName = !_rObjectName.isEmpty();
- const bool bGraphicalDesign = i_rDispatchArgs.getOrDefault( OUString(PROPERTY_GRAPHICAL_DESIGN), sal_True );
+ const bool bGraphicalDesign = i_rDispatchArgs.getOrDefault( PROPERTY_GRAPHICAL_DESIGN, sal_True );
const bool bEditViewAsSQLCommand = ( m_nCommandType == CommandType::TABLE ) && !bGraphicalDesign;
i_rDispatchArgs.put( OUString(PROPERTY_COMMAND_TYPE), m_nCommandType );
diff --git a/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx b/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
index 35cb35e1cd9b..1e9ac26c5add 100644
--- a/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
+++ b/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
@@ -187,7 +187,7 @@ namespace dbaui
const ::comphelper::NamedValueCollection& rArguments( getInitParams() );
Reference< XConnection > xConnection;
- xConnection = rArguments.getOrDefault( OUString(PROPERTY_ACTIVE_CONNECTION), xConnection );
+ xConnection = rArguments.getOrDefault( PROPERTY_ACTIVE_CONNECTION, xConnection );
if ( !xConnection.is() )
::dbtools::isEmbeddedInDatabase( getModel(), xConnection );
diff --git a/dbaccess/source/ui/misc/linkeddocuments.cxx b/dbaccess/source/ui/misc/linkeddocuments.cxx
index 388f4d58a273..40f62b4ad299 100644
--- a/dbaccess/source/ui/misc/linkeddocuments.cxx
+++ b/dbaccess/source/ui/misc/linkeddocuments.cxx
@@ -358,7 +358,7 @@ namespace dbaui
aInfo = dbtools::SQLExceptionInfo(aSQLException);
// more like a hack, insert an empty message
- aInfo.prepend(OUString(" \n"));
+ aInfo.prepend(" \n");
OUString sMessage = ModuleRes(STR_COULDNOTOPEN_LINKEDDOC);
sMessage = sMessage.replaceFirst("$file$",_rLinkName);
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 64c59f9e7c99..d2606d9b2711 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -1542,7 +1542,7 @@ namespace
for(;aIter != aTabEnd;++aIter)
{
OQueryTableWindow* pTabWin = static_cast<OQueryTableWindow*>(aIter->second.get());
- if (pTabWin->ExistsField( OUString("*"), aDragLeft ))
+ if (pTabWin->ExistsField( "*", aDragLeft ))
{
aDragLeft->SetAlias(OUString());
aDragLeft->SetTable(OUString());
@@ -2203,7 +2203,7 @@ namespace
for(;aIter != aEnd;++aIter)
{
OQueryTableWindow* pTabWin = static_cast<OQueryTableWindow*>(aIter->second.get());
- if (pTabWin->ExistsField( OUString("*"), aInfo ))
+ if (pTabWin->ExistsField( "*", aInfo ))
{
aInfo->SetAlias(OUString());
aInfo->SetTable(OUString());
@@ -2726,7 +2726,7 @@ SqlParseError OQueryDesignView::InsertField( const OTableFieldDescRef& rInfo, bo
sal_Int32 OQueryDesignView::getColWidth(sal_uInt16 _nColPos) const
{
- static sal_Int32 s_nDefaultWidth = GetTextWidth(OUString("0")) * 15;
+ static sal_Int32 s_nDefaultWidth = GetTextWidth("0") * 15;
sal_Int32 nWidth = static_cast<OQueryController&>(getController()).getColWidth(_nColPos);
if ( !nWidth )
nWidth = s_nDefaultWidth;
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
index 006257f68f9f..30f4f013e80b 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
@@ -801,7 +801,7 @@ bool OSelectionBrowseBox::saveField(OUString& _sFieldName ,OTableFieldDescRef& _
if ( nFunCount == 4 && SQL_ISRULE(pColumnRef->getChild(3),column_ref) )
bError = fillColumnRef( pColumnRef->getChild(3), xConnection, aSelEntry, _bListAction );
else if ( nFunCount == 3 ) // we have a COUNT(*) here, so take the first table
- bError = fillColumnRef( OUString("*"), OUString(), xMetaData, aSelEntry, _bListAction );
+ bError = fillColumnRef( "*", OUString(), xMetaData, aSelEntry, _bListAction );
else
{
nFunctionType |= FKT_NUMERIC;
diff --git a/dbaccess/source/ui/querydesign/querycontroller.cxx b/dbaccess/source/ui/querydesign/querycontroller.cxx
index e4e042eb4a80..8cc18c58a052 100644
--- a/dbaccess/source/ui/querydesign/querycontroller.cxx
+++ b/dbaccess/source/ui/querydesign/querycontroller.cxx
@@ -884,8 +884,8 @@ void OQueryController::impl_initialize()
}
// non-legacy parameters which overwrite the legacy parameters
- rArguments.get_ensureType( OUString(PROPERTY_COMMAND), sCommand );
- rArguments.get_ensureType( OUString(PROPERTY_COMMAND_TYPE), m_nCommandType );
+ rArguments.get_ensureType( PROPERTY_COMMAND, sCommand );
+ rArguments.get_ensureType( PROPERTY_COMMAND_TYPE, m_nCommandType );
// translate Command/Type into proper members
// TODO/Later: all this (including those members) should be hidden behind some abstract interface,
@@ -909,17 +909,17 @@ void OQueryController::impl_initialize()
// more legacy parameters
bool bGraphicalDesign( true );
- if ( rArguments.get_ensureType( OUString(PROPERTY_QUERYDESIGNVIEW), bGraphicalDesign ) )
+ if ( rArguments.get_ensureType( PROPERTY_QUERYDESIGNVIEW, bGraphicalDesign ) )
{
OSL_FAIL( "OQueryController::impl_initialize: QueryDesignView is regognized for compatibility only!" );
m_bGraphicalDesign = bGraphicalDesign;
}
// more non-legacy
- rArguments.get_ensureType( OUString(PROPERTY_GRAPHICAL_DESIGN), m_bGraphicalDesign );
+ rArguments.get_ensureType( PROPERTY_GRAPHICAL_DESIGN, m_bGraphicalDesign );
bool bEscapeProcessing( true );
- if ( rArguments.get_ensureType( OUString(PROPERTY_ESCAPE_PROCESSING), bEscapeProcessing ) )
+ if ( rArguments.get_ensureType( PROPERTY_ESCAPE_PROCESSING, bEscapeProcessing ) )
{
setEscapeProcessing_fireEvent( bEscapeProcessing );
@@ -938,11 +938,11 @@ void OQueryController::impl_initialize()
::comphelper::NamedValueCollection aCurrentQueryDesign( aCurrentQueryDesignProps );
if ( aCurrentQueryDesign.has( OUString(PROPERTY_GRAPHICAL_DESIGN) ) )
{
- aCurrentQueryDesign.get_ensureType( OUString(PROPERTY_GRAPHICAL_DESIGN), m_bGraphicalDesign );
+ aCurrentQueryDesign.get_ensureType( PROPERTY_GRAPHICAL_DESIGN, m_bGraphicalDesign );
}
if ( aCurrentQueryDesign.has( OUString(PROPERTY_ESCAPE_PROCESSING) ) )
{
- aCurrentQueryDesign.get_ensureType( OUString(PROPERTY_ESCAPE_PROCESSING), m_bEscapeProcessing );
+ aCurrentQueryDesign.get_ensureType( PROPERTY_ESCAPE_PROCESSING, m_bEscapeProcessing );
}
if ( aCurrentQueryDesign.has( "Statement" ) )
{
@@ -1967,7 +1967,7 @@ bool OQueryController::allowQueries() const
return false;
const NamedValueCollection& rArguments( getInitParams() );
- sal_Int32 nCommandType = rArguments.getOrDefault( OUString(PROPERTY_COMMAND_TYPE), (sal_Int32)CommandType::QUERY );
+ sal_Int32 nCommandType = rArguments.getOrDefault( PROPERTY_COMMAND_TYPE, (sal_Int32)CommandType::QUERY );
bool bCreatingView = ( nCommandType == CommandType::TABLE );
return !bCreatingView;
}
diff --git a/dbaccess/source/ui/tabledesign/TableController.cxx b/dbaccess/source/ui/tabledesign/TableController.cxx
index 252ba4b1f29c..0099ac8dea38 100644
--- a/dbaccess/source/ui/tabledesign/TableController.cxx
+++ b/dbaccess/source/ui/tabledesign/TableController.cxx
@@ -501,7 +501,7 @@ void OTableController::impl_initialize()
const NamedValueCollection& rArguments( getInitParams() );
- rArguments.get_ensureType( OUString(PROPERTY_CURRENTTABLE), m_sName );
+ rArguments.get_ensureType( PROPERTY_CURRENTTABLE, m_sName );
// read autoincrement value set in the datasource
::dbaui::fillAutoIncrementValue(getDataSource(),m_bAllowAutoIncrementValue,m_sAutoIncrementValue);
@@ -959,7 +959,7 @@ bool OTableController::checkColumns(bool _bNew)
pActFieldDescr->SetAutoIncrement(false);
pActFieldDescr->SetIsNullable(ColumnValue::NO_NULLS);
- pActFieldDescr->SetName( createUniqueName(OUString("ID") ));
+ pActFieldDescr->SetName( createUniqueName("ID" ));
pActFieldDescr->SetPrimaryKey( true );
m_vRowList.insert(m_vRowList.begin(),pNewRow);
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
index c575b4981edf..d4547ba8cb97 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
@@ -49,10 +49,10 @@ ODBTypeWizDialogSetup::ODBTypeWizDialogSetup(const Reference< XComponentContext
,m_bOpenDatabase(true)
,m_bStartTableWizard(false)
{
- registerProperty(OUString("OpenDatabase"), 3, PropertyAttribute::TRANSIENT,
+ registerProperty("OpenDatabase", 3, PropertyAttribute::TRANSIENT,
&m_bOpenDatabase, cppu::UnoType<bool>::get());
- registerProperty(OUString("StartTableWizard"), 4, PropertyAttribute::TRANSIENT,
+ registerProperty("StartTableWizard", 4, PropertyAttribute::TRANSIENT,
&m_bStartTableWizard, cppu::UnoType<bool>::get());
}