summaryrefslogtreecommitdiff
path: root/filter/source/xsltdialog/xmlfiltertestdialog.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-05-02 10:36:43 +0200
committerNoel Grandin <noelgrandin@gmail.com>2013-05-22 10:44:29 +0000
commit6a043e9c0acff20e1618ca8ec15c21d5d0fd0d37 (patch)
tree2746468845d6f1159e3759ee2cf7a620fca15b6e /filter/source/xsltdialog/xmlfiltertestdialog.cxx
parent697a007c61b9cabceb9767fad87cd5822b300452 (diff)
Use the new type-checking Reference constructor to reduce code noise
Also create a Clang compiler plugin to detect such cases. Change-Id: I61ad1a1d6b1c017eeb51f226d2dde0e9bb7f1752 Reviewed-on: https://gerrit.libreoffice.org/4001 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'filter/source/xsltdialog/xmlfiltertestdialog.cxx')
-rw-r--r--filter/source/xsltdialog/xmlfiltertestdialog.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.cxx b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
index 099aec7933d6..807393253b0b 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
@@ -630,11 +630,10 @@ void XMLFilterTestDialog::import( const OUString& rURL )
aOutputFile.open( osl_File_OpenFlag_Write );
Reference< XOutputStream > xOS( new OSLOutputStreamWrapper( aOutputFile ) );
- Reference< XActiveDataSource > xDocSrc( xWriter, UNO_QUERY );
- xDocSrc->setOutputStream( xOS );
+ xWriter->setOutputStream( xOS );
Sequence< OUString > aFilterUserData( m_pFilterInfo->getFilterUserData() );
- xImporter->importer( aSourceData, Reference<XDocumentHandler>(xWriter, UNO_QUERY_THROW), aFilterUserData );
+ xImporter->importer( aSourceData, xWriter, aFilterUserData );
}
displayXMLFile( aTempFileURL );