diff options
author | Ivo Hinkelmann <ihi@openoffice.org> | 2009-06-15 08:47:44 +0000 |
---|---|---|
committer | Ivo Hinkelmann <ihi@openoffice.org> | 2009-06-15 08:47:44 +0000 |
commit | 0ca8e0ea2db280fc7ce464611079b513a020199f (patch) | |
tree | 6542e82f1a655bf2419a256138dacbb7ecef3d83 /sdext/source/pdfimport/pdfiadaptor.cxx | |
parent | 19ed9c3a16889a49f6d6b222de40f7b377ff3e83 (diff) |
CWS-TOOLING: integrate CWS pdfextfix02_DEV300
2009-05-10 11:23:59 +0200 pl r271736 : #i94755# adjust extension version, add extension icon
2009-05-08 17:06:50 +0200 pl r271726 : #i92909# handle some cases of mirroring
2009-05-08 14:51:37 +0200 pl r271720 : #i95270# cope with some rotated images
2009-05-08 11:37:46 +0200 pl r271709 : #i101327# recognize non breaking space also (thanks ayaniger)
2009-05-07 13:39:06 +0200 pl r271658 : #i92598# still more masked bitmap support
2009-05-07 10:44:41 +0200 pl r271638 : remove some compiler warnings
2009-05-07 09:59:56 +0200 pl r271633 : make test compile again
2009-05-06 21:12:55 +0200 pl r271612 : #i92903# handle two color images
2009-05-06 19:48:19 +0200 pl r271610 : soft masked images
2009-05-06 16:30:36 +0200 pl r271600 : #i92598# use masked PNG images for drawMask
2009-05-05 18:40:06 +0200 pl r271550 : #i90617# #i92598# some workarounds for mask bitmaps
2009-05-04 18:53:09 +0200 pl r271479 : #i94755# add supported for encrypted PDF files
Diffstat (limited to 'sdext/source/pdfimport/pdfiadaptor.cxx')
-rw-r--r-- | sdext/source/pdfimport/pdfiadaptor.cxx | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/sdext/source/pdfimport/pdfiadaptor.cxx b/sdext/source/pdfimport/pdfiadaptor.cxx index 8b6db0ff972d..43f11c173d1c 100644 --- a/sdext/source/pdfimport/pdfiadaptor.cxx +++ b/sdext/source/pdfimport/pdfiadaptor.cxx @@ -238,6 +238,8 @@ void PDFIRawAdaptor::setTreeVisitorFactory(const TreeVisitorFactorySharedPtr& rV } bool PDFIRawAdaptor::parse( const uno::Reference<io::XInputStream>& xInput, + const uno::Reference<task::XInteractionHandler>& xIHdl, + const rtl::OUString& rPwd, const uno::Reference<task::XStatusIndicator>& xStatus, const XmlEmitterSharedPtr& rEmitter, const rtl::OUString& rURL ) @@ -253,9 +255,9 @@ bool PDFIRawAdaptor::parse( const uno::Reference<io::XInputStream>& xInput bool bSuccess=false; if( xInput.is() && (!rURL.getLength() || rURL.compareToAscii( "file:", 5 ) != 0) ) - bSuccess = xpdf_ImportFromStream( xInput, pSink, m_xContext ); + bSuccess = xpdf_ImportFromStream( xInput, pSink, xIHdl, rPwd, m_xContext ); else - bSuccess = xpdf_ImportFromFile( rURL, pSink, m_xContext ); + bSuccess = xpdf_ImportFromFile( rURL, pSink, xIHdl, rPwd, m_xContext ); if( bSuccess ) pSink->emit(*rEmitter,*m_pVisitorFactory); @@ -268,7 +270,10 @@ bool PDFIRawAdaptor::odfConvert( const rtl::OUString& r const uno::Reference<task::XStatusIndicator>& xStatus ) { XmlEmitterSharedPtr pEmitter = createOdfEmitter(xOutput); - const bool bSuccess = parse(uno::Reference<io::XInputStream>(),xStatus,pEmitter,rURL); + const bool bSuccess = parse(uno::Reference<io::XInputStream>(), + uno::Reference<task::XInteractionHandler>(), + rtl::OUString(), + xStatus,pEmitter,rURL); // tell input stream that it is no longer needed xOutput->closeOutput(); @@ -284,7 +289,9 @@ sal_Bool SAL_CALL PDFIRawAdaptor::importer( const uno::Sequence< beans::Property // get the InputStream carrying the PDF content uno::Reference< io::XInputStream > xInput; uno::Reference< task::XStatusIndicator > xStatus; + uno::Reference< task::XInteractionHandler > xInteractionHandler; rtl::OUString aURL; + rtl::OUString aPwd; const beans::PropertyValue* pAttribs = rSourceData.getConstArray(); sal_Int32 nAttribs = rSourceData.getLength(); for( sal_Int32 i = 0; i < nAttribs; i++, pAttribs++ ) @@ -296,12 +303,16 @@ sal_Bool SAL_CALL PDFIRawAdaptor::importer( const uno::Sequence< beans::Property pAttribs->Value >>= aURL; else if( pAttribs->Name.equalsAscii( "StatusIndicator" ) ) pAttribs->Value >>= xStatus; + else if( pAttribs->Name.equalsAscii( "InteractionHandler" ) ) + pAttribs->Value >>= xInteractionHandler; + else if( pAttribs->Name.equalsAscii( "Password" ) ) + pAttribs->Value >>= aPwd; } if( !xInput.is() ) return sal_False; XmlEmitterSharedPtr pEmitter = createSaxEmitter(rHdl); - const bool bSuccess = parse(xInput,xStatus,pEmitter,aURL); + const bool bSuccess = parse(xInput,xInteractionHandler, aPwd, xStatus,pEmitter,aURL); // tell input stream that it is no longer needed xInput->closeInput(); |