1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
28 // MARKER(update_precomp.py): autogen include statement, do not remove
29 #include "precompiled_sd.hxx"
31 #include "PaneDockingWindow.hxx"
33 #include "ViewShellBase.hxx"
34 #include "sdresid.hxx"
35 #include "res_bmp.hrc"
36 #include <sfx2/dispatch.hxx>
37 #include <vcl/toolbox.hxx>
38 #include <vcl/taskpanelist.hxx>
39 #include "framework/FrameworkHelper.hxx"
41 using namespace ::com::sun::star
;
42 using namespace ::com::sun::star::uno
;
43 using namespace ::com::sun::star::drawing::framework
;
44 using ::sfx2::TitledDockingWindow
;
48 PaneDockingWindow::PaneDockingWindow(
49 SfxBindings
*_pBindings
, SfxChildWindow
*pChildWindow
, ::Window
* pParent
,
50 const ResId
& rResId
, const ::rtl::OUString
& rsTitle
)
51 :TitledDockingWindow( _pBindings
, pChildWindow
, pParent
, rResId
)
56 PaneDockingWindow::~PaneDockingWindow (void)
60 void PaneDockingWindow::StateChanged( StateChangedType nType
)
64 case STATE_CHANGE_VISIBLE
:
65 // The visibility of the docking window has changed. Tell the
66 // ConfigurationController so that it can activate or deactivate
67 // a/the view for the pane.
68 // Without this the side panes remain empty after closing an
69 // in-place slide show.
70 ViewShellBase
* pBase
= ViewShellBase::GetViewShellBase(
71 GetBindings().GetDispatcher()->GetFrame());
74 framework::FrameworkHelper::Instance(*pBase
)->UpdateConfiguration();
78 SfxDockingWindow::StateChanged (nType
);
81 } // end of namespace ::sd