diff options
author | Oliver Bolte <obo@openoffice.org> | 2007-01-23 06:14:41 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2007-01-23 06:14:41 +0000 |
commit | 1a8b3fb4024b61af655d97bae19d3adbf80a6da6 (patch) | |
tree | c98b4a9ff3e5dd4c99762e65993b504e26bceb82 /sfx2 | |
parent | c18b99ee6039448678d869fcee53ddeb38c7845a (diff) |
INTEGRATION: CWS fwk58 (1.20.102); FILE MERGED
2007/01/17 15:59:05 mba 1.20.102.2: #i72240#: new StartPrintHandler
2006/12/06 15:16:14 mba 1.20.102.1: #i72240#: don't send JOB_STARTED event before printing acually started
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/view/prnmon.cxx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sfx2/source/view/prnmon.cxx b/sfx2/source/view/prnmon.cxx index 423dec10ab1c..01d65490dc42 100644 --- a/sfx2/source/view/prnmon.cxx +++ b/sfx2/source/view/prnmon.cxx @@ -4,9 +4,9 @@ * * $RCSfile: prnmon.cxx,v $ * - * $Revision: 1.20 $ + * $Revision: 1.21 $ * - * last change: $Author: obo $ $Date: 2006-09-17 16:50:24 $ + * last change: $Author: obo $ $Date: 2007-01-23 07:14:41 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -84,6 +84,7 @@ #include "sfxresid.hxx" #include "event.hxx" #include "request.hxx" +#include "app.hxx" #include "view.hrc" @@ -303,6 +304,7 @@ SfxPrintProgress::SfxPrintProgress( SfxViewShell* pViewSh, FASTBOOL bShow ) { pImp->pPrinter->SetEndPrintHdl( LINK( this, SfxPrintProgress, EndPrintNotify ) ); pImp->pPrinter->SetErrorHdl( LINK( this, SfxPrintProgress, PrintErrorNotify ) ); + pImp->pPrinter->SetStartPrintHdl( LINK( this, SfxPrintProgress, StartPrintNotify ) ); pImp->bCallbacks = TRUE; SfxObjectShell* pDoc = pViewSh->GetObjectShell(); @@ -411,6 +413,14 @@ IMPL_LINK_INLINE_END( SfxPrintProgress, PrintErrorNotify, void *, EMPTYARG ) //------------------------------------------------------------------------ +IMPL_LINK( SfxPrintProgress, StartPrintNotify, void *, EMPTYARG ) +{ + SfxObjectShell *pObjShell = pImp->pViewShell->GetObjectShell(); + SFX_APP()->NotifyEvent(SfxEventHint(SFX_EVENT_PRINTDOC, pObjShell)); + pObjShell->Broadcast( SfxPrintingHint( com::sun::star::view::PrintableState_JOB_STARTED, NULL, NULL ) ); + return 0; +} + IMPL_LINK( SfxPrintProgress, EndPrintNotify, void *, EMPTYARG ) { if ( pImp->pMonitor ) |