diff options
author | Kai Ahrens <ka@openoffice.org> | 2001-09-28 12:59:43 +0000 |
---|---|---|
committer | Kai Ahrens <ka@openoffice.org> | 2001-09-28 12:59:43 +0000 |
commit | 958238894e3e7d477f483fe20194ab85ae1da782 (patch) | |
tree | 2fcde1fcde9ff59ac98035bdc9f1586cae1623ab /sd/source/ui/view/presvish.cxx | |
parent | 89a80b88febd533d77b0c3ff460e28c2ee762a75 (diff) |
#91778#: start slide show in ::Activate
Diffstat (limited to 'sd/source/ui/view/presvish.cxx')
-rw-r--r-- | sd/source/ui/view/presvish.cxx | 47 |
1 files changed, 41 insertions, 6 deletions
diff --git a/sd/source/ui/view/presvish.cxx b/sd/source/ui/view/presvish.cxx index 4197b9a9fff9..53f6604347ca 100644 --- a/sd/source/ui/view/presvish.cxx +++ b/sd/source/ui/view/presvish.cxx @@ -2,9 +2,9 @@ * * $RCSfile: presvish.cxx,v $ * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * - * last change: $Author: ka $ $Date: 2001-09-05 12:04:23 $ + * last change: $Author: ka $ $Date: 2001-09-28 13:59:43 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -108,7 +108,8 @@ TYPEINIT1( SdPresViewShell, SdDrawViewShell ); // ----------------------------------------------------------------------------- SdPresViewShell::SdPresViewShell( SfxViewFrame* pFrame, SfxViewShell *pOldShell ) : - SdDrawViewShell( pFrame, pOldShell ) + SdDrawViewShell( pFrame, pOldShell ), + mbShowStarted( sal_False ) { if( pDocSh && pDocSh->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED ) maOldVisArea = pDocSh->GetVisArea( ASPECT_CONTENT ); @@ -117,7 +118,8 @@ SdPresViewShell::SdPresViewShell( SfxViewFrame* pFrame, SfxViewShell *pOldShell // ----------------------------------------------------------------------------- SdPresViewShell::SdPresViewShell( SfxViewFrame* pFrame, const SdDrawViewShell& rShell ) : - SdDrawViewShell( pFrame, rShell ) + SdDrawViewShell( pFrame, rShell ), + mbShowStarted( sal_False ) { if( pDocSh && pDocSh->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED ) maOldVisArea = pDocSh->GetVisArea( ASPECT_CONTENT ); @@ -148,6 +150,40 @@ SdPresViewShell::~SdPresViewShell() // ----------------------------------------------------------------------------- +void SdPresViewShell::Activate( BOOL bIsMDIActivate ) +{ + SfxViewShell::Activate( bIsMDIActivate ); + + if( bIsMDIActivate ) + { + SdView* pView = GetView(); + SfxBoolItem aItem( SID_NAVIGATOR_INIT, TRUE ); + + GetViewFrame()->GetDispatcher()->Execute( SID_NAVIGATOR_INIT, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD, &aItem, 0L ); + + if( pFuSlideShow && !pFuSlideShow->IsTerminated() ) + pFuSlideShow->Activate(); + + if( pFuActual ) + pFuActual->Activate(); + + if( pView ) + pView->ShowMarkHdl( NULL ); + } + + ReadFrameViewData( pFrameView ); + pDocSh->Connect( this ); + pDrView->UpdateSelectionClipboard( FALSE ); + + if( pFuSlideShow && !mbShowStarted ) + { + pFuSlideShow->StartShow(); + mbShowStarted = sal_True; + } +} + +// ----------------------------------------------------------------------------- + void SdPresViewShell::CreateFullScreenShow( SdViewShell* pOriginShell, SfxRequest& rReq ) { SFX_REQUEST_ARG( rReq, pAlwaysOnTop, SfxBoolItem, ATTR_PRESENT_ALWAYS_ON_TOP, FALSE ); @@ -170,6 +206,5 @@ void SdPresViewShell::CreateFullScreenShow( SdViewShell* pOriginShell, SfxReques pShell->GetViewFrame()->GetDispatcher()->Execute( SID_SHOWPOPUPS, SFX_CALLMODE_SYNCHRON, &aShowItem, &aId, 0L ); pShell->GetViewFrame()->Show(); pShell->pFuSlideShow = new FuSlideShow( pShell, pShell->pWindow, pShell->pDrView, pShell->pDoc, rReq ); - pShell->pFuSlideShow->StartShow(); - pShell->pFuSlideShow->Activate(); + pShell->GetActiveWindow()->GrabFocus(); } |