diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-12-05 08:47:18 +0200 |
---|---|---|
committer | Ashod Nakashian <ashod.nakashian@collabora.co.uk> | 2017-12-18 01:07:53 -0500 |
commit | 3c4333c24882d6699b65d109f2cfbf7daf3122c6 (patch) | |
tree | 739dacdd38ddd2053aaa3ad7f0ffc053eb515d52 /filter | |
parent | 6b631a02d36aa09f7c06793e8b4482d3b67ab258 (diff) |
convert DecodeMechanism to scoped enum
(cherry picked from commit bfde4866e07746eafa2f0d6173c29d805cc35ad0)
(cherry picked from commit 3de922d4a695e253d4ca2d42b70e0b35b52e9b7c)
Change-Id: I5c56634b1bca8e37fa73d02d2428645301b6c547
Diffstat (limited to 'filter')
-rw-r--r-- | filter/source/config/cache/filtercache.cxx | 2 | ||||
-rw-r--r-- | filter/source/config/cache/typedetection.cxx | 2 | ||||
-rw-r--r-- | filter/source/msfilter/escherex.cxx | 2 | ||||
-rw-r--r-- | filter/source/msfilter/msdffimp.cxx | 4 | ||||
-rw-r--r-- | filter/source/pdf/pdfexport.cxx | 2 | ||||
-rw-r--r-- | filter/source/storagefilterdetect/filterdetect.cxx | 2 | ||||
-rw-r--r-- | filter/source/textfilterdetect/filterdetect.cxx | 2 | ||||
-rw-r--r-- | filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx | 4 | ||||
-rw-r--r-- | filter/source/xsltdialog/xmlfiltertestdialog.cxx | 2 | ||||
-rw-r--r-- | filter/source/xsltfilter/XSLTFilter.cxx | 4 |
10 files changed, 13 insertions, 13 deletions
diff --git a/filter/source/config/cache/filtercache.cxx b/filter/source/config/cache/filtercache.cxx index d1a56b7997a3..86d092e73b1a 100644 --- a/filter/source/config/cache/filtercache.cxx +++ b/filter/source/config/cache/filtercache.cxx @@ -688,7 +688,7 @@ void FilterCache::detectFlatForURL(const css::util::URL& aURL , INetURLObject aParser (aURL.Main); OUString sExtension = aParser.getExtension(INetURLObject::LAST_SEGMENT , true , - INetURLObject::DECODE_WITH_CHARSET); + INetURLObject::DecodeMechanism::WithCharset); sExtension = sExtension.toAsciiLowerCase(); // SAFE -> ---------------------------------- diff --git a/filter/source/config/cache/typedetection.cxx b/filter/source/config/cache/typedetection.cxx index 16c0f1e9a2a6..d789df9a51cd 100644 --- a/filter/source/config/cache/typedetection.cxx +++ b/filter/source/config/cache/typedetection.cxx @@ -675,7 +675,7 @@ bool TypeDetection::impl_getPreselectionForType( INetURLObject aParser (aParsedURL.Main); OUString sExtension = aParser.getExtension(INetURLObject::LAST_SEGMENT , true , - INetURLObject::DECODE_WITH_CHARSET); + INetURLObject::DecodeMechanism::WithCharset); sExtension = sExtension.toAsciiLowerCase(); // otherwise we must know, if it matches to the given URL really. diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx index 961266bac179..9dc283e501ff 100644 --- a/filter/source/msfilter/escherex.cxx +++ b/filter/source/msfilter/escherex.cxx @@ -1584,7 +1584,7 @@ bool EscherPropertyContainer::CreateGraphicProperties( nFormat != GraphicFileFormat::EMF) ) { std::unique_ptr<SvStream> pIn(::utl::UcbStreamHelper::CreateStream( - aTmp.GetMainURL( INetURLObject::NO_DECODE ), StreamMode::READ )); + aTmp.GetMainURL( INetURLObject::DecodeMechanism::NONE ), StreamMode::READ )); if ( pIn ) { Graphic aGraphic; diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx index 420d9727b668..725dc9ecf998 100644 --- a/filter/source/msfilter/msdffimp.cxx +++ b/filter/source/msfilter/msdffimp.cxx @@ -3972,7 +3972,7 @@ SdrObject* SvxMSDffManager::ImportGraphic( SvStream& rSt, SfxItemSet& rSet, cons GraphicFilter &rGrfFilter = GraphicFilter::GetGraphicFilter(); aLinkFilterName = rGrfFilter.GetImportFormatName( rGrfFilter.GetImportFormatNumberForShortName( aAbsURL.getExtension() ) ); - aLinkFileName = aAbsURL.GetMainURL( INetURLObject::DECODE_TO_IURI ); + aLinkFileName = aAbsURL.GetMainURL( INetURLObject::DecodeMechanism::ToIUri ); } else aLinkFileName = aFileName; @@ -6454,7 +6454,7 @@ bool SvxMSDffManager::GetBLIPDirect( SvStream& rBLIPStream, Graphic& rData, Rect aURL.removeFinalSlash(); aURL.Append( aFileName ); - aURLStr = aURL.GetMainURL( INetURLObject::NO_DECODE ); + aURLStr = aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ); SAL_INFO("filter.ms", "dumping " << aURLStr); diff --git a/filter/source/pdf/pdfexport.cxx b/filter/source/pdf/pdfexport.cxx index e75a52f9c228..ad6f29ec76a8 100644 --- a/filter/source/pdf/pdfexport.cxx +++ b/filter/source/pdf/pdfexport.cxx @@ -564,7 +564,7 @@ bool PDFExport::Export( const OUString& rFile, const Sequence< PropertyValue >& rFilterData[ nData ].Value >>= mbUseReferenceXObject; } - aContext.URL = aURL.GetMainURL(INetURLObject::DECODE_TO_IURI); + aContext.URL = aURL.GetMainURL(INetURLObject::DecodeMechanism::ToIUri); // set the correct version, depending on user request switch( mnPDFTypeSelection ) diff --git a/filter/source/storagefilterdetect/filterdetect.cxx b/filter/source/storagefilterdetect/filterdetect.cxx index fa10c3c4e77a..a549ec64f19a 100644 --- a/filter/source/storagefilterdetect/filterdetect.cxx +++ b/filter/source/storagefilterdetect/filterdetect.cxx @@ -121,7 +121,7 @@ OUString SAL_CALL StorageFilterDetect::detect(uno::Sequence<beans::PropertyValue if ( xInteraction.is() ) { INetURLObject aParser( aMediaDesc.getUnpackedValueOrDefault( MediaDescriptor::PROP_URL(), OUString() ) ); - OUString aDocumentTitle = aParser.getName( INetURLObject::LAST_SEGMENT, true, INetURLObject::DECODE_WITH_CHARSET ); + OUString aDocumentTitle = aParser.getName( INetURLObject::LAST_SEGMENT, true, INetURLObject::DecodeMechanism::WithCharset ); bool bRepairPackage = aMediaDesc.getUnpackedValueOrDefault( "RepairPackage", false ); // fdo#46310 Don't try to repair if the user rejected it once. bool bRepairAllowed = aMediaDesc.getUnpackedValueOrDefault( "RepairAllowed", true ); diff --git a/filter/source/textfilterdetect/filterdetect.cxx b/filter/source/textfilterdetect/filterdetect.cxx index 3368af1e79aa..b8f9cab62cba 100644 --- a/filter/source/textfilterdetect/filterdetect.cxx +++ b/filter/source/textfilterdetect/filterdetect.cxx @@ -168,7 +168,7 @@ OUString SAL_CALL PlainTextFilterDetect::detect(uno::Sequence<beans::PropertyVal } // Get the file name extension. INetURLObject aParser(aMediaDesc.getUnpackedValueOrDefault(MediaDescriptor::PROP_URL(), OUString() ) ); - OUString aExt = aParser.getExtension(INetURLObject::LAST_SEGMENT, true, INetURLObject::DECODE_WITH_CHARSET); + OUString aExt = aParser.getExtension(INetURLObject::LAST_SEGMENT, true, INetURLObject::DecodeMechanism::WithCharset); aExt = aExt.toAsciiLowerCase(); OUString aName = aParser.getName().toAsciiLowerCase(); diff --git a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx index 88d829dead0b..13cfb4a27606 100644 --- a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx +++ b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx @@ -89,7 +89,7 @@ bool SAL_CALL XmlFilterAdaptor::importImpl( const Sequence< css::beans::Property INetURLObject aURLObj(aBaseURI); // base URI in this case is the URI of the actual saving location // aURLObj.removeSegment(); - aBaseURI = aURLObj.GetMainURL(INetURLObject::NO_DECODE); + aBaseURI = aURLObj.GetMainURL(INetURLObject::DecodeMechanism::NONE); } // create an XProperty set to configure the exporter for pretty printing @@ -242,7 +242,7 @@ bool SAL_CALL XmlFilterAdaptor::exportImpl( const Sequence< css::beans::Property INetURLObject aURLObj(aBaseURI); // base URI in this case is the URI of the actual saving location // aURLObj.removeSegment(); - aBaseURI = aURLObj.GetMainURL(INetURLObject::NO_DECODE); + aBaseURI = aURLObj.GetMainURL(INetURLObject::DecodeMechanism::NONE); } // create an XProperty set to configure the exporter for pretty printing diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.cxx b/filter/source/xsltdialog/xmlfiltertestdialog.cxx index 686d1427cf78..eb6900a2b661 100644 --- a/filter/source/xsltdialog/xmlfiltertestdialog.cxx +++ b/filter/source/xsltdialog/xmlfiltertestdialog.cxx @@ -226,7 +226,7 @@ void XMLFilterTestDialog::test( const filter_info_impl& rFilterInfo ) static OUString getFileNameFromURL( OUString& rURL ) { INetURLObject aURL( rURL ); - OUString aName( aURL.getName(INetURLObject::LAST_SEGMENT, true, INetURLObject::DECODE_WITH_CHARSET) ); + OUString aName( aURL.getName(INetURLObject::LAST_SEGMENT, true, INetURLObject::DecodeMechanism::WithCharset) ); return aName; } diff --git a/filter/source/xsltfilter/XSLTFilter.cxx b/filter/source/xsltfilter/XSLTFilter.cxx index 1deb70ff6286..38dbb8ae7dc9 100644 --- a/filter/source/xsltfilter/XSLTFilter.cxx +++ b/filter/source/xsltfilter/XSLTFilter.cxx @@ -261,7 +261,7 @@ namespace XSLT bool bWasAbsolute; INetURLObject aURL = aObj.smartRel2Abs(s, bWasAbsolute, false, INetURLObject::EncodeMechanism::WasEncoded, RTL_TEXTENCODING_UTF8, true); - return aURL.GetMainURL(INetURLObject::NO_DECODE); + return aURL.GetMainURL(INetURLObject::DecodeMechanism::NONE); } sal_Bool @@ -461,7 +461,7 @@ namespace XSLT nv.Name = "TargetBaseURL"; INetURLObject ineturl(sURL); ineturl.removeSegment(); - m_aExportBaseUrl = ineturl.GetMainURL(INetURLObject::NO_DECODE); + m_aExportBaseUrl = ineturl.GetMainURL(INetURLObject::DecodeMechanism::NONE); nv.Value <<= m_aExportBaseUrl; args[3] <<= nv; |