[Libreoffice-commits] .: sfx2/source
Gert Faller
gfaller at kemper.freedesktop.org
Sat Nov 20 14:49:05 PST 2010
sfx2/source/appl/fileobj.cxx | 4 ++--
sfx2/source/bastyp/fltfnc.cxx | 20 ++++++++++----------
sfx2/source/bastyp/frmhtmlw.cxx | 18 +++++++++---------
sfx2/source/config/evntconf.cxx | 2 +-
sfx2/source/dialog/filedlghelper.cxx | 4 ++--
sfx2/source/dialog/filtergrouping.cxx | 2 +-
sfx2/source/notify/eventsupplier.cxx | 10 +++++-----
7 files changed, 30 insertions(+), 30 deletions(-)
New commits:
commit 53bd41bbf733c47dc8d7b9dd699b1953d97f87fc
Author: Gert Faller <gertfaller at aliceadsl.fr>
Date: Sat Nov 20 23:48:23 2010 +0100
RTL_CONSTASCII_USTRINGPARAM in libs core 28
diff --git a/sfx2/source/appl/fileobj.cxx b/sfx2/source/appl/fileobj.cxx
index 1a16444..a09999a 100644
--- a/sfx2/source/appl/fileobj.cxx
+++ b/sfx2/source/appl/fileobj.cxx
@@ -419,7 +419,7 @@ String impl_getFilter( const String& _rURL )
{
css::uno::Reference< ::com::sun::star::document::XTypeDetection > xTypeDetection(
::comphelper::getProcessServiceFactory()->createInstance(
- ::rtl::OUString::createFromAscii("com.sun.star.document.TypeDetection") ),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.TypeDetection")) ),
css::uno::UNO_QUERY );
if ( xTypeDetection.is() )
{
@@ -436,7 +436,7 @@ String impl_getFilter( const String& _rURL )
{
::comphelper::SequenceAsHashMap lTypeProps( xTypeCont->getByName( sType ) );
sFilter = lTypeProps.getUnpackedValueOrDefault(
- ::rtl::OUString::createFromAscii("PreferredFilter"), ::rtl::OUString() );
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PreferredFilter")), ::rtl::OUString() );
}
}
}
diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx
index 5ec078b..e001943 100644
--- a/sfx2/source/bastyp/fltfnc.cxx
+++ b/sfx2/source/bastyp/fltfnc.cxx
@@ -368,7 +368,7 @@ sal_uInt32 SfxFilterMatcher::GuessFilterIgnoringContent(
SfxFilterFlags nMust,
SfxFilterFlags nDont ) const
{
- Reference< XTypeDetection > xDetection( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.document.TypeDetection")), UNO_QUERY );
+ Reference< XTypeDetection > xDetection( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.TypeDetection"))), UNO_QUERY );
::rtl::OUString sTypeName;
try
{
@@ -420,7 +420,7 @@ sal_uInt32 SfxFilterMatcher::GuessFilterControlDefaultUI( SfxMedium& rMedium, c
const SfxFilter* pOldFilter = *ppFilter;
// no detection service -> nothing to do !
- Reference< XTypeDetection > xDetection( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.document.TypeDetection")), UNO_QUERY );
+ Reference< XTypeDetection > xDetection( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.TypeDetection"))), UNO_QUERY );
if (!xDetection.is())
return ERRCODE_ABORT;
@@ -466,7 +466,7 @@ sal_uInt32 SfxFilterMatcher::GuessFilterControlDefaultUI( SfxMedium& rMedium, c
// The DocumentService property is only a preselection, and all preselections are considered as optional!
// This "wrong" type will be sorted out now because we match only allowed filters to the detected type
::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue > lQuery(1);
- lQuery[0].Name = ::rtl::OUString::createFromAscii("Name");
+ lQuery[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
lQuery[0].Value <<= sTypeName;
const SfxFilter* pFilter = GetFilterForProps(lQuery, nMust, nDont);
@@ -639,7 +639,7 @@ const SfxFilter* SfxFilterMatcher::GetFilterForProps( const com::sun::star::uno:
::rtl::OUString aValue;
// try to get the preferred filter (works without loading all filters!)
- if ( (aProps[::rtl::OUString::createFromAscii("PreferredFilter")] >>= aValue) && aValue.getLength() )
+ if ( (aProps[::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PreferredFilter"))] >>= aValue) && aValue.getLength() )
{
const SfxFilter* pFilter = SfxFilter::GetFilterByName( aValue );
if ( !pFilter || (pFilter->GetFilterFlags() & nMust) != nMust || (pFilter->GetFilterFlags() & nDont ) )
@@ -655,7 +655,7 @@ const SfxFilter* SfxFilterMatcher::GetFilterForProps( const com::sun::star::uno:
{
// preferred filter belongs to another document type; now we must search the filter
pImpl->InitForIterating();
- aProps[::rtl::OUString::createFromAscii("Name")] >>= aValue;
+ aProps[::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"))] >>= aValue;
pFilter = GetFilter4EA( aValue, nMust, nDont );
if ( pFilter )
return pFilter;
@@ -689,7 +689,7 @@ const SfxFilter* SfxFilterMatcher::GetFilter4Mime( const String& rMediaType,SfxF
}
com::sun::star::uno::Sequence < com::sun::star::beans::NamedValue > aSeq(1);
- aSeq[0].Name = ::rtl::OUString::createFromAscii("MediaType");
+ aSeq[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MediaType"));
aSeq[0].Value <<= ::rtl::OUString( rMediaType );
return GetFilterForProps( aSeq, nMust, nDont );
}
@@ -719,7 +719,7 @@ const SfxFilter* SfxFilterMatcher::GetFilter4EA( const String& rType,SfxFilterFl
}
com::sun::star::uno::Sequence < com::sun::star::beans::NamedValue > aSeq(1);
- aSeq[0].Name = ::rtl::OUString::createFromAscii("Name");
+ aSeq[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
aSeq[0].Value <<= ::rtl::OUString( rType );
return GetFilterForProps( aSeq, nMust, nDont );
}
@@ -759,7 +759,7 @@ const SfxFilter* SfxFilterMatcher::GetFilter4Extension( const String& rExt, SfxF
sExt.Erase(0,1);
com::sun::star::uno::Sequence < com::sun::star::beans::NamedValue > aSeq(1);
- aSeq[0].Name = ::rtl::OUString::createFromAscii("Extensions");
+ aSeq[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Extensions"));
::com::sun::star::uno::Sequence < ::rtl::OUString > aExts(1);
aExts[0] = sExt;
aSeq[0].Value <<= aExts;
@@ -789,7 +789,7 @@ const SfxFilter* SfxFilterMatcher::GetFilter4ClipBoardId( sal_uInt32 nId, SfxFil
com::sun::star::uno::Sequence < com::sun::star::beans::NamedValue > aSeq(1);
::rtl::OUString aName = SotExchange::GetFormatName( nId );
- aSeq[0].Name = ::rtl::OUString::createFromAscii("ClipboardFormat");
+ aSeq[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ClipboardFormat"));
aSeq[0].Value <<= aName;
return GetFilterForProps( aSeq, nMust, nDont );
}
@@ -1199,7 +1199,7 @@ void SfxFilterContainer::ReadFilters_Impl( BOOL bUpdate )
// And conditional breakpoints on unicode values seams not to be supported .-(
#ifdef DEBUG
bool bDBGStop = FALSE;
- if (sFilterName.indexOf(::rtl::OUString::createFromAscii("DBG_"))>-1)
+ if (sFilterName.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DBG_")))>-1)
bDBGStop = TRUE;
#endif
diff --git a/sfx2/source/bastyp/frmhtmlw.cxx b/sfx2/source/bastyp/frmhtmlw.cxx
index 3e5adbd..4086891 100644
--- a/sfx2/source/bastyp/frmhtmlw.cxx
+++ b/sfx2/source/bastyp/frmhtmlw.cxx
@@ -235,7 +235,7 @@ void SfxFrameHTMLWriter::Out_DocInfo( SvStream& rStrm, const String& rBaseURL,
uno::Reference < script::XTypeConverter > xConverter(
::comphelper::getProcessServiceFactory()->createInstance(
- ::rtl::OUString::createFromAscii("com.sun.star.script.Converter")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.script.Converter"))),
uno::UNO_QUERY_THROW );
uno::Reference<beans::XPropertySet> xUserDefinedProps(
i_xDocProps->getUserDefinedProperties(), uno::UNO_QUERY_THROW);
@@ -289,7 +289,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
{
ByteString sOut;
::rtl::OUString aStr;
- uno::Any aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameURL") );
+ uno::Any aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameURL")) );
if ( (aAny >>= aStr) && aStr.getLength() )
{
String aURL = INetURLObject( aStr ).GetMainURL( INetURLObject::DECODE_TO_IURI );
@@ -304,7 +304,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
}
}
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameName") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameName")) );
if ( (aAny >>= aStr) && aStr.getLength() )
{
((sOut += ' ') += OOO_STRING_SVTOOLS_HTML_O_name) += "=\"";
@@ -314,18 +314,18 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
}
sal_Int32 nVal = SIZE_NOT_SET;
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameMarginWidth") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameMarginWidth")) );
if ( (aAny >>= nVal) && nVal != SIZE_NOT_SET )
(((sOut += ' ') += OOO_STRING_SVTOOLS_HTML_O_marginwidth) += '=') += ByteString::CreateFromInt32( nVal );
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameMarginHeight") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameMarginHeight")) );
if ( (aAny >>= nVal) && nVal != SIZE_NOT_SET )
(((sOut += ' ') += OOO_STRING_SVTOOLS_HTML_O_marginheight) += '=') += ByteString::CreateFromInt32( nVal );
sal_Bool bVal = sal_True;
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameIsAutoScroll") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameIsAutoScroll")) );
if ( (aAny >>= bVal) && !bVal )
{
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameIsScrollingMode") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameIsScrollingMode")) );
if ( aAny >>= bVal )
{
const sal_Char *pStr = bVal ? sHTML_SC_yes : sHTML_SC_no;
@@ -334,10 +334,10 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
}
// frame border (MS+Netscape-Erweiterung)
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameIsAutoBorder") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameIsAutoBorder")) );
if ( (aAny >>= bVal) && !bVal )
{
- aAny = xSet->getPropertyValue( ::rtl::OUString::createFromAscii("FrameIsBorder") );
+ aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameIsBorder")) );
if ( aAny >>= bVal )
{
const char* pStr = bVal ? sHTML_SC_yes : sHTML_SC_no;
diff --git a/sfx2/source/config/evntconf.cxx b/sfx2/source/config/evntconf.cxx
index 6f69830..91c8826 100644
--- a/sfx2/source/config/evntconf.cxx
+++ b/sfx2/source/config/evntconf.cxx
@@ -252,7 +252,7 @@ void PropagateEvent_Impl( SfxObjectShell *pDoc, rtl::OUString aEventName, const
{
xSupplier = uno::Reference < document::XEventsSupplier >
( ::comphelper::getProcessServiceFactory()->createInstance(
- rtl::OUString::createFromAscii("com.sun.star.frame.GlobalEventBroadcaster" )), uno::UNO_QUERY );
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.GlobalEventBroadcaster"))), uno::UNO_QUERY );
}
if ( xSupplier.is() )
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index ab0cff3..9ab7c21 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -1627,7 +1627,7 @@ ErrCode FileDialogHelper_Impl::execute( SvStringsDtor*& rpURLList,
if ( ( aValue >>= bPassWord ) && bPassWord )
{
// ask for a password
- uno::Reference < ::com::sun::star::task::XInteractionHandler > xInteractionHandler( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.comp.uui.UUIInteractionHandler")), UNO_QUERY );
+ uno::Reference < ::com::sun::star::task::XInteractionHandler > xInteractionHandler( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.uui.UUIInteractionHandler"))), UNO_QUERY );
if( xInteractionHandler.is() )
{
@@ -1842,7 +1842,7 @@ void FileDialogHelper_Impl::addFilters( sal_Int64 nFlags,
uno::Reference< XMultiServiceFactory > xSMGR = ::comphelper::getProcessServiceFactory();
uno::Reference< XContainerQuery > xFilterCont(
- xSMGR->createInstance(::rtl::OUString::createFromAscii("com.sun.star.document.FilterFactory")),
+ xSMGR->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.FilterFactory"))),
UNO_QUERY);
if ( ! xFilterCont.is() )
return;
diff --git a/sfx2/source/dialog/filtergrouping.cxx b/sfx2/source/dialog/filtergrouping.cxx
index 8fd6f7d..9bf1307 100644
--- a/sfx2/source/dialog/filtergrouping.cxx
+++ b/sfx2/source/dialog/filtergrouping.cxx
@@ -920,7 +920,7 @@ namespace sfx2
{
::comphelper::SequenceAsHashMap lFilterProps (xFilterList->nextElement());
::rtl::OUString sFilterName = lFilterProps.getUnpackedValueOrDefault(
- ::rtl::OUString::createFromAscii("Name"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name")),
::rtl::OUString());
if (sFilterName.getLength())
m_lFilters.push_back(sFilterName);
diff --git a/sfx2/source/notify/eventsupplier.cxx b/sfx2/source/notify/eventsupplier.cxx
index 5a10a1d..a94d288 100644
--- a/sfx2/source/notify/eventsupplier.cxx
+++ b/sfx2/source/notify/eventsupplier.cxx
@@ -282,7 +282,7 @@ static void Execute( ANY& aEventData, const css::document::DocumentEvent& aTrigg
if ( xDisp.is() )
{
//::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue > aArgs(1);
- //aArgs[0].Name = rtl::OUString::createFromAscii("Referer");
+ //aArgs[0].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Referer"));
//aArs[0].Value <<= ::rtl::OUString( pDoc->GetMedium()->GetName() );
//xDisp->dispatch( aURL, aArgs );
@@ -597,7 +597,7 @@ css::uno::Any SAL_CALL ModelCollectionEnumeration::nextElement()
::osl::ResettableMutexGuard aLock(m_aLock);
if (m_pEnumerationIt == m_lModels.end())
throw css::container::NoSuchElementException(
- ::rtl::OUString::createFromAscii("End of model enumeration reached."),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("End of model enumeration reached.")),
static_cast< css::container::XEnumeration* >(this));
css::uno::Reference< css::frame::XModel > xModel(*m_pEnumerationIt, UNO_QUERY);
++m_pEnumerationIt;
@@ -623,7 +623,7 @@ SfxGlobalEvents_Impl::SfxGlobalEvents_Impl( const com::sun::star::uno::Reference
pImp = new GlobalEventConfig();
m_xEvents = pImp;
m_xJobExecutorListener = css::uno::Reference< css::document::XEventListener >(
- xSMGR->createInstance(::rtl::OUString::createFromAscii("com.sun.star.task.JobExecutor")),
+ xSMGR->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.task.JobExecutor"))),
UNO_QUERY);
m_refCount--;
}
@@ -746,7 +746,7 @@ void SAL_CALL SfxGlobalEvents_Impl::insert( const css::uno::Any& aElement )
aElement >>= xDoc;
if (!xDoc.is())
throw css::lang::IllegalArgumentException(
- ::rtl::OUString::createFromAscii("Cant locate at least the model parameter."),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Cant locate at least the model parameter.")),
static_cast< css::container::XSet* >(this),
0);
@@ -783,7 +783,7 @@ void SAL_CALL SfxGlobalEvents_Impl::remove( const css::uno::Any& aElement )
aElement >>= xDoc;
if (!xDoc.is())
throw css::lang::IllegalArgumentException(
- ::rtl::OUString::createFromAscii("Cant locate at least the model parameter."),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Cant locate at least the model parameter.")),
static_cast< css::container::XSet* >(this),
0);
More information about the Libreoffice-commits
mailing list