rpms/openoffice.org/devel openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch, NONE, 1.1 openoffice.org.spec, 1.1341, 1.1342
Jan Navrátil (jnavrati)
fedora-extras-commits at redhat.com
Wed Nov 21 14:44:45 UTC 2007
Author: jnavrati
Update of /cvs/pkgs/rpms/openoffice.org/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv14627
Modified Files:
openoffice.org.spec
Added Files:
openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch
Log Message:
added openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch
openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch:
--- NEW FILE openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch ---
Index: sd/inc/app.hrc
===================================================================
RCS file: /cvs/graphics/sd/inc/app.hrc,v
retrieving revision 1.24
diff -u -r1.24 app.hrc
--- openoffice.org.orig/sd/inc/app.hrc 6 Jul 2007 13:09:31 -0000 1.24
+++ openoffice.org/sd/inc/app.hrc 23 Oct 2007 09:21:00 -0000
@@ -462,6 +462,8 @@
#define SID_DISPLAY_MASTER_BACKGROUND (SID_SD_START+436)
#define SID_DISPLAY_MASTER_OBJECTS (SID_SD_START+437)
#define SID_INSERTPAGE_LAYOUT_MENU (SID_SD_START+438)
+// FIXME get an official SID
+#define SID_SELECT_BACKGROUND (SID_SD_START+450)
// Add companion for the SID_HIDE_SLIDE (that is defined in svx)
#define SID_SHOW_SLIDE (SID_SD_START+440)
Index: sd/sdi/_drvwsh.sdi
===================================================================
RCS file: /cvs/graphics/sd/sdi/_drvwsh.sdi,v
retrieving revision 1.39
diff -u -r1.39 _drvwsh.sdi
--- openoffice.org.orig/sd/sdi/_drvwsh.sdi 19 Dec 2006 17:29:45 -0000 1.39
+++ openoffice.org/sd/sdi/_drvwsh.sdi 23 Oct 2007 09:21:01 -0000
@@ -2463,6 +2463,11 @@
ExecMethod = FuSupport ;
StateMethod = GetMenuState ;
]
+ SID_SELECT_BACKGROUND
+ [
+ ExecMethod = FuTemporary ;
+ StateMethod = GetMenuState ;
+ ]
SID_DISPLAY_MASTER_BACKGROUND
[
ExecMethod = FuTemporary ;
Index: sd/sdi/sdraw.sdi
===================================================================
RCS file: /cvs/graphics/sd/sdi/sdraw.sdi,v
retrieving revision 1.32
diff -u -r1.32 sdraw.sdi
--- openoffice.org.orig/sd/sdi/sdraw.sdi 6 Jul 2007 13:09:58 -0000 1.32
+++ openoffice.org/sd/sdi/sdraw.sdi 23 Oct 2007 09:21:01 -0000
@@ -6783,6 +6783,29 @@
ToolBoxConfig = TRUE,
GroupId = GID_FORMAT;
]
+SfxVoidItem SelectBackground SID_SELECT_BACKGROUND
+()
+[
+ /* flags: */
+ AutoUpdate = FALSE,
+ Cachable = Cachable,
+ FastCall = FALSE,
+ HasCoreId = FALSE,
+ HasDialog = TRUE,
+ ReadOnlyDoc = FALSE,
+ Toggle = FALSE,
+ Container = FALSE,
+ RecordAbsolute = FALSE,
+ RecordPerSet;
+ Synchron;
+
+ /* config: */
+ AccelConfig = FALSE,
+ MenuConfig = FALSE,
+ StatusBarConfig = FALSE,
+ ToolBoxConfig = FALSE,
+ GroupId = GID_OPTIONS;
+]
SfxBoolItem DisplayMasterBackground SID_DISPLAY_MASTER_BACKGROUND
[
/* flags: */
Index: sd/source/ui/app/menuids_tmpl.src
===================================================================
RCS file: /cvs/graphics/sd/source/ui/app/menuids_tmpl.src,v
retrieving revision 1.16
diff -u -r1.16 menuids_tmpl.src
--- openoffice.org.orig/sd/source/ui/app/menuids_tmpl.src 19 Apr 2007 12:20:20 -0000 1.16
+++ openoffice.org/sd/source/ui/app/menuids_tmpl.src 23 Oct 2007 09:21:02 -0000
@@ -160,6 +160,13 @@
HelpID = SID_INSERTPAGE ; \
Text [ en-US ] = "~New Page" ; \
};
+#define MN_SELECT_BACKGROUND \
+ MenuItem\
+ {\
+ Identifier = SID_SELECT_BACKGROUND ; \
+ HelpID = SID_SELECT_BACKGROUND ; \
+ Text [ en-US ] = "Select Background for Slide ..." ; \
+ };
#define MN_DISPLAY_MASTER_BACKGROUND \
MenuItem\
{\
@@ -210,6 +217,7 @@
MN_MODIFY_PAGE\
MN_RENAME_SLIDE\
SEPARATOR\
+ MN_SELECT_BACKGROUND\
MN_DISPLAY_MASTER_BACKGROUND\
MN_DISPLAY_MASTER_OBJECTS\
SEPARATOR\
Index: source/ui/func/fuinsert.cxx
===================================================================
RCS file: /cvs/graphics/sd/source/ui/func/fuinsert.cxx,v
retrieving revision 1.47
diff -u -r1.47 fuinsert.cxx
--- openoffice.org.orig/sd/source/ui/func/fuinsert.cxx 6 Sep 2007 13:55:56 -0000 1.47
+++ openoffice.org/sd/source/ui/func/fuinsert.cxx 30 Oct 2007 08:29:44 -0000
@@ -154,10 +154,23 @@
#include <vcl/svapp.hxx>
#endif
+#ifndef _SVX_XBTMPIT_HXX
+#include <svx/xbtmpit.hxx>
+#endif
+#ifndef _SVX_XSETITEM_HXX
+#include <svx/xsetit.hxx>
+#endif
+#ifndef _SFXITEMPOOL_HXX //autogen
+#include <svtools/itempool.hxx>
+#endif
+#include <svx/ulspitem.hxx>
+#include <svx/lrspitem.hxx>
+
using namespace com::sun::star;
namespace sd {
+TYPEINIT1( FuInsertBackground, FuPoor );
TYPEINIT1( FuInsertGraphic, FuPoor );
TYPEINIT1( FuInsertClipboard, FuPoor );
TYPEINIT1( FuInsertOLE, FuPoor );
@@ -165,6 +178,106 @@
/*************************************************************************
|*
+|* FuInsertBackground::Konstruktor
+|*
+\************************************************************************/
+
+FuInsertBackground::FuInsertBackground (
+ ViewShell* pViewSh,
+ ::sd::Window* pWin,
+ ::sd::View* pView,
+ SdDrawDocument* pDoc,
+ SfxRequest& rReq)
+ : FuPoor(pViewSh, pWin, pView, pDoc, rReq),
+ mpPage(0)
+{
+}
+
+FunctionReference FuInsertBackground::Create( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::View* pView, SdDrawDocument* pDoc, SfxRequest& rReq )
+{
+ FunctionReference xFunc( new FuInsertBackground( pViewSh, pWin, pView, pDoc, rReq ) );
+ xFunc->DoExecute(rReq);
+ return xFunc;
+}
+
+#ifdef WNT
+#pragma optimize ( "", off )
+#endif
+
+void FuInsertBackground::DoExecute( SfxRequest& )
+{
+ mpDrawViewShell = dynamic_cast<DrawViewShell*>(mpViewShell);
+ DBG_ASSERT( mpDrawViewShell, "sd::FuInsertiBackground::FuInsertBackground(), called without a current DrawViewShell!" );
+ if( mpDrawViewShell )
+ mpPage = mpDrawViewShell->getCurrentPage();
+
+//*************************************************************************
+
+ if( mpPage )
+ {
+ SvxOpenGraphicDialog aDlg(SdResId(STR_INSERTGRAPHIC));
+
+ if( aDlg.Execute() == GRFILTER_OK )
+ {
+ Graphic aGraphic;
+ int nError = aDlg.GetGraphic(aGraphic);
+ if( nError == GRFILTER_OK )
+ {
+
+ const SfxPoolItem* pPoolItem = NULL;
+
+ SfxItemSet aNewAttr(
+ mpDoc->GetPool(),
+ XATTR_FILL_FIRST, XATTR_FILL_LAST,
+ 0);
+
+ aNewAttr.Put( XFillStyleItem( XFILL_BITMAP ) );
+ aNewAttr.Put( XFillBitmapItem( String(), XOBitmap(aGraphic) ) );
+ aNewAttr.Put( XFillBmpStretchItem( TRUE ));
+ aNewAttr.Put( XFillBmpTileItem( FALSE ));
+
+ if( SFX_ITEM_SET == aNewAttr.GetItemState( mpDoc->GetPool().GetWhich( XATTR_FILLBITMAP ), TRUE, &pPoolItem ) )
+ {
+ INT32 nLeft = mpPage->GetLftBorder();
+ INT32 nRight = mpPage->GetRgtBorder();
+ INT32 nUpper = mpPage->GetUppBorder();
+ INT32 nLower = mpPage->GetLwrBorder();
+
+ // Only this page
+ SdrObject* pObj = mpPage->GetBackgroundObj();
+
+ if( !pObj )
+ {
+ pObj = new SdrRectObj();
+ mpPage->SetBackgroundObj( pObj );
+ }
+
+ Point aPos ( nLeft, nUpper );
+ Size aSize( mpPage->GetSize() );
+ aSize.Width() -= nLeft + nRight - 1;
+ aSize.Height() -= nUpper + nLower - 1;
+ Rectangle aRect( aPos, aSize );
+ pObj->SetLogicRect( aRect );
+ pObj->SetMergedItemSet(aNewAttr);
+
+ mpPage->ActionChanged();
+ mpDoc->SetChanged(TRUE);
+ }
+
+ mpDrawViewShell->UpdatePreview( mpPage );
+ }
+ else
+ {
+ SdGRFFilter::HandleGraphicFilterError( (USHORT)nError, GetGrfFilter()->GetLastError().nStreamError );
+ }
+ }
+ }
+
+//*************************************************************************
+
+}
+/*************************************************************************
+|*
|* FuInsertGraphic::Konstruktor
|*
\************************************************************************/
Index: sd/source/ui/inc/fuinsert.hxx
===================================================================
RCS file: /cvs/graphics/sd/source/ui/inc/fuinsert.hxx,v
retrieving revision 1.6
diff -u -r1.6 fuinsert.hxx
--- openoffice.org.orig/sd/source/ui/inc/fuinsert.hxx 14 Dec 2005 17:12:10 -0000 1.6
+++ openoffice.org/sd/source/ui/inc/fuinsert.hxx 23 Oct 2007 09:21:02 -0000
@@ -40,7 +40,37 @@
#include "fupoor.hxx"
#endif
+class SfxItemSet;
+class SdPage;
+
namespace sd {
+class DrawViewShell;
+
+/* TEMP *****************************************************************/
+
+class FuInsertBackground
+ : public FuPoor
+{
+public:
+ TYPEINFO();
+
+ static FunctionReference Create( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::View* pView, SdDrawDocument* pDoc, SfxRequest& rReq );
+ virtual void DoExecute( SfxRequest& rReq );
+
+private:
+
+ FuInsertBackground (
+ ViewShell* pViewSh,
+ ::sd::Window* pWin,
+ ::sd::View* pView,
+ SdDrawDocument* pDoc,
+ SfxRequest& rReq);
+
+ SdPage* mpPage;
+ DrawViewShell* mpDrawViewShell;
+};
+
+/************************************************************************/
class FuInsertGraphic
: public FuPoor
Index: sd/source/ui/view/drviews6.cxx
===================================================================
RCS file: /cvs/graphics/sd/source/ui/view/drviews6.cxx,v
retrieving revision 1.28
diff -u -r1.28 drviews6.cxx
--- openoffice.org.orig/sd/source/ui/view/drviews6.cxx 2 Aug 2007 18:23:49 -0000 1.28
+++ openoffice.org/sd/source/ui/view/drviews6.cxx 23 Oct 2007 09:21:02 -0000
@@ -77,6 +77,9 @@
#ifndef _SVX_COLRCTRL_HXX //autogen
#include <svx/colrctrl.hxx>
#endif
+#ifndef _SVX_OPENGRF_HXX
+#include <svx/opengrf.hxx>
+#endif
#ifndef _SVX_F3DCHILD_HXX //autogen
#include <svx/f3dchild.hxx>
@@ -129,6 +132,9 @@
#ifndef SD_FU_CUSTOM_SHOW_DLG_HXX
#include "fucushow.hxx"
#endif
+#ifndef SD_FU_INSERT_HXX
+#include "fuinsert.hxx"
+#endif
#ifndef SD_DRAW_VIEW_HXX
#include "drawview.hxx"
#endif
@@ -829,8 +835,15 @@
}
break;
- case SID_DISPLAY_MASTER_BACKGROUND:
- case SID_DISPLAY_MASTER_OBJECTS:
+ case SID_SELECT_BACKGROUND:
+ {
+ SetCurrentFunction( FuInsertBackground::Create( this, GetActiveWindow(), mpDrawView, GetDoc(), rReq ) );
+ Cancel();
+ rReq.Ignore ();
+ }
+ break;
+ case SID_DISPLAY_MASTER_BACKGROUND:
+ case SID_DISPLAY_MASTER_OBJECTS:
{
// Determine current page and toggle visibility of layers
// associated with master page background or master page shapes.
Index: openoffice.org.spec
===================================================================
RCS file: /cvs/pkgs/rpms/openoffice.org/devel/openoffice.org.spec,v
retrieving revision 1.1341
retrieving revision 1.1342
diff -u -r1.1341 -r1.1342
--- openoffice.org.spec 15 Nov 2007 08:00:43 -0000 1.1341
+++ openoffice.org.spec 21 Nov 2007 14:44:11 -0000 1.1342
@@ -1,6 +1,6 @@
%define oootag OOG680
%define ooomilestone 9
-%define rh_rpm_release 2
+%define rh_rpm_release 3
# undef to get english only and no-langpacks for a faster smoketest build
%define langpacks 1
@@ -150,6 +150,7 @@
Patch68: openoffice.org-2.3.0.ooo82966.svx.missing3d.patch
Patch69: openoffice.org-2.3.1.ooo81307.sw.word2.patch
Patch70: openoffice.org-2.3.0.ooo83591.vcl.checkboxes.patch
+Patch71: openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch
%define instdir %{_libdir}/openoffice.org
@@ -1099,6 +1100,7 @@
%patch68 -p1 -b .ooo82966.svx.missing3d.patch
%patch69 -p1 -b .ooo81307.sw.word2.patch
%patch70 -p1 -b .ooo83591.vcl.checkboxes.patch
+%patch71 -p1 -b .ooo82911.sd.insertbackground.patch
%if %{linkopt}
chmod a+x solenv/bin/mklinkscript.pl
@@ -2795,6 +2797,9 @@
%{instdir}/share/registry/modules/org/openoffice/Office/Scripting/Scripting-python.xcu
%changelog
+* Wed Nov 21 2007 Jan Navratil <jnavrati at redhat.com> - 1:2.3.1-9.3
+- Resolves: rhbz#247634 fix openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch
+
* Thu Nov 15 2007 Caolan McNamara <caolanm at redhat.com> - 1:2.3.1-9.2
- move from firefox to xulrunner
More information about the scm-commits
mailing list