[Libreoffice-commits] .: sfx2/source
Gert Faller
gfaller at kemper.freedesktop.org
Sat Nov 20 14:54:28 PST 2010
sfx2/source/appl/helpinterceptor.cxx | 2 -
sfx2/source/bastyp/helper.cxx | 40 +++++++++++++++++------------------
sfx2/source/doc/graphhelp.cxx | 14 ++++++------
sfx2/source/doc/iframe.cxx | 10 ++++----
sfx2/source/inet/inettbc.cxx | 10 ++++----
sfx2/source/view/ipclient.cxx | 2 -
6 files changed, 39 insertions(+), 39 deletions(-)
New commits:
commit d593eb380439af733b78436a9004061de5ca9e52
Author: Gert Faller <gertfaller at aliceadsl.fr>
Date: Sat Nov 20 23:53:54 2010 +0100
TL_CONSTASCII_USTRINGPARAM in libs core 29
diff --git a/sfx2/source/appl/helpinterceptor.cxx b/sfx2/source/appl/helpinterceptor.cxx
index a07579f..4dc6dd9 100644
--- a/sfx2/source/appl/helpinterceptor.cxx
+++ b/sfx2/source/appl/helpinterceptor.cxx
@@ -162,7 +162,7 @@ Reference< XDispatch > SAL_CALL HelpInterceptor_Impl::queryDispatch(
// INetURLObject aObj( aURL.Complete );
// sal_Bool bHelpURL = ( aObj.GetProtocol() == INET_PROT_VND_SUN_STAR_HELP );
- BOOL bHelpURL = aURL.Complete.toAsciiLowerCase().match(rtl::OUString::createFromAscii("vnd.sun.star.help"),0);
+ BOOL bHelpURL = aURL.Complete.toAsciiLowerCase().match(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.help")),0);
if ( bHelpURL )
{
diff --git a/sfx2/source/bastyp/helper.cxx b/sfx2/source/bastyp/helper.cxx
index 14dd8df..9543a07 100644
--- a/sfx2/source/bastyp/helper.cxx
+++ b/sfx2/source/bastyp/helper.cxx
@@ -103,7 +103,7 @@ sal_Bool SfxContentHelper::Transfer_Impl( const String& rSource, const String& r
{
::ucbhelper::Content aDestPath( aDestObj.GetMainURL( INetURLObject::NO_DECODE ), uno::Reference< ucb::XCommandEnvironment > () );
uno::Reference< ucb::XCommandInfo > xInfo = aDestPath.getCommands();
- OUString aTransferName = OUString::createFromAscii( "transfer" );
+ OUString aTransferName(RTL_CONSTASCII_USTRINGPARAM("transfer"));
if ( xInfo->hasCommandByName( aTransferName ) )
{
aDestPath.executeCommand( aTransferName, uno::makeAny(
@@ -206,7 +206,7 @@ sal_Bool SfxContentHelper::GetTitle( const String& rContent, String& rTitle )
{
::ucbhelper::Content aCnt( aObj.GetMainURL( INetURLObject::NO_DECODE ), uno::Reference< ucb::XCommandEnvironment > () );
OUString aTemp;
- aCnt.getPropertyValue( OUString::createFromAscii( "Title" ) ) >>= aTemp;
+ aCnt.getPropertyValue( OUString(RTL_CONSTASCII_USTRINGPARAM("Title")) ) >>= aTemp;
rTitle = String( aTemp );
bRet = sal_True;
}
@@ -232,7 +232,7 @@ sal_Bool SfxContentHelper::Kill( const String& rContent )
try
{
::ucbhelper::Content aCnt( aDeleteObj.GetMainURL( INetURLObject::NO_DECODE ), uno::Reference< ucb::XCommandEnvironment > () );
- aCnt.executeCommand( OUString::createFromAscii( "delete" ), uno::makeAny( sal_Bool( sal_True ) ) );
+ aCnt.executeCommand( OUString(RTL_CONSTASCII_USTRINGPARAM("delete")), uno::makeAny( sal_Bool( sal_True ) ) );
}
catch( ucb::CommandAbortedException& )
{
@@ -261,8 +261,8 @@ uno::Sequence < OUString > SfxContentHelper::GetFolderContents( const String& rF
uno::Reference< sdbc::XResultSet > xResultSet;
uno::Sequence< OUString > aProps(2);
OUString* pProps = aProps.getArray();
- pProps[0] = OUString::createFromAscii( "Title" );
- pProps[1] = OUString::createFromAscii( "IsFolder" );
+ pProps[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
+ pProps[1] = OUString(RTL_CONSTASCII_USTRINGPARAM("IsFolder"));
try
{
@@ -279,7 +279,7 @@ uno::Sequence < OUString > SfxContentHelper::GetFolderContents( const String& rF
uno::Reference < ucb::XAnyCompareFactory > xFactory;
uno::Reference < lang::XMultiServiceFactory > xMgr = getProcessServiceFactory();
uno::Reference < ucb::XSortedDynamicResultSetFactory > xSRSFac(
- xMgr->createInstance( ::rtl::OUString::createFromAscii("com.sun.star.ucb.SortedDynamicResultSetFactory") ), uno::UNO_QUERY );
+ xMgr->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SortedDynamicResultSetFactory")) ), uno::UNO_QUERY );
uno::Sequence< ucb::NumberedSortingInfo > aSortInfo( 2 );
ucb::NumberedSortingInfo* pInfo = aSortInfo.getArray();
@@ -369,11 +369,11 @@ uno::Sequence < OUString > SfxContentHelper::GetFolderContentProperties( const S
uno::Reference< sdbc::XResultSet > xResultSet;
uno::Sequence< OUString > aProps(5);
OUString* pProps = aProps.getArray();
- pProps[0] = OUString::createFromAscii( "Title" );
- pProps[1] = OUString::createFromAscii( "ContentType" );
- pProps[2] = OUString::createFromAscii( "Size" );
- pProps[3] = OUString::createFromAscii( "DateModified" );
- pProps[4] = OUString::createFromAscii( "IsFolder" );
+ pProps[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
+ pProps[1] = OUString(RTL_CONSTASCII_USTRINGPARAM("ContentType"));
+ pProps[2] = OUString(RTL_CONSTASCII_USTRINGPARAM("Size"));
+ pProps[3] = OUString(RTL_CONSTASCII_USTRINGPARAM("DateModified"));
+ pProps[4] = OUString(RTL_CONSTASCII_USTRINGPARAM("IsFolder"));
try
{
@@ -384,7 +384,7 @@ uno::Sequence < OUString > SfxContentHelper::GetFolderContentProperties( const S
uno::Reference < ucb::XAnyCompareFactory > xCmpFactory;
uno::Reference < lang::XMultiServiceFactory > xMgr = getProcessServiceFactory();
uno::Reference < ucb::XSortedDynamicResultSetFactory > xSRSFac(
- xMgr->createInstance( ::rtl::OUString::createFromAscii("com.sun.star.ucb.SortedDynamicResultSetFactory") ), uno::UNO_QUERY );
+ xMgr->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SortedDynamicResultSetFactory")) ), uno::UNO_QUERY );
uno::Sequence< ucb::NumberedSortingInfo > aSortInfo( 2 );
ucb::NumberedSortingInfo* pInfo = aSortInfo.getArray();
@@ -500,9 +500,9 @@ uno::Sequence < OUString > SfxContentHelper::GetResultSet( const String& rURL )
uno::Reference< ucb::XDynamicResultSet > xDynResultSet;
uno::Sequence< OUString > aProps(3);
OUString* pProps = aProps.getArray();
- pProps[0] = OUString::createFromAscii( "Title" );
- pProps[1] = OUString::createFromAscii( "ContentType" );
- pProps[2] = OUString::createFromAscii( "IsFolder" );
+ pProps[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
+ pProps[1] = OUString(RTL_CONSTASCII_USTRINGPARAM("ContentType"));
+ pProps[2] = OUString(RTL_CONSTASCII_USTRINGPARAM("IsFolder"));
try
{
@@ -596,8 +596,8 @@ uno::Sequence< OUString > SfxContentHelper::GetHelpTreeViewContents( const Strin
uno::Reference< sdbc::XResultSet > xResultSet;
uno::Sequence< OUString > aProps(2);
OUString* pProps = aProps.getArray();
- pProps[0] = OUString::createFromAscii( "Title" );
- pProps[1] = OUString::createFromAscii( "IsFolder" );
+ pProps[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
+ pProps[1] = OUString(RTL_CONSTASCII_USTRINGPARAM("IsFolder"));
try
{
@@ -707,7 +707,7 @@ sal_Bool SfxContentHelper::IsHelpErrorDocument( const String& rURL )
{
::ucbhelper::Content aCnt( INetURLObject( rURL ).GetMainURL( INetURLObject::NO_DECODE ),
uno::Reference< ucb::XCommandEnvironment > () );
- if ( !( aCnt.getPropertyValue( OUString::createFromAscii( "IsErrorDocument" ) ) >>= bRet ) )
+ if ( !( aCnt.getPropertyValue( OUString(RTL_CONSTASCII_USTRINGPARAM("IsErrorDocument")) ) >>= bRet ) )
{
DBG_ERRORFILE( "Property 'IsErrorDocument' is missing" );
}
@@ -785,7 +785,7 @@ ErrCode SfxContentHelper::QueryDiskSpace( const String& rPath, sal_Int64& rFreeB
try
{
::ucbhelper::Content aCnt( aObj.GetMainURL( INetURLObject::NO_DECODE ), uno::Reference< ucb::XCommandEnvironment > () );
- aCnt.getPropertyValue( OUString::createFromAscii( "FreeSpace" ) ) >>= rFreeBytes;
+ aCnt.getPropertyValue( OUString(RTL_CONSTASCII_USTRINGPARAM("FreeSpace")) ) >>= rFreeBytes;
}
catch( ucb::CommandAbortedException& )
{
@@ -811,7 +811,7 @@ ULONG SfxContentHelper::GetSize( const String& rContent )
try
{
::ucbhelper::Content aCnt( aObj.GetMainURL( INetURLObject::NO_DECODE ), uno::Reference< ucb::XCommandEnvironment > () );
- aCnt.getPropertyValue( OUString::createFromAscii( "Size" ) ) >>= nTemp;
+ aCnt.getPropertyValue( OUString(RTL_CONSTASCII_USTRINGPARAM("Size")) ) >>= nTemp;
}
catch( ucb::CommandAbortedException& )
{
diff --git a/sfx2/source/doc/graphhelp.cxx b/sfx2/source/doc/graphhelp.cxx
index bb91de4..524c698 100644
--- a/sfx2/source/doc/graphhelp.cxx
+++ b/sfx2/source/doc/graphhelp.cxx
@@ -118,7 +118,7 @@ void* GraphicHelper::getEnhMetaFileFromGDI_Impl( const GDIMetaFile* pGDIMeta )
#ifdef WNT
if ( pGDIMeta )
{
- String aStr = ::rtl::OUString::createFromAscii( ".emf" );
+ String aStr = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".emf"));
::utl::TempFile aTempFile( ::rtl::OUString(),
&aStr,
NULL,
@@ -464,25 +464,25 @@ sal_Bool GraphicHelper::getThumbnailReplacement_Impl( sal_Int32 nResID, const un
{
uno::Reference< graphic::XGraphicProvider > xGraphProvider(
xServiceManager->createInstance(
- ::rtl::OUString::createFromAscii( "com.sun.star.graphic.GraphicProvider" ) ),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.graphic.GraphicProvider")) ),
uno::UNO_QUERY );
if ( xGraphProvider.is() )
{
- ::rtl::OUString aURL = ::rtl::OUString::createFromAscii( "private:resource/sfx/bitmapex/" );
+ ::rtl::OUString aURL(RTL_CONSTASCII_USTRINGPARAM("private:resource/sfx/bitmapex/"));
aURL += ::rtl::OUString::valueOf( nResID );
uno::Sequence< beans::PropertyValue > aMediaProps( 1 );
- aMediaProps[0].Name = ::rtl::OUString::createFromAscii( "URL" );
+ aMediaProps[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URL"));
aMediaProps[0].Value <<= aURL;
uno::Reference< graphic::XGraphic > xGraphic = xGraphProvider->queryGraphic( aMediaProps );
if ( xGraphic.is() )
{
uno::Sequence< beans::PropertyValue > aStoreProps( 2 );
- aStoreProps[0].Name = ::rtl::OUString::createFromAscii( "OutputStream" );
+ aStoreProps[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OutputStream"));
aStoreProps[0].Value <<= xStream;
- aStoreProps[1].Name = ::rtl::OUString::createFromAscii( "MimeType" );
- aStoreProps[1].Value <<= ::rtl::OUString::createFromAscii( "image/png" );
+ aStoreProps[1].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MimeType"));
+ aStoreProps[1].Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("image/png"));
xGraphProvider->storeGraphic( xGraphic, aStoreProps );
bResult = sal_True;
diff --git a/sfx2/source/doc/iframe.cxx b/sfx2/source/doc/iframe.cxx
index 2a64464..8d9622a 100644
--- a/sfx2/source/doc/iframe.cxx
+++ b/sfx2/source/doc/iframe.cxx
@@ -160,7 +160,7 @@ throw( uno::RuntimeException )
// we must destroy the IFrame before the parent is destroyed
xWindow->addEventListener( this );
- mxFrame = uno::Reference< frame::XFrame >( mxFact->createInstance( ::rtl::OUString::createFromAscii( "com.sun.star.frame.Frame" ) ),
+ mxFrame = uno::Reference< frame::XFrame >( mxFact->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Frame")) ),
uno::UNO_QUERY );
uno::Reference < awt::XWindow > xWin( pWin->GetComponentInterface(), uno::UNO_QUERY );
mxFrame->initialize( xWin );
@@ -174,15 +174,15 @@ throw( uno::RuntimeException )
util::URL aTargetURL;
aTargetURL.Complete = ::rtl::OUString( maFrmDescr.GetURL().GetMainURL( INetURLObject::NO_DECODE ) );
- uno::Reference < util::XURLTransformer > xTrans( mxFact->createInstance( rtl::OUString::createFromAscii("com.sun.star.util.URLTransformer" )), uno::UNO_QUERY );
+ uno::Reference < util::XURLTransformer > xTrans( mxFact->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.URLTransformer"))), uno::UNO_QUERY );
xTrans->parseStrict( aTargetURL );
uno::Sequence < beans::PropertyValue > aProps(2);
- aProps[0].Name = ::rtl::OUString::createFromAscii("PluginMode");
+ aProps[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PluginMode"));
aProps[0].Value <<= (sal_Int16) 2;
- aProps[1].Name = ::rtl::OUString::createFromAscii("ReadOnly");
+ aProps[1].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ReadOnly"));
aProps[1].Value <<= (sal_Bool) sal_True;
- uno::Reference < frame::XDispatch > xDisp = xProv->queryDispatch( aTargetURL, ::rtl::OUString::createFromAscii("_self"), 0 );
+ uno::Reference < frame::XDispatch > xDisp = xProv->queryDispatch( aTargetURL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0 );
if ( xDisp.is() )
xDisp->dispatch( aTargetURL, aProps );
diff --git a/sfx2/source/inet/inettbc.cxx b/sfx2/source/inet/inettbc.cxx
index 1e73582..d3581b0 100644
--- a/sfx2/source/inet/inettbc.cxx
+++ b/sfx2/source/inet/inettbc.cxx
@@ -114,7 +114,7 @@ void SfxURLToolBoxControl_Impl::OpenURL( const String& rName, BOOL /*bNew*/ ) co
if ( xDispatchProvider.is() && m_xServiceManager.is() )
{
URL aTargetURL;
- ::rtl::OUString aTarget( ::rtl::OUString::createFromAscii( "_default" ));
+ ::rtl::OUString aTarget( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_default")));
aTargetURL.Complete = aName;
@@ -123,7 +123,7 @@ void SfxURLToolBoxControl_Impl::OpenURL( const String& rName, BOOL /*bNew*/ ) co
if ( xDispatch.is() )
{
Sequence< PropertyValue > aArgs( 2 );
- aArgs[0].Name = ::rtl::OUString::createFromAscii( "Referer" );
+ aArgs[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Referer"));
aArgs[0].Value = makeAny( ::rtl::OUString::createFromAscii( SFX_REFERER_USER ));
aArgs[1].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FileName" ));
aArgs[1].Value = makeAny( ::rtl::OUString( aName ));
@@ -131,9 +131,9 @@ void SfxURLToolBoxControl_Impl::OpenURL( const String& rName, BOOL /*bNew*/ ) co
if ( aFilter.Len() )
{
aArgs.realloc( 4 );
- aArgs[2].Name = ::rtl::OUString::createFromAscii( "FilterOptions" );
+ aArgs[2].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FilterOptions"));
aArgs[2].Value = makeAny( ::rtl::OUString( aOptions ));
- aArgs[3].Name = ::rtl::OUString::createFromAscii( "FilterName" );
+ aArgs[3].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FilterName"));
aArgs[3].Value = makeAny( ::rtl::OUString( aFilter ));
}
@@ -194,7 +194,7 @@ IMPL_LINK( SfxURLToolBoxControl_Impl, OpenHdl, void*, EMPTYARG )
if ( m_xServiceManager.is() )
{
Reference< XFramesSupplier > xDesktop( m_xServiceManager->createInstance(
- ::rtl::OUString::createFromAscii( "com.sun.star.frame.Desktop" )),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop"))),
UNO_QUERY );
Reference< XFrame > xFrame( xDesktop->getActiveFrame(), UNO_QUERY );
if ( xFrame.is() )
diff --git a/sfx2/source/view/ipclient.cxx b/sfx2/source/view/ipclient.cxx
index 17628cd..dd9c1b6 100644
--- a/sfx2/source/view/ipclient.cxx
+++ b/sfx2/source/view/ipclient.cxx
@@ -438,7 +438,7 @@ uno::Reference< ::com::sun::star::frame::XLayoutManager > SAL_CALL SfxInPlaceCli
uno::Reference< ::com::sun::star::frame::XLayoutManager > xMan;
try
{
- uno::Any aAny = xFrame->getPropertyValue( ::rtl::OUString::createFromAscii("LayoutManager") );
+ uno::Any aAny = xFrame->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LayoutManager")) );
aAny >>= xMan;
}
catch ( uno::Exception& )
More information about the Libreoffice-commits
mailing list