summaryrefslogtreecommitdiff
path: root/dbaccess/source/ui/dlg
diff options
context:
space:
mode:
authorSantiago Alessandri <salessandri@nasel.com.ar>2010-11-11 17:20:24 -0300
committerDavid Tardon <dtardon@redhat.com>2010-11-12 08:12:31 +0100
commit7c26a84a582641c671b35516ef0e6edf63c3752f (patch)
tree142f100cdf7e9e1d73ad8de7380200ee88c5ebfe /dbaccess/source/ui/dlg
parent6c07a3cf7056f73488df19a135592824e692a2ea (diff)
Changed usage of createFromAscii for macro RTL_CONSTASCII_USTRINGPARAM
Diffstat (limited to 'dbaccess/source/ui/dlg')
-rw-r--r--dbaccess/source/ui/dlg/AdabasStat.cxx26
-rw-r--r--dbaccess/source/ui/dlg/ConnectionHelper.cxx6
-rw-r--r--dbaccess/source/ui/dlg/DbAdminImpl.cxx14
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.cxx6
-rw-r--r--dbaccess/source/ui/dlg/dbwizsetup.cxx8
-rw-r--r--dbaccess/source/ui/dlg/dsselect.cxx2
-rw-r--r--dbaccess/source/ui/dlg/generalpage.cxx2
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.cxx2
-rw-r--r--dbaccess/source/ui/dlg/queryorder.cxx6
9 files changed, 36 insertions, 36 deletions
diff --git a/dbaccess/source/ui/dlg/AdabasStat.cxx b/dbaccess/source/ui/dlg/AdabasStat.cxx
index 6f4af6e9aae8..59b453d80fcc 100644
--- a/dbaccess/source/ui/dlg/AdabasStat.cxx
+++ b/dbaccess/source/ui/dlg/AdabasStat.cxx
@@ -99,14 +99,14 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
try
{
xMetaData = m_xConnection->getMetaData();
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("SERVERDBSTATISTICS"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SERVERDBSTATISTICS")), sSchema);
if(bCanSelect)
{
- aStmt = ::rtl::OUString::createFromAscii("SELECT SERVERDBSIZE, UNUSEDPAGES FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT SERVERDBSIZE, UNUSEDPAGES FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".\"SERVERDBSTATISTICS\"");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".\"SERVERDBSTATISTICS\""));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
@@ -153,14 +153,14 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
{
try
{
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("DATADEVSPACES"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DATADEVSPACES")), sSchema);
if(bCanSelect)
{
// then the db files
- aStmt = ::rtl::OUString::createFromAscii("SELECT DEVSPACENAME FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT DEVSPACENAME FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".\"DATADEVSPACES\"");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".\"DATADEVSPACES\""));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
@@ -197,13 +197,13 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
{
try
{
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("CONFIGURATION"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CONFIGURATION")), sSchema);
if(bCanSelect)
{
- aStmt = ::rtl::OUString::createFromAscii("SELECT * FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT * FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".CONFIGURATION WHERE DESCRIPTION LIKE 'SYS%DEVSPACE%NAME'");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".CONFIGURATION WHERE DESCRIPTION LIKE 'SYS%DEVSPACE%NAME'"));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
if(xRes.is() && xRes->next())
@@ -214,9 +214,9 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
else
showError();
- aStmt = ::rtl::OUString::createFromAscii("SELECT * FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT * FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".CONFIGURATION WHERE DESCRIPTION = 'TRANSACTION LOG NAME'");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".CONFIGURATION WHERE DESCRIPTION = 'TRANSACTION LOG NAME'"));
xRes = xStmt->executeQuery(aStmt);
if(xRes.is() && xRes->next())
{
@@ -268,11 +268,11 @@ sal_Bool OAdabasStatistics::checkSystemTable(const ::rtl::OUString& _rsSystemTab
Reference<XDatabaseMetaData> xMeta = m_xConnection->getMetaData();
if ( xMeta.is() )
{
- Reference<XResultSet> xRes = xMeta->getTablePrivileges(Any(),::rtl::OUString::createFromAscii("%"), _rsSystemTable);
+ Reference<XResultSet> xRes = xMeta->getTablePrivileges(Any(), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("%")), _rsSystemTable);
if(xRes.is())
{
Reference<XRow> xRow(xRes,UNO_QUERY);
- static const ::rtl::OUString sSelect = ::rtl::OUString::createFromAscii("SELECT");
+ static const ::rtl::OUString sSelect(RTL_CONSTASCII_USTRINGPARAM("SELECT"));
// first the db sizes
while( xRow.is() && xRes->next() )
{
diff --git a/dbaccess/source/ui/dlg/ConnectionHelper.cxx b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
index 7e6ac39f658f..51f2dd27be60 100644
--- a/dbaccess/source/ui/dlg/ConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
@@ -785,18 +785,18 @@ DBG_NAME(OConnectionHelper)
::rtl::OUString sContentType;
if ( INET_PROT_FILE == eProtocol )
{
- sContentType = ::rtl::OUString::createFromAscii( "application/vnd.sun.staroffice.fsys-folder" );
+ sContentType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.staroffice.fsys-folder"));
// the file UCP currently does not support the ContentType property
}
else
{
- Any aContentType = aParent.getPropertyValue( ::rtl::OUString::createFromAscii( "ContentType" ) );
+ Any aContentType = aParent.getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ContentType")) );
aContentType >>= sContentType;
}
// the properties which need to be set on the new content
Sequence< ::rtl::OUString > aNewDirectoryProperties(1);
- aNewDirectoryProperties[0] = ::rtl::OUString::createFromAscii("Title");
+ aNewDirectoryProperties[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
// the values to be set
Sequence< Any > aNewDirectoryAttributes(1);
diff --git a/dbaccess/source/ui/dlg/DbAdminImpl.cxx b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
index 8be379b9aa89..e8e347af58c4 100644
--- a/dbaccess/source/ui/dlg/DbAdminImpl.cxx
+++ b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
@@ -207,18 +207,18 @@ ODbDataSourceAdministrationHelper::ODbDataSourceAdministrationHelper(const Refer
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_NAMED_PIPE, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "NamedPipe" ) ) ) );
// special settings for adabas
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_SHUTSERVICE, ::rtl::OUString::createFromAscii("ShutdownDatabase")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_DATAINC, ::rtl::OUString::createFromAscii("DataCacheSizeIncrement")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CACHESIZE, ::rtl::OUString::createFromAscii("DataCacheSize")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLUSER, ::rtl::OUString::createFromAscii("ControlUser")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLPWD, ::rtl::OUString::createFromAscii("ControlPassword")));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_SHUTSERVICE, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ShutdownDatabase"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_DATAINC, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataCacheSizeIncrement"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CACHESIZE, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataCacheSize"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLUSER, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ControlUser"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLPWD, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ControlPassword"))));
// extra settings for odbc
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_USECATALOG, INFO_USECATALOG));
// extra settings for a ldap address book
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_BASEDN, INFO_CONN_LDAP_BASEDN));
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_ROWCOUNT, INFO_CONN_LDAP_ROWCOUNT));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_USESSL, ::rtl::OUString::createFromAscii("UseSSL")));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_USESSL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UseSSL"))));
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_DOCUMENT_URL, PROPERTY_URL));
// oracle
@@ -664,7 +664,7 @@ void ODbDataSourceAdministrationHelper::translateProperties(const Reference< XPr
if (0 == pAdditionalInfo->Name.compareToAscii("JDBCDRV"))
{ // compatibility
PropertyValue aCompatibility(*pAdditionalInfo);
- aCompatibility.Name = ::rtl::OUString::createFromAscii("JavaDriverClass");
+ aCompatibility.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("JavaDriverClass"));
aInfos.insert(aCompatibility);
}
else
diff --git a/dbaccess/source/ui/dlg/dbfindex.cxx b/dbaccess/source/ui/dlg/dbfindex.cxx
index 809ccddc27eb..a359ceeb56b5 100644
--- a/dbaccess/source/ui/dlg/dbfindex.cxx
+++ b/dbaccess/source/ui/dlg/dbfindex.cxx
@@ -354,8 +354,8 @@ void ODbaseIndexDialog::Init()
Sequence< ::rtl::OUString> aFolderContent( ::utl::LocalFileHelper::GetFolderContents(m_aDSN,bFolder));
- ::rtl::OUString aIndexExt = ::rtl::OUString::createFromAscii("ndx");
- ::rtl::OUString aTableExt = ::rtl::OUString::createFromAscii("dbf");
+ ::rtl::OUString aIndexExt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ndx"));
+ ::rtl::OUString aTableExt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("dbf"));
::std::vector< String > aUsedIndexes;
@@ -541,7 +541,7 @@ void OTableInfo::WriteInfFile( const String& rDSN ) const
try
{
::ucbhelper::Content aContent(aURL.GetURLNoPass(),Reference<XCommandEnvironment>());
- aContent.executeCommand( rtl::OUString::createFromAscii( "delete" ),makeAny( sal_Bool( sal_True ) ) );
+ aContent.executeCommand( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("delete")),makeAny( sal_Bool( sal_True ) ) );
}
catch (const Exception& e )
{
diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index aea15cf0fb8a..4b7e600ff60c 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -359,7 +359,7 @@ void ODbTypeWizDialogSetup::activateDatabasePath()
{
sal_Int32 nCreateNewDBIndex = m_pCollection->getIndexOf( m_pCollection->getEmbeddedDatabase() );
if ( nCreateNewDBIndex == -1 )
- nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString::createFromAscii( "sdbc:dbase:" ) );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:")) );
OSL_ENSURE( nCreateNewDBIndex != -1, "ODbTypeWizDialogSetup::activateDatabasePath: the GeneralPage should have prevented this!" );
activatePath( static_cast< PathId >( nCreateNewDBIndex + 1 ), sal_True );
@@ -860,7 +860,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
}
else if ( m_pCollection->isFileSystemBased(eType) )
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
INetURLObject aDBPathURL(m_sWorkPath);
aDBPathURL.Append(m_aDocURL.getBase());
createUniqueFolderName(&aDBPathURL);
@@ -929,7 +929,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
//-------------------------------------------------------------------------
void ODbTypeWizDialogSetup::createUniqueFolderName(INetURLObject* pURL)
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
:: rtl::OUString sLastSegmentName = pURL->getName();
sal_Bool bFolderExists = sal_True;
sal_Int32 i = 1;
@@ -947,7 +947,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
//-------------------------------------------------------------------------
String ODbTypeWizDialogSetup::createUniqueFileName(const INetURLObject& _rURL)
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
:: rtl::OUString sFilename = _rURL.getName();
::rtl::OUString BaseName = _rURL.getBase();
::rtl::OUString sExtension = _rURL.getExtension();
diff --git a/dbaccess/source/ui/dlg/dsselect.cxx b/dbaccess/source/ui/dlg/dsselect.cxx
index dc7e5426c1d8..0f787bcc996d 100644
--- a/dbaccess/source/ui/dlg/dsselect.cxx
+++ b/dbaccess/source/ui/dlg/dsselect.cxx
@@ -149,7 +149,7 @@ IMPL_LINK( ODatasourceSelectDialog, CreateDBClickHdl, PushButton*, /*pButton*/ )
if ( xCatalog.is() && m_pOutputSet )
{
Sequence< Any > aArgs(2);
- aArgs[0] <<= PropertyValue(::rtl::OUString::createFromAscii("CreateCatalog"), 0,makeAny(xCatalog) , PropertyState_DIRECT_VALUE);
+ aArgs[0] <<= PropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CreateCatalog")), 0, makeAny(xCatalog), PropertyState_DIRECT_VALUE);
aArgs[1] <<= PropertyValue(PROPERTY_PARENTWINDOW, 0, makeAny(VCLUnoHelper::GetInterface(this)), PropertyState_DIRECT_VALUE);
Reference< XExecutableDialog > xDialog(
diff --git a/dbaccess/source/ui/dlg/generalpage.cxx b/dbaccess/source/ui/dlg/generalpage.cxx
index 1103a375b636..2092db3a1579 100644
--- a/dbaccess/source/ui/dlg/generalpage.cxx
+++ b/dbaccess/source/ui/dlg/generalpage.cxx
@@ -105,7 +105,7 @@ 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( ::rtl::OUString::createFromAscii( "sdbc:dbase:" ) );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:")) );
bool bHideCreateNew = ( nCreateNewDBIndex == -1 );
// also, if our application policies tell us to hide the option, do it
diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index 780fe621157f..a559f4ec8d94 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -186,7 +186,7 @@ DBG_NAME(DbaIndexDialog)
const Reference< XMultiServiceFactory >& _rxORB,sal_Int32 _nMaxColumnsInIndex)
:ModalDialog( _pParent, ModuleRes(DLG_INDEXDESIGN))
,m_xConnection(_rxConnection)
- ,m_aGeometrySettings(E_DIALOG, ::rtl::OUString::createFromAscii("dbaccess.tabledesign.indexdialog"))
+ ,m_aGeometrySettings(E_DIALOG, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("dbaccess.tabledesign.indexdialog")))
,m_aActions (this, ModuleRes(TLB_ACTIONS))
,m_aIndexes (this, ModuleRes(CTR_INDEXLIST))
,m_aIndexDetails (this, ModuleRes(FL_INDEXDETAILS))
diff --git a/dbaccess/source/ui/dlg/queryorder.cxx b/dbaccess/source/ui/dlg/queryorder.cxx
index d237978ce1ce..caa2b79e9a17 100644
--- a/dbaccess/source/ui/dlg/queryorder.cxx
+++ b/dbaccess/source/ui/dlg/queryorder.cxx
@@ -247,8 +247,8 @@ void DlgOrderCrit::EnableLines()
DBG_CHKTHIS(DlgOrderCrit,NULL);
Reference<XDatabaseMetaData> xMetaData = m_xConnection->getMetaData();
::rtl::OUString sQuote = xMetaData.is() ? xMetaData->getIdentifierQuoteString() : ::rtl::OUString();
- static const ::rtl::OUString sDESC = ::rtl::OUString::createFromAscii(" DESC ");
- static const ::rtl::OUString sASC = ::rtl::OUString::createFromAscii(" ASC ");
+ static const ::rtl::OUString sDESC(RTL_CONSTASCII_USTRINGPARAM(" DESC "));
+ static const ::rtl::OUString sASC(RTL_CONSTASCII_USTRINGPARAM(" ASC "));
Reference< XNameAccess> xColumns = Reference< XColumnsSupplier >(m_xQueryComposer,UNO_QUERY)->getColumns();
@@ -258,7 +258,7 @@ void DlgOrderCrit::EnableLines()
if(m_aColumnList[i]->GetSelectEntryPos() != 0)
{
if(sOrder.getLength())
- sOrder += ::rtl::OUString::createFromAscii(",");
+ sOrder += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(","));
String sName = m_aColumnList[i]->GetSelectEntry();
try