rpms/openoffice.org/devel openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch, NONE, 1.1 openoffice.org.spec, 1.1419, 1.1420

Caolan McNamara (caolanm) fedora-extras-commits at redhat.com
Wed Feb 6 16:40:37 UTC 2008


Author: caolanm

Update of /cvs/pkgs/rpms/openoffice.org/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv17352

Modified Files:
	openoffice.org.spec 
Added Files:
	openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch 
Log Message:
add openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch for jrb

openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch:

--- NEW FILE openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch ---
diff -ru sd/inc/app.hrc sd/inc/app.hrc
--- openoffice.org.orig/sd/inc/app.hrc	2008-02-05 17:05:14.000000000 +0000
+++ openoffice.org/sd/inc/app.hrc	2008-02-05 20:29:11.000000000 +0000
@@ -469,6 +469,8 @@
 // Add companion for the SID_HIDE_SLIDE (that is defined in svx)
 #define SID_SHOW_SLIDE                      (SID_SD_START+440)
 
-#define SID_ADD_MOTION_PATH				(SID_SD_START+441)
+#define SID_ADD_MOTION_PATH                 (SID_SD_START+441)
+
+#define SID_TP_EDIT_MASTER                  (SID_SD_START+442)
 
 #endif
diff -ru sd/sdi/TaskPaneViewShell.sdi sd/sdi/TaskPaneViewShell.sdi
--- openoffice.org.orig/sd/sdi/TaskPaneViewShell.sdi	2008-02-05 17:05:16.000000000 +0000
+++ openoffice.org/sd/sdi/TaskPaneViewShell.sdi	2008-02-05 20:30:12.000000000 +0000
@@ -159,6 +159,31 @@
 	GroupId = GID_VIEW;
 ]
 
+SfxVoidItem TaskPaneEditMaster SID_TP_EDIT_MASTER
+[
+	/* flags: */
+	AutoUpdate = TRUE,
+	Cachable = Cachable,
+	FastCall = FALSE,
+	HasCoreId = FALSE,
+	HasDialog = FALSE,
+	ReadOnlyDoc = FALSE,
+	Toggle = FALSE,
+	Container = FALSE,
+	RecordAbsolute = FALSE,
+	RecordPerSet;
+	Synchron;
+
+	Readonly = FALSE,
+
+	/* config: */
+	AccelConfig = FALSE,
+	MenuConfig = FALSE,
+	StatusBarConfig = FALSE,
+	ToolBoxConfig = FALSE,
+	GroupId = GID_VIEW;
+]
+
 SfxVoidItem InsertPage SID_INSERTPAGE_LAYOUT_MENU
 [
 	/* flags: */  
@@ -212,6 +237,11 @@
 		ExecMethod = Execute ;
 		StateMethod = GetState ;
 	]
+    SID_TP_EDIT_MASTER
+	[
+		ExecMethod = Execute ;
+		StateMethod = GetState ;
+	]
 
     // The copy and paste slots are included here so that they later can be
     // disabled in order to remove them from context menus.
diff -ru sd/source/ui/app/popup.src sd/source/ui/app/popup.src
--- openoffice.org.orig/sd/source/ui/app/popup.src	2008-02-05 17:05:14.000000000 +0000
+++ openoffice.org/sd/source/ui/app/popup.src	2008-02-06 09:05:04.000000000 +0000
@@ -337,6 +337,12 @@
             HelpID = SID_TP_SHOW_SMALL_PREVIEW;
             Text[ en-US ] = "Show S~mall Preview";
         };
+        MenuItem
+        {
+            Identifier = SID_TP_EDIT_MASTER;
+            HelpID = SID_TP_EDIT_MASTER;
+            Text[ en-US ] = "~Edit Master...";
+        };
 	};
 };
 
diff -ru sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx	2008-02-06 14:01:07.000000000 +0000
@@ -44,6 +44,8 @@
 #include <tools/link.hxx>
 #include <set>
 
+#include "app.hrc"
+
 namespace {
 
 using namespace sd::toolpanel::controls;
@@ -202,4 +204,13 @@
 
 
 
+void AllMasterPagesSelector::GetState (SfxItemSet& rItemSet)
+{
+    MasterPagesSelector::GetState (rItemSet);
+    rItemSet.DisableItem (SID_TP_EDIT_MASTER);
+}
+
+
+
+
 } } } // end of namespace ::sd::toolpanel::controls
diff -ru sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx	2008-02-06 13:56:51.000000000 +0000
@@ -63,6 +63,7 @@
     */
     virtual void Fill (ItemList& rItemList);
 
+    virtual void GetState (SfxItemSet& rItemSet);
 protected:
     virtual void NotifyContainerChangeEvent (const MasterPageContainerChangeEvent& rEvent);
 
diff -ru sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx	2008-02-06 16:28:56.000000000 +0000
@@ -39,6 +39,7 @@
 #include "CurrentMasterPagesSelector.hxx"
 #include "PreviewValueSet.hxx"
 #include "ViewShellBase.hxx"
+#include "DrawViewShell.hxx"
 #include "drawdoc.hxx"
 #include "sdpage.hxx"
 #include "MasterPageContainer.hxx"
@@ -243,5 +244,12 @@
     return 0;
 }
 
