summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2008-05-21 07:33:43 +0000
committerKurt Zenker <kz@openoffice.org>2008-05-21 07:33:43 +0000
commitd4beb6a05d81e988901794247aeb51293a70db0d (patch)
tree31698cc85e833a6af1436c1d321dc8fa43cbc6e5 /sfx2
parentcdeaeb448987e8e49b5c168bb73101d64145df1d (diff)
INTEGRATION: CWS late241bf01_DEV300 (1.131.26.4.18); FILE MERGED
2008/05/16 12:58:52 mba 1.131.26.4.18.2: #157928#: forward PrintJobListeners to PrintingHelper 2008/05/16 12:57:09 mba 1.131.26.4.18.1: #157928#: forward PrintJobListeners to PrintingHelper
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/doc/sfxbasemodel.cxx20
1 files changed, 17 insertions, 3 deletions
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index b5771b9395b9..28dc8f4709e3 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -7,7 +7,7 @@
* OpenOffice.org - a multi-platform office productivity suite
*
* $RCSfile: sfxbasemodel.cxx,v $
- * $Revision: 1.142 $
+ * $Revision: 1.143 $
*
* This file is part of OpenOffice.org.
*
@@ -2842,7 +2842,14 @@ void SAL_CALL SfxBaseModel::addPrintJobListener( const uno::Reference< view::XPr
if ( impl_isDisposed() )
return;
- m_pData->m_aInterfaceContainer.addInterface( ::getCppuType((const uno::Reference< view::XPrintJobListener >*)0), xListener );
+ if ( impl_getPrintHelper() )
+ {
+ uno::Reference < view::XPrintJobBroadcaster > xPJB( m_pData->m_xPrintable, uno::UNO_QUERY );
+ if ( xPJB.is() )
+ xPJB->addPrintJobListener( xListener );
+ }
+// else
+// m_pData->m_aInterfaceContainer.addInterface( ::getCppuType((const uno::Reference< view::XPrintJobListener >*)0), xListener );
}
void SAL_CALL SfxBaseModel::removePrintJobListener( const uno::Reference< view::XPrintJobListener >& xListener ) throw (uno::RuntimeException)
@@ -2852,7 +2859,14 @@ void SAL_CALL SfxBaseModel::removePrintJobListener( const uno::Reference< view::
if ( impl_isDisposed() )
return;
- m_pData->m_aInterfaceContainer.removeInterface( ::getCppuType((const uno::Reference< view::XPrintJobListener >*)0), xListener );
+ if ( impl_getPrintHelper() )
+ {
+ uno::Reference < view::XPrintJobBroadcaster > xPJB( m_pData->m_xPrintable, uno::UNO_QUERY );
+ if ( xPJB.is() )
+ xPJB->removePrintJobListener( xListener );
+ }
+// else
+// m_pData->m_aInterfaceContainer.addInterface( ::getCppuType((const uno::Reference< view::XPrintJobListener >*)0), xListener );
}
// simple declaration of class SvObject is enough