diff -uNr old/sd/source/ui/inc/ViewShellBase.hxx new/sd/source/ui/inc/ViewShellBase.hxx --- old/sd/source/ui/inc/ViewShellBase.hxx 2009-01-17 06:36:54.000000000 +0800 +++ new/sd/source/ui/inc/ViewShellBase.hxx 2009-02-11 09:12:02.000000000 +0800 @@ -88,7 +88,8 @@ SfxViewShell* pOldShell); virtual ~ViewShellBase (void); - + void SetIsSlidesortercopy(bool i_iscopy); + bool GetIsSlidesortercopy(void); /** This method is part of the object construction. It HAS to be called after the constructor has created a new object. */ @@ -271,7 +272,7 @@ ::boost::scoped_ptr mpImpl; DrawDocShell* mpDocShell; SdDrawDocument* mpDocument; - + bool iscopy; /** Determine from the properties of the document shell the initial type of the view shell in the center pane. We use this method to avoid starting with the wrong type. When ReadUserDataSequence() is called diff -uNr old/sd/source/ui/slidesorter/controller/SlsClipboard.cxx new/sd/source/ui/slidesorter/controller/SlsClipboard.cxx --- old/sd/source/ui/slidesorter/controller/SlsClipboard.cxx 2009-01-17 06:36:48.000000000 +0800 +++ new/sd/source/ui/slidesorter/controller/SlsClipboard.cxx 2009-02-11 09:23:38.000000000 +0800 @@ -136,6 +136,8 @@ xFunc->DoCopy(); else DoCopy(); + ViewShellBase& pMainViewShellBase = mrController.GetSlideSorter().GetViewShell()->GetViewShellBase(); + pMainViewShellBase.SetIsSlidesortercopy(true); } rRequest.Done(); break; diff -uNr old/sd/source/ui/view/ViewClipboard.cxx new/sd/source/ui/view/ViewClipboard.cxx --- old/sd/source/ui/view/ViewClipboard.cxx 2009-01-17 06:36:54.000000000 +0800 +++ new/sd/source/ui/view/ViewClipboard.cxx 2009-02-12 10:49:22.000000000 +0800 @@ -72,8 +72,10 @@ SdPage* pMasterPage = GetFirstMasterPage (rTransferable); if (pMasterPage != NULL) AssignMasterPage (rTransferable, pMasterPage); - else - InsertSlides (rTransferable, DetermineInsertPosition (rTransferable)); + else if (mrView.GetViewShell()->GetShellType()!=ViewShell::ST_HANDOUT) + { + InsertSlides (rTransferable, DetermineInsertPosition (rTransferable)); + } } diff -uNr old/sd/source/ui/view/ViewShellBase.cxx new/sd/source/ui/view/ViewShellBase.cxx --- old/sd/source/ui/view/ViewShellBase.cxx 2009-01-17 06:36:54.000000000 +0800 +++ new/sd/source/ui/view/ViewShellBase.cxx 2009-02-11 09:12:00.000000000 +0800 @@ -281,6 +281,7 @@ maMutex(), mpImpl(), mpDocShell (NULL), + iscopy(false), mpDocument (NULL) { mpImpl.reset(new Implementation(*this)); @@ -338,7 +339,14 @@ SetWindow(NULL); } - +void ViewShellBase::SetIsSlidesortercopy(bool i_iscopy) +{ + iscopy=i_iscopy; +} +bool ViewShellBase::GetIsSlidesortercopy(void) +{ + return iscopy; +} void ViewShellBase::LateInit (const ::rtl::OUString& rsDefaultView) diff -uNr old/sd/source/ui/view/drviews7.cxx new/sd/source/ui/view/drviews7.cxx --- old/sd/source/ui/view/drviews7.cxx 2009-02-04 11:13:46.000000000 +0800 +++ new/sd/source/ui/view/drviews7.cxx 2009-02-12 10:51:34.000000000 +0800 @@ -648,6 +648,17 @@ { rSet.DisableItem(SID_PRESENTATION_LAYOUT); rSet.DisableItem(SID_SELECT_BACKGROUND); + ViewShell* pMainViewShell = GetViewShellBase().GetMainViewShell().get(); + ViewShellBase& pMainViewShellBase=GetViewShellBase(); + bool acopy=false; + if (pMainViewShell != NULL) + { + acopy=pMainViewShellBase.GetIsSlidesortercopy(); + } + if(acopy) + { + rSet.DisableItem(SID_PASTE); + } } if (mePageKind == PK_NOTES) diff -uNr old/sd/source/ui/view/drviewse.cxx new/sd/source/ui/view/drviewse.cxx --- old/sd/source/ui/view/drviewse.cxx 2009-01-17 06:36:54.000000000 +0800 +++ new/sd/source/ui/view/drviewse.cxx 2009-02-12 10:52:56.000000000 +0800 @@ -761,6 +761,12 @@ case SID_COPY: { + ViewShell* pMainViewShell = GetViewShellBase().GetMainViewShell().get(); + ViewShellBase& pMainViewShellBase=GetViewShellBase(); + if(pMainViewShell->GetShellType()==ViewShell::ST_HANDOUT) + { + pMainViewShellBase.SetIsSlidesortercopy(false); + } if ( mpDrawView->IsPresObjSelected(FALSE, TRUE, FALSE, TRUE) ) { ::sd::Window* pWindow = GetActiveWindow(); @@ -783,15 +789,15 @@ case SID_PASTE: { - WaitObject aWait( (Window*)GetActiveWindow() ); - - if(HasCurrentFunction()) - { - GetCurrentFunction()->DoPaste(); - } - else if(mpDrawView) - { - mpDrawView->DoPaste(); + WaitObject aWait( (Window*)GetActiveWindow() ); + + if(HasCurrentFunction()) + { + GetCurrentFunction()->DoPaste(); + } + else if(mpDrawView) + { + mpDrawView->DoPaste(); } rReq.Ignore ();