summaryrefslogtreecommitdiff
path: root/dbaccess/source/ui
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2012-05-17 14:00:15 +0100
committerCaolán McNamara <caolanm@redhat.com>2012-05-17 14:03:26 +0100
commit5dcf536b69848b56f1199b81e4b7ed87a0a3864d (patch)
tree86f28d6db1963680549b6111ca99f95ca580f763 /dbaccess/source/ui
parentacd9cda35457f0a839bf9713c261022c39cd8269 (diff)
merge the 5 ConstAsciiString duplicate classes together
a) merge them together and move it into comphelper b) turn it into a POD rather than having vast amounts of destructors registered into the cxa_atexit chain Change-Id: I04d3b9d7804f8e233013c916df9d617a0f84f96a
Diffstat (limited to 'dbaccess/source/ui')
-rw-r--r--dbaccess/source/ui/browser/dbloader.cxx12
-rw-r--r--dbaccess/source/ui/misc/UITools.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx2
-rw-r--r--dbaccess/source/ui/uno/ColumnControl.cxx2
-rw-r--r--dbaccess/source/ui/uno/ColumnPeer.cxx8
-rw-r--r--dbaccess/source/ui/uno/unoDirectSql.cxx2
6 files changed, 16 insertions, 16 deletions
diff --git a/dbaccess/source/ui/browser/dbloader.cxx b/dbaccess/source/ui/browser/dbloader.cxx
index a3557049e853..0caddb29b98c 100644
--- a/dbaccess/source/ui/browser/dbloader.cxx
+++ b/dbaccess/source/ui/browser/dbloader.cxx
@@ -204,12 +204,12 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
{
}
} aImplementations[] = {
- ServiceNameToImplName( URL_COMPONENT_FORMGRIDVIEW, "org.openoffice.comp.dbu.OFormGridView" ),
- ServiceNameToImplName( URL_COMPONENT_DATASOURCEBROWSER, "org.openoffice.comp.dbu.ODatasourceBrowser" ),
- ServiceNameToImplName( URL_COMPONENT_QUERYDESIGN, "org.openoffice.comp.dbu.OQueryDesign" ),
- ServiceNameToImplName( URL_COMPONENT_TABLEDESIGN, "org.openoffice.comp.dbu.OTableDesign" ),
- ServiceNameToImplName( URL_COMPONENT_RELATIONDESIGN, "org.openoffice.comp.dbu.ORelationDesign" ),
- ServiceNameToImplName( URL_COMPONENT_VIEWDESIGN, "org.openoffice.comp.dbu.OViewDesign" )
+ ServiceNameToImplName( URL_COMPONENT_FORMGRIDVIEW.ascii, "org.openoffice.comp.dbu.OFormGridView" ),
+ ServiceNameToImplName( URL_COMPONENT_DATASOURCEBROWSER.ascii, "org.openoffice.comp.dbu.ODatasourceBrowser" ),
+ ServiceNameToImplName( URL_COMPONENT_QUERYDESIGN.ascii, "org.openoffice.comp.dbu.OQueryDesign" ),
+ ServiceNameToImplName( URL_COMPONENT_TABLEDESIGN.ascii, "org.openoffice.comp.dbu.OTableDesign" ),
+ ServiceNameToImplName( URL_COMPONENT_RELATIONDESIGN.ascii, "org.openoffice.comp.dbu.ORelationDesign" ),
+ ServiceNameToImplName( URL_COMPONENT_VIEWDESIGN.ascii, "org.openoffice.comp.dbu.OViewDesign" )
};
INetURLObject aParser( rURL );
diff --git a/dbaccess/source/ui/misc/UITools.cxx b/dbaccess/source/ui/misc/UITools.cxx
index 5e60e7ca24b0..ed2f8717ec7c 100644
--- a/dbaccess/source/ui/misc/UITools.cxx
+++ b/dbaccess/source/ui/misc/UITools.cxx
@@ -1162,18 +1162,18 @@ void adjustBrowseBoxColumnWidth( ::svt::EditBrowseBox* _pBox, sal_uInt16 _nColId
// check if SQL92 name checking is enabled
sal_Bool isSQL92CheckEnabled(const Reference<XConnection>& _xConnection)
{
- return ::dbtools::getBooleanDataSourceSetting( _xConnection, PROPERTY_ENABLESQL92CHECK );
+ return ::dbtools::getBooleanDataSourceSetting( _xConnection, PROPERTY_ENABLESQL92CHECK.ascii );
}
// -----------------------------------------------------------------------------
sal_Bool isAppendTableAliasEnabled(const Reference<XConnection>& _xConnection)
{
- return ::dbtools::getBooleanDataSourceSetting( _xConnection, INFO_APPEND_TABLE_ALIAS );
+ return ::dbtools::getBooleanDataSourceSetting( _xConnection, INFO_APPEND_TABLE_ALIAS.ascii );
}
// -----------------------------------------------------------------------------
sal_Bool generateAsBeforeTableAlias(const Reference<XConnection>& _xConnection)
{
- return ::dbtools::getBooleanDataSourceSetting( _xConnection, INFO_AS_BEFORE_CORRELATION_NAME );
+ return ::dbtools::getBooleanDataSourceSetting( _xConnection, INFO_AS_BEFORE_CORRELATION_NAME.ascii );
}
// -----------------------------------------------------------------------------
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 751145add512..d6a28725ec37 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -1055,7 +1055,7 @@ namespace
aMulti.insert(::std::multimap<sal_Int32 , OTableWindow*>::value_type(aCountIter->second,aCountIter->first));
}
- const sal_Bool bUseEscape = ::dbtools::getBooleanDataSourceSetting( _xConnection, PROPERTY_OUTERJOINESCAPE );
+ const sal_Bool bUseEscape = ::dbtools::getBooleanDataSourceSetting( _xConnection, PROPERTY_OUTERJOINESCAPE.ascii );
::std::multimap<sal_Int32 , OTableWindow*>::reverse_iterator aRIter = aMulti.rbegin();
::std::multimap<sal_Int32 , OTableWindow*>::reverse_iterator aREnd = aMulti.rend();
for(;aRIter != aREnd;++aRIter)
diff --git a/dbaccess/source/ui/uno/ColumnControl.cxx b/dbaccess/source/ui/uno/ColumnControl.cxx
index 16dec735db19..9c240e448712 100644
--- a/dbaccess/source/ui/uno/ColumnControl.cxx
+++ b/dbaccess/source/ui/uno/ColumnControl.cxx
@@ -52,7 +52,7 @@ OColumnControl::OColumnControl(const Reference<XMultiServiceFactory>& _rxFactory
{
}
// -----------------------------------------------------------------------------
-IMPLEMENT_SERVICE_INFO2_STATIC(OColumnControl,SERVICE_CONTROLDEFAULT,"com.sun.star.awt.UnoControl","com.sun.star.sdb.ColumnDescriptorControl")
+IMPLEMENT_SERVICE_INFO2_STATIC(OColumnControl,SERVICE_CONTROLDEFAULT.ascii,"com.sun.star.awt.UnoControl","com.sun.star.sdb.ColumnDescriptorControl")
// -----------------------------------------------------------------------------
::rtl::OUString OColumnControl::GetComponentServiceName()
{
diff --git a/dbaccess/source/ui/uno/ColumnPeer.cxx b/dbaccess/source/ui/uno/ColumnPeer.cxx
index 07902e808b81..4b583571bcc2 100644
--- a/dbaccess/source/ui/uno/ColumnPeer.cxx
+++ b/dbaccess/source/ui/uno/ColumnPeer.cxx
@@ -126,12 +126,12 @@ void OColumnPeer::setProperty( const ::rtl::OUString& _rPropertyName, const Any&
{
SolarMutexGuard aGuard;
- if ( 0 == _rPropertyName.compareToAscii( PROPERTY_COLUMN ) )
+ if (_rPropertyName.equalsAsciiL(PROPERTY_COLUMN.ascii, PROPERTY_COLUMN.length) )
{
Reference<XPropertySet> xProp(Value,UNO_QUERY);
setColumn(xProp);
}
- else if ( 0 == _rPropertyName.compareToAscii( PROPERTY_ACTIVE_CONNECTION ) )
+ else if (_rPropertyName.equalsAsciiL(PROPERTY_ACTIVE_CONNECTION.ascii, PROPERTY_ACTIVE_CONNECTION.length) )
{
Reference<XConnection> xCon(Value,UNO_QUERY);
setConnection(xCon);
@@ -144,11 +144,11 @@ Any OColumnPeer::getProperty( const ::rtl::OUString& _rPropertyName ) throw( Run
{
Any aProp;
OFieldDescControl* pFieldControl = static_cast<OFieldDescControl*>( GetWindow() );
- if ( pFieldControl && 0 == _rPropertyName.compareToAscii( PROPERTY_COLUMN ) )
+ if (pFieldControl && _rPropertyName.equalsAsciiL(PROPERTY_COLUMN.ascii, PROPERTY_COLUMN.length))
{
aProp <<= m_xColumn;
}
- else if ( pFieldControl && 0 == _rPropertyName.compareToAscii( PROPERTY_ACTIVE_CONNECTION ) )
+ else if (pFieldControl && _rPropertyName.equalsAsciiL(PROPERTY_ACTIVE_CONNECTION.ascii, PROPERTY_ACTIVE_CONNECTION.length))
{
aProp <<= pFieldControl->getConnection();
}
diff --git a/dbaccess/source/ui/uno/unoDirectSql.cxx b/dbaccess/source/ui/uno/unoDirectSql.cxx
index 90219f268d31..931862f97287 100644
--- a/dbaccess/source/ui/uno/unoDirectSql.cxx
+++ b/dbaccess/source/ui/uno/unoDirectSql.cxx
@@ -80,7 +80,7 @@ DBG_NAME(ODirectSQLDialog)
IMPLEMENT_IMPLEMENTATION_ID( ODirectSQLDialog )
//---------------------------------------------------------------------
- IMPLEMENT_SERVICE_INFO1_STATIC( ODirectSQLDialog, "com.sun.star.comp.sdb.DirectSQLDialog", SERVICE_SDB_DIRECTSQLDIALOG )
+ IMPLEMENT_SERVICE_INFO1_STATIC( ODirectSQLDialog, "com.sun.star.comp.sdb.DirectSQLDialog", SERVICE_SDB_DIRECTSQLDIALOG.ascii )
//---------------------------------------------------------------------
IMPLEMENT_PROPERTYCONTAINER_DEFAULTS( ODirectSQLDialog )