[Libreoffice-commits] core.git: Branch 'feature/sidebaropt' - officecfg/registry sd/source sd/util

Michael Meeks michael.meeks at suse.com
Fri May 17 05:58:31 PDT 2013


 officecfg/registry/data/org/openoffice/Office/Impress.xcu               |   12 ++
 officecfg/registry/data/org/openoffice/Office/UI/Factories.xcu          |   14 ++
 officecfg/registry/data/org/openoffice/Office/UI/ImpressWindowState.xcu |   55 ++++++++++
 sd/source/ui/framework/tools/FrameworkHelper.cxx                        |    4 
 sd/source/ui/unoidl/facreg.cxx                                          |   38 ++++++
 sd/source/ui/view/ToolBarManager.cxx                                    |    1 
 sd/source/ui/view/ViewShellBase.cxx                                     |   13 ++
 sd/source/ui/view/ViewShellImplementation.cxx                           |    2 
 sd/util/sd.component                                                    |    3 
 9 files changed, 139 insertions(+), 3 deletions(-)

New commits:
commit e93474c151eae2970d9c6e8801c3e3a3455da539
Author: Michael Meeks <michael.meeks at suse.com>
Date:   Fri May 17 13:48:27 2013 +0100

    tentatively restore more UNO / task-pane goo ...

diff --git a/officecfg/registry/data/org/openoffice/Office/Impress.xcu b/officecfg/registry/data/org/openoffice/Office/Impress.xcu
index 2310cc2..924d414 100644
--- a/officecfg/registry/data/org/openoffice/Office/Impress.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/Impress.xcu
@@ -82,6 +82,11 @@
                 <value>private:resource/pane/LeftDrawPane</value>
               </prop>
             </node>
+            <node oor:name="R3" oor:op="replace">
+              <prop oor:name="URL">
+                <value>private:resource/pane/RightPane</value>
+              </prop>
+            </node>
           </node>
         </node>
         <node oor:name="F1" oor:op="replace">
@@ -121,6 +126,11 @@
             </node>
             <node oor:name="R6" oor:op="replace">
               <prop oor:name="URL">
+                <value>private:resource/view/TaskPane</value>
+              </prop>
+            </node>
+            <node oor:name="R7" oor:op="replace">
+              <prop oor:name="URL">
                 <value>private:resource/view/PresentationView</value>
               </prop>
             </node>
@@ -140,7 +150,7 @@
         </node>
         <node oor:name="F3" oor:op="replace">
           <prop oor:name="ServiceName">
-            <value>com.sun.star.comp.Draw.framework.TaskPanelFactory</value>
+            <value>com.sun.star.drawing.framework.TaskPanelFactory</value> <!-- MMeeks -->
           </prop>
           <node oor:name="ResourceList">
             <node oor:name="R0a" oor:op="replace">
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/Factories.xcu b/officecfg/registry/data/org/openoffice/Office/UI/Factories.xcu
index 15c0a04..61b2f8d 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/Factories.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/Factories.xcu
@@ -76,6 +76,20 @@
           <value>com.sun.star.comp.framework.StatusBarFactory</value>
         </prop>
       </node>
+      <node oor:name="org.openoffice.Office.Impress.ImpressToolPanelFactory" oor:op="replace">
+        <prop oor:name="Type">
+          <value>toolpanel</value>
+        </prop>
+        <prop oor:name="Name">
+          <value>DrawingFramework</value>
+        </prop>
+        <prop oor:name="Module">
+          <value>com.sun.star.presentation.PresentationDocument</value>
+        </prop>
+        <prop oor:name="FactoryImplementation">
+          <value>com.sun.star.drawing.DefaultToolPanelFactory</value>
+        </prop>
+      </node>
       <node oor:name="SvxPanelFactory" oor:op="replace">
         <prop oor:name="Type">
           <value>toolpanel</value>
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/ImpressWindowState.xcu b/officecfg/registry/data/org/openoffice/Office/UI/ImpressWindowState.xcu
index c72079b..5aa630a 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/ImpressWindowState.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/ImpressWindowState.xcu
@@ -825,6 +825,61 @@
           <value>true</value>
         </prop>
       </node>
+      <node oor:name="private:resource/toolpanel/DrawingFramework/MasterPages" oor:op="replace">
+        <prop oor:name="Visible" oor:type="xs:boolean">
+          <value>false</value>
+        </prop>
+        <prop oor:name="UIName" oor:type="xs:string">
+          <value xml:lang="en-US">Master Pages</value>
+        </prop>
+        <prop oor:name="ImageURL" oor:type="xs:string">
+          <value>private:commandimage/PresentationLayout</value>
+        </prop>
+      </node>
+      <node oor:name="private:resource/toolpanel/DrawingFramework/Layouts" oor:op="replace">
+        <prop oor:name="Visible" oor:type="xs:boolean">
+          <value>false</value>
+        </prop>
+        <prop oor:name="UIName" oor:type="xs:string">
+          <value xml:lang="en-US">Layouts</value>
+        </prop>
+        <prop oor:name="ImageURL" oor:type="xs:string">
+          <value>private:commandimage/ModifyPage</value>
+        </prop>
+      </node>
+      <node oor:name="private:resource/toolpanel/DrawingFramework/TableDesign" oor:op="replace">
+        <prop oor:name="Visible" oor:type="xs:boolean">
+          <value>false</value>
+        </prop>
+        <prop oor:name="UIName" oor:type="xs:string">
+          <value xml:lang="en-US">Table Design</value>
+        </prop>
+        <prop oor:name="ImageURL" oor:type="xs:string">
+          <value>private:commandimage/InsertTable</value>
+        </prop>
+      </node>
+      <node oor:name="private:resource/toolpanel/DrawingFramework/CustomAnimations" oor:op="replace">
+        <prop oor:name="Visible" oor:type="xs:boolean">
+          <value>false</value>
+        </prop>
+        <prop oor:name="UIName" oor:type="xs:string">
+          <value xml:lang="en-US">Custom Animation</value>
+        </prop>
+        <prop oor:name="ImageURL" oor:type="xs:string">
+          <value>private:commandimage/CustomAnimation</value>
+        </prop>
+      </node>
+      <node oor:name="private:resource/toolpanel/DrawingFramework/SlideTransitions" oor:op="replace">
+        <prop oor:name="Visible" oor:type="xs:boolean">
+          <value>false</value>
+        </prop>
+        <prop oor:name="UIName" oor:type="xs:string">
+          <value xml:lang="en-US">Slide Transition</value>
+        </prop>
+        <prop oor:name="ImageURL" oor:type="xs:string">
+          <value>private:commandimage/RehearseTimings</value>
+        </prop>
+      </node>
       <node oor:name="private:resource/toolbar/optimizetablebar" oor:op="replace">
         <prop oor:name="Docked" oor:type="xs:boolean">
           <value>false</value>
diff --git a/sd/source/ui/framework/tools/FrameworkHelper.cxx b/sd/source/ui/framework/tools/FrameworkHelper.cxx
index ab98a7a..1f91f17 100644
--- a/sd/source/ui/framework/tools/FrameworkHelper.cxx
+++ b/sd/source/ui/framework/tools/FrameworkHelper.cxx
@@ -196,12 +196,14 @@ const OUString FrameworkHelper::msViewTabBarURL( msToolBarURLPrefix + "ViewTabBa
 
 
 // Task panel URLs.
-// FIXME: MMeeks - this set of urls changed:
 const OUString FrameworkHelper::msTaskPanelURLPrefix( "private:resource/toolpanel/" );
 const OUString FrameworkHelper::msMasterPagesTaskPanelURL( msTaskPanelURLPrefix + "MasterPages");
+
+// these three appear to be unused ...
 const OUString FrameworkHelper::msAllMasterPagesTaskPanelURL( msTaskPanelURLPrefix + "AllMasterPages" );
 const OUString FrameworkHelper::msRecentMasterPagesTaskPanelURL( msTaskPanelURLPrefix + "RecentMasterPages" );
 const OUString FrameworkHelper::msUsedMasterPagesTaskPanelURL( msTaskPanelURLPrefix + "UsedMasterPages" );
+
 const OUString FrameworkHelper::msLayoutTaskPanelURL( msTaskPanelURLPrefix + "Layouts" );
 const OUString FrameworkHelper::msTableDesignPanelURL( msTaskPanelURLPrefix + "TableDesign" );
 const OUString FrameworkHelper::msCustomAnimationTaskPanelURL( msTaskPanelURLPrefix + "CustomAnimations" );
diff --git a/sd/source/ui/unoidl/facreg.cxx b/sd/source/ui/unoidl/facreg.cxx
index df50159..c1445b5 100644
--- a/sd/source/ui/unoidl/facreg.cxx
+++ b/sd/source/ui/unoidl/facreg.cxx
@@ -113,6 +113,13 @@ extern OUString BasicViewFactory_getImplementationName(void) throw (uno::Runtime
 extern uno::Sequence<OUString> SAL_CALL BasicViewFactory_getSupportedServiceNames (void)
     throw (uno::RuntimeException);
 
+extern uno::Reference<uno::XInterface> SAL_CALL TaskPanelFactory_createInstance(
+    const uno::Reference<uno::XComponentContext>& rxContext)
+    throw(uno::Exception);
+extern OUString TaskPanelFactory_getImplementationName(void) throw (uno::RuntimeException);
+extern uno::Sequence<OUString> SAL_CALL TaskPanelFactory_getSupportedServiceNames (void)
+    throw (uno::RuntimeException);
+
 extern uno::Reference<uno::XInterface> SAL_CALL ResourceId_createInstance(
     const uno::Reference<uno::XComponentContext>& rxContext)
     throw(uno::Exception);
@@ -140,6 +147,16 @@ extern uno::Sequence<OUString> SAL_CALL PanelFactory_getSupportedServiceNames (v
 
 } }
 
+namespace sd { namespace toolpanel {
+extern uno::Reference<uno::XInterface> SAL_CALL ToolPanelFactory_createInstance(
+     const uno::Reference<uno::XComponentContext>& rxContext)
+     throw(uno::Exception);
+extern OUString ToolPanelFactory_getImplementationName(void) throw (uno::RuntimeException);
+extern uno::Sequence<OUString> SAL_CALL ToolPanelFactory_getSupportedServiceNames (void)
+    throw (uno::RuntimeException);
+
+} }
+
 namespace sd { namespace presenter {
 extern uno::Reference<uno::XInterface> SAL_CALL SlideRenderer_createInstance(
     const uno::Reference<uno::XComponentContext>& rxContext)
@@ -198,6 +215,7 @@ using namespace ::sd::framework;
 using namespace ::sd::presenter;
 using namespace ::sd::slidesorter;
 using namespace ::sd::sidebar;
+using namespace ::sd::toolpanel;
 
 
 
@@ -220,6 +238,8 @@ enum FactoryId
     BasicPaneFactoryFactoryId,
     BasicToolBarFactoryFactoryId,
     BasicViewFactoryFactoryId,
+    TaskPanelFactoryFactoryId,
+    ToolPanelFactoryFactoryId,
     PanelFactoryFactoryId,
     ResourceIdFactoryId,
     PresentationFactoryProviderFactoryId,
@@ -253,7 +273,9 @@ static ::boost::shared_ptr<FactoryMap> spFactoryMap;
         (*spFactoryMap)[BasicPaneFactory_getImplementationName()] = BasicPaneFactoryFactoryId;
         (*spFactoryMap)[BasicToolBarFactory_getImplementationName()] = BasicToolBarFactoryFactoryId;
         (*spFactoryMap)[BasicViewFactory_getImplementationName()] = BasicViewFactoryFactoryId;
-        (*spFactoryMap)[sidebar::PanelFactory_getImplementationName()] = PanelFactoryFactoryId;
+        (*spFactoryMap)[TaskPanelFactory_getImplementationName()] = TaskPanelFactoryFactoryId;
+        (*spFactoryMap)[ToolPanelFactory_getImplementationName()] = ToolPanelFactoryFactoryId;
+        (*spFactoryMap)[PanelFactory_getImplementationName()] = PanelFactoryFactoryId;
         (*spFactoryMap)[ResourceId_getImplementationName()] = ResourceIdFactoryId;
         (*spFactoryMap)[PresentationFactoryProvider_getImplementationName()] = PresentationFactoryProviderFactoryId;
         (*spFactoryMap)[SlideRenderer_getImplementationName()] = SlideRendererFactoryId;
@@ -376,6 +398,20 @@ SAL_DLLPUBLIC_EXPORT void * SAL_CALL sd_component_getFactory(
                         sd::framework::BasicViewFactory_getSupportedServiceNames());
                     break;
 
+                case TaskPanelFactoryFactoryId:
+                    xComponentFactory = ::cppu::createSingleComponentFactory(
+                        sd::framework::TaskPanelFactory_createInstance,
+                        sd::framework::TaskPanelFactory_getImplementationName(),
+                        sd::framework::TaskPanelFactory_getSupportedServiceNames());
+                    break;
+
+                case ToolPanelFactoryFactoryId:
+                     xComponentFactory = ::cppu::createSingleComponentFactory(
+                        sd::toolpanel::ToolPanelFactory_createInstance,
+                        sd::toolpanel::ToolPanelFactory_getImplementationName(),
+                        sd::toolpanel::ToolPanelFactory_getSupportedServiceNames());
+                     break;
+
                 case PanelFactoryFactoryId:
                     xComponentFactory = ::cppu::createSingleComponentFactory(
                         sd::sidebar::PanelFactory_createInstance,
diff --git a/sd/source/ui/view/ToolBarManager.cxx b/sd/source/ui/view/ToolBarManager.cxx
index ca0ec6b..03db02e 100644
--- a/sd/source/ui/view/ToolBarManager.cxx
+++ b/sd/source/ui/view/ToolBarManager.cxx
@@ -1199,6 +1199,7 @@ void ToolBarRules::MainViewShellChanged (ViewShell::ShellType nShellType)
 
         case ViewShell::ST_NONE:
         case ViewShell::ST_PRESENTATION:
+        case ViewShell::ST_TASK_PANE:
         case ViewShell::ST_SIDEBAR:
         default:
             break;
diff --git a/sd/source/ui/view/ViewShellBase.cxx b/sd/source/ui/view/ViewShellBase.cxx
index 3348c19..91091c4 100644
--- a/sd/source/ui/view/ViewShellBase.cxx
+++ b/sd/source/ui/view/ViewShellBase.cxx
@@ -54,6 +54,7 @@
 #include "PresentationViewShell.hxx"
 #include "FormShellManager.hxx"
 #include "ToolBarManager.hxx"
+#include "taskpane/PanelId.hxx"
 #include "SidebarPanelId.hxx"
 #include "Window.hxx"
 #include "framework/ConfigurationController.hxx"
@@ -697,6 +698,13 @@ void ViewShellBase::Execute (SfxRequest& rRequest)
                 framework::FrameworkHelper::msSlideSorterURL);
             break;
 
+        case SID_TASKPANE:
+            mpImpl->SetPaneVisibility(
+                rRequest,
+                framework::FrameworkHelper::msRightPaneURL,
+                framework::FrameworkHelper::msTaskPaneURL);
+            break;
+
         case SID_NORMAL_MULTI_PANE_GUI:
         case SID_SLIDE_SORTER_MULTI_PANE_GUI:
         case SID_DRAWINGMODE:
@@ -1387,6 +1395,11 @@ void ViewShellBase::Implementation::GetSlotState (SfxItemSet& rSet)
                             xContext, FrameworkHelper::msLeftDrawPaneURL);
                         break;
 
+                    case SID_TASKPANE:
+                        xResourceId = ResourceId::create(
+                            xContext, FrameworkHelper::msRightPaneURL);
+                        break;
+
                     case SID_NORMAL_MULTI_PANE_GUI:
                         xResourceId = ResourceId::createWithAnchorURL(
                             xContext,
diff --git a/sd/source/ui/view/ViewShellImplementation.cxx b/sd/source/ui/view/ViewShellImplementation.cxx
index 84c3181..07048c0 100644
--- a/sd/source/ui/view/ViewShellImplementation.cxx
+++ b/sd/source/ui/view/ViewShellImplementation.cxx
@@ -40,6 +40,7 @@
 #include "FrameView.hxx"
 #include "DrawViewShell.hxx"
 #include "ViewShellHint.hxx"
+#include "taskpane/PanelId.hxx"
 #include "SidebarPanelId.hxx"
 #include "framework/FrameworkHelper.hxx"
 
@@ -330,6 +331,7 @@ sal_uInt16 ViewShell::Implementation::GetViewId (void)
         // Since we have to return a view id for every possible shell type
         // and there is not (yet) a proper ViewShellBase sub class for the
         // remaining types we chose the Impress factory as a fall back.
+        case ViewShell::ST_TASK_PANE:
         case ViewShell::ST_SIDEBAR:
         case ViewShell::ST_NONE:
         default:
diff --git a/sd/util/sd.component b/sd/util/sd.component
index a588165..ff6d79c 100644
--- a/sd/util/sd.component
+++ b/sd/util/sd.component
@@ -63,6 +63,9 @@
   <implementation name="com.sun.star.comp.Draw.framework.ResourceId">
     <service name="com.sun.star.drawing.framework.ResourceId"/>
   </implementation>
+  <implementation name="com.sun.star.comp.Draw.framework.TaskPanelFactory">
+    <service name="com.sun.star.drawing.framework.TaskPanelFactory"/>
+  </implementation>
   <implementation name="org.openoffice.comp.Draw.framework.PanelFactory">
     <service name="com.sun.star.drawing.framework.PanelFactory"/>
   </implementation>


More information about the Libreoffice-commits mailing list