+void CurrentMasterPagesSelector::GetState (SfxItemSet& rItemSet)
+{
+    MasterPagesSelector::GetState (rItemSet);
+    DrawViewShell* pDrawViewShell = dynamic_cast<DrawViewShell*>(mrBase.GetMainViewShell().get());
+    if (pDrawViewShell && pDrawViewShell->GetEditMode() == EM_MASTERPAGE)
+        rItemSet.DisableItem (SID_TP_EDIT_MASTER);
+}
 
 } } } // end of namespace ::sd::toolpanel::controls
diff -ru sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx	2008-02-06 14:20:20.000000000 +0000
@@ -72,6 +72,8 @@
     */
     virtual void Fill (ItemList& rItemList);
 
+    virtual void GetState (SfxItemSet& rItemSet);
+
 	using sd::toolpanel::controls::MasterPagesSelector::Fill;
 
 protected:
diff -ru sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx	2008-02-06 16:28:52.000000000 +0000
@@ -599,6 +597,21 @@
             break;
         }
 
+        case SID_TP_EDIT_MASTER:
+            using namespace ::sd::slidesorter;
+            using namespace ::sd::slidesorter::controller;
+            if (SlideSorterViewShell* pSlideSorter = SlideSorterViewShell::GetSlideSorter(mrBase))
+            {
+                USHORT nIndex = mpPageSet->GetSelectItemId();
+                SlideSorterController& rController = pSlideSorter->GetSlideSorterController();
+                rController.PrepareEditModeChange();
+                rController.ChangeEditMode ( EM_MASTERPAGE );
+                rController.FinishEditModeChange();
+                mpPageSet->SelectItem (nIndex);
+                rController.GetPageSelector().SetCurrentPage ( GetSelectedMasterPage() );
+            }
+            break;
+
         case SID_CUT:
         case SID_COPY:
         case SID_PASTE:
diff -ru sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx	2008-02-06 13:56:58.000000000 +0000
@@ -106,7 +106,7 @@
     virtual sal_Int32 GetMinimumWidth (void);
 
     void Execute (SfxRequest& rRequest);
-    void GetState (SfxItemSet& rItemSet);
+    virtual void GetState (SfxItemSet& rItemSet);
 
     /** Update the selection of previews according to whatever
         influences them appart from mouse and keyboard.  If, for
diff -ru sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx	2008-02-06 14:01:57.000000000 +0000
@@ -47,6 +47,8 @@
 #include <vcl/bitmap.hxx>
 #include <tools/color.hxx>
 
+#include "app.hrc"
+
 namespace sd { namespace toolpanel { namespace controls {
 
 
@@ -150,4 +152,16 @@
     }
 }
 
+
+
+
+void RecentMasterPagesSelector::GetState (SfxItemSet& rItemSet)
+{
+    MasterPagesSelector::GetState (rItemSet);
+    rItemSet.DisableItem (SID_TP_EDIT_MASTER);
+}
+
+
+
+
 } } } // end of namespace ::sd::toolpanel::controls
diff -ru sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx
--- openoffice.org.orig/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx	2008-02-05 17:05:15.000000000 +0000
+++ openoffice.org/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx	2008-02-06 13:57:15.000000000 +0000
@@ -56,6 +56,8 @@
 
     virtual void LateInit (void);
 
+    virtual void GetState (SfxItemSet& rItemSet);
+
 protected:
     DECL_LINK(MasterPageListListener, void*);
     virtual void Fill (ItemList& rItemList);


Index: openoffice.org.spec
===================================================================
RCS file: /cvs/pkgs/rpms/openoffice.org/devel/openoffice.org.spec,v
retrieving revision 1.1419
retrieving revision 1.1420
diff -u -r1.1419 -r1.1420
--- openoffice.org.spec	6 Feb 2008 13:44:01 -0000	1.1419
+++ openoffice.org.spec	6 Feb 2008 16:39:46 -0000	1.1420
@@ -138,6 +138,7 @@
 Patch64: workspace.cairotext01.patch
 Patch65: workspace.gcc430two.patch
 Patch66: openoffice.org-2.4.0.ooo85854.sw.graphicsaveas.patch
+Patch67: openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch
 
 %define instdir %{_libdir}/openoffice.org
 
@@ -1090,6 +1091,7 @@
 %patch64 -p1 -b .workspace.cairotext01.patch
 %patch65 -p1 -b .workspace.gcc430two.patch
 %patch66 -p1 -b .ooo85854.sw.graphicsaveas.patch
+%patch67 -p1 -b .ooo85921.sd.editmasterundermouse.patch
 
 %build
 echo build start time is `date`, diskspace: `df -h . | tail -n 1`
@@ -2863,6 +2865,7 @@
 - Resolves: rhbz#431606 require jre not java
 - Resolves: rhbz#431620/ooo#85909 depth mismatch for text
 - ooo#85914 work around trouble with deleting multiple notes
+- add openoffice.org-2.4.0.ooo85921.sd.editmasterundermouse.patch for jrb
 
 * Mon Feb 04 2008 Caolan McNamara <caolanm at redhat.com> - 1:2.4.0-6.1
 - next milestone




More information about the fedora-extras-commits mailing list