diff options
author | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-03-16 13:36:35 +0100 |
---|---|---|
committer | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-03-16 13:36:35 +0100 |
commit | c2297610c51057e3a8f4716ffc0b9a570c4876e8 (patch) | |
tree | 38ae59942d09e7f1567df6a2fc6d34adb061134f /sd/source/ui/inc | |
parent | 263bcb1a8f686afe66f4fe53b76929423fc6ce43 (diff) |
slidecopy: de/activate panels via the drawing framework
Instead of simply letting svtool's ToolPanelDeck decide on panel activation, requests are re-routed through
the view's ConfigurationController. So, clicking onto a tab just requests the activation of the respective
resource, which in turn - when the requested configuration becomes the active configuration - will activate
the ToolPanel.
Diffstat (limited to 'sd/source/ui/inc')
-rw-r--r-- | sd/source/ui/inc/TaskPaneViewShell.hxx | 15 | ||||
-rw-r--r-- | sd/source/ui/inc/taskpane/PanelId.hxx | 56 | ||||
-rw-r--r-- | sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx | 23 |
3 files changed, 66 insertions, 28 deletions
diff --git a/sd/source/ui/inc/TaskPaneViewShell.hxx b/sd/source/ui/inc/TaskPaneViewShell.hxx index a290291f7e7c..d116b23e2140 100644 --- a/sd/source/ui/inc/TaskPaneViewShell.hxx +++ b/sd/source/ui/inc/TaskPaneViewShell.hxx @@ -34,6 +34,7 @@ #include "ViewShell.hxx" #include "glob.hxx" #include "framework/FrameworkHelper.hxx" +#include "taskpane/PanelId.hxx" #include <vcl/button.hxx> #include <sfx2/shell.hxx> #include <sfx2/viewfac.hxx> @@ -68,20 +69,6 @@ public: TYPEINFO(); SFX_DECL_INTERFACE(SD_IF_SDTASKPANEVIEWSHELL) - /** List of top level panels that can be shown in the task pane. - */ - enum PanelId - { - PID__START = 0, - PID_UNKNOWN = PID__START, - PID_MASTER_PAGES, - PID_LAYOUT, - PID_TABLE_DESIGN, - PID_CUSTOM_ANIMATION, - PID_SLIDE_TRANSITION, - PID__END = PID_SLIDE_TRANSITION - }; - TaskPaneViewShell ( SfxViewFrame* pFrame, ViewShellBase& rViewShellBase, diff --git a/sd/source/ui/inc/taskpane/PanelId.hxx b/sd/source/ui/inc/taskpane/PanelId.hxx new file mode 100644 index 000000000000..dbd618118ecf --- /dev/null +++ b/sd/source/ui/inc/taskpane/PanelId.hxx @@ -0,0 +1,56 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef SD_UI_TASKPANE_PANELID_HXX +#define SD_UI_TASKPANE_PANELID_HXX + +//...................................................................................................................... +namespace sd { namespace toolpanel +{ +//...................................................................................................................... + + //================================================================================================================== + //= PanelId + //================================================================================================================== + /** List of top level panels that can be shown in the task pane. + */ + enum PanelId + { + PID__START = 0, + PID_UNKNOWN = PID__START, + PID_MASTER_PAGES, + PID_LAYOUT, + PID_TABLE_DESIGN, + PID_CUSTOM_ANIMATION, + PID_SLIDE_TRANSITION, + PID__END = PID_SLIDE_TRANSITION + }; + +//...................................................................................................................... +} } // namespace sd::toolpanel +//...................................................................................................................... + +#endif // SD_UI_TASKPANE_PANELID_HXX diff --git a/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx b/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx index ab687b55de47..a4eb499076e6 100644 --- a/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx +++ b/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx @@ -33,6 +33,7 @@ #include "ViewShell.hxx" #include "glob.hxx" +#include "taskpane/PanelId.hxx" #include "framework/FrameworkHelper.hxx" #include <vcl/button.hxx> #include <sfx2/shell.hxx> @@ -70,20 +71,6 @@ public: TYPEINFO(); SFX_DECL_INTERFACE(SD_IF_SDTOOLPANELSHELL) - /** List of top level panels that can be shown in the task pane. - */ - enum PanelId - { - PID__START = 0, - PID_UNKNOWN = PID__START, - PID_MASTER_PAGES, - PID_LAYOUT, - PID_TABLE_DESIGN, - PID_CUSTOM_ANIMATION, - PID_SLIDE_TRANSITION, - PID__END = PID_SLIDE_TRANSITION - }; - ToolPanelViewShell ( SfxViewFrame* pFrame, ViewShellBase& rViewShellBase, @@ -112,6 +99,14 @@ public: TaskPaneShellManager& GetSubShellManager (void) const; + /** activates the given panel, bypassing the configuration controller, deactivates the previously active one. + */ + void ActivatePanel( const PanelId i_ePanelId ); + + /** deactivates the given panel, bypassing the configuration controller + */ + void DeactivatePanel( const PanelId i_ePanelId ); + /** Called when a mouse button has been pressed but not yet released, this handler is used to show the popup menu of the title bar. |