[ooo-build-commit] .: 2 commits - patches/dev300 patches/test
Thorsten Behrens
thorsten at kemper.freedesktop.org
Mon Jan 25 03:30:43 PST 2010
patches/dev300/apply | 1
patches/dev300/framework-menubar-fix.diff | 29
patches/test/opengl-canvas.diff | 1283 +++++++++++++-----------------
3 files changed, 587 insertions(+), 726 deletions(-)
New commits:
commit fdd0eaab9388c42796e39d14d7fc84611d4c7d8d
Author: Thorsten Behrens <tbehrens at novell.com>
Date: Thu Jan 21 14:50:29 2010 +0100
Fix crash when extensions have Addons.xcu with nonstd merge points
* patches/dev300/apply: added the patch
* patches/dev300/framework-menubar-fix.diff: catch the case that
merge path is empty
diff --git a/patches/dev300/apply b/patches/dev300/apply
index 97660de..b290c29 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3484,3 +3484,4 @@ evaluation-row-limit.diff
[ Fixes ]
# TODO: split up into the original patches were this belongs
valgrind-fixes.diff, thorsten
+framework-menubar-fix.diff, thorsten
diff --git a/patches/dev300/framework-menubar-fix.diff b/patches/dev300/framework-menubar-fix.diff
new file mode 100644
index 0000000..6d10051
--- /dev/null
+++ b/patches/dev300/framework-menubar-fix.diff
@@ -0,0 +1,29 @@
+Fix crash when extensions have Addons.xcu with nonstd merge points
+
+diff --git a/framework/source/uielement/menubarmerger.cxx b/framework/source/uielement/menubarmerger.cxx
+index 9e497b6..7067f96 100644
+--- framework/source/uielement/menubarmerger.cxx
++++ framework/source/uielement/menubarmerger.cxx
+@@ -104,6 +104,14 @@ ReferencePathInfo MenuBarMerger::FindReferencePath(
+ {
+ sal_uInt32 i( 0 );
+ const sal_uInt32 nCount( rReferencePath.size() );
++
++ ReferencePathInfo aResult;
++ if ( !nCount )
++ {
++ aResult.eResult = RP_MENUITEM_NOT_FOUND;
++ return aResult;
++ }
++
+ Menu* pCurrMenu( pMenu );
+ RPResultInfo eResult( RP_OK );
+
+@@ -145,7 +153,6 @@ ReferencePathInfo MenuBarMerger::FindReferencePath(
+ }
+ while (( pCurrMenu != 0 ) && ( i < nCount ) && ( eResult == RP_OK ));
+
+- ReferencePathInfo aResult;
+ aResult.pPopupMenu = pCurrMenu;
+ aResult.nPos = nPos;
+ aResult.nLevel = nLevel;
commit d12940e888114d240a80bfb04c893a7485808904
Author: Thorsten Behrens <tbehrens at novell.com>
Date: Thu Jan 21 12:20:42 2010 +0100
Updated to latest thbfixes10 state
* patches/test/opengl-canvas.diff: an opengl-based canvas
implementation
diff --git a/patches/test/opengl-canvas.diff b/patches/test/opengl-canvas.diff
index 0eb6644..5689332 100644
--- a/patches/test/opengl-canvas.diff
+++ b/patches/test/opengl-canvas.diff
@@ -1,173 +1,11 @@
-Necessary slideshow changes for working properly with ogl canvas
+Opengl canvas implementation
From: Thorsten Behrens <thb at openoffice.org>
-
----
-
- slideshow/source/engine/slideview.cxx | 9 +++++----
- .../source/engine/transitions/slidechangebase.cxx | 1 +
- .../engine/transitions/slidetransitionfactory.cxx | 2 ++
- 3 files changed, 8 insertions(+), 4 deletions(-)
-
-
-diff --git slideshow/source/engine/slideview.cxx slideshow/source/engine/slideview.cxx
-index ad511f5..6a11cda 100644
---- slideshow/source/engine/slideview.cxx
-+++ slideshow/source/engine/slideview.cxx
-@@ -888,6 +888,11 @@ void SlideView::clearAll() const
- if( !mxView.is() || !mpCanvas )
- return;
-
-+ mpCanvas->clear(); // this is unnecessary, strictly speaking. but
-+ // it makes the SlideView behave exactly like a
-+ // sprite-based SlideViewLayer, because those
-+ // are created from scratch after a resize
-+
- // clear whole view
- mxView->clear();
- }
-@@ -1091,10 +1096,6 @@ void SlideView::updateCanvas()
- if( !mpCanvas || !mxView.is())
- return;
-
-- mpCanvas->clear(); // this is unnecessary, strictly speaking. but
-- // it makes the SlideView behave exactly like a
-- // sprite-based SlideViewLayer, because those
-- // are created from scratch after a resize
- clearAll();
- mpCanvas->setTransformation( getTransformation() );
- mpCanvas->setClip(
-diff --git slideshow/source/engine/transitions/slidechangebase.cxx slideshow/source/engine/transitions/slidechangebase.cxx
-index 2983e6b..1432b95 100644
---- slideshow/source/engine/transitions/slidechangebase.cxx
-+++ slideshow/source/engine/transitions/slidechangebase.cxx
-@@ -245,6 +245,7 @@ void SlideChangeBase::end()
-
- const SlideBitmapSharedPtr pSlideBitmap( getEnteringBitmap( *aCurr ));
- pSlideBitmap->clip( basegfx::B2DPolyPolygon() /* no clipping */ );
-+ aCurr->mpView->clearAll();
- renderBitmap( pSlideBitmap,
- aCurr->mpView->getCanvas() );
-
-diff --git slideshow/source/engine/transitions/slidetransitionfactory.cxx slideshow/source/engine/transitions/slidetransitionfactory.cxx
-index b82025a..f3a22e9 100644
---- slideshow/source/engine/transitions/slidetransitionfactory.cxx
-+++ slideshow/source/engine/transitions/slidetransitionfactory.cxx
-@@ -421,6 +421,7 @@ void MovingSlideChange::performIn(
- if (mbFirstPerformCall && maLeavingDirection.equalZero())
- {
- mbFirstPerformCall = false;
-+ rViewEntry.mpView->clearAll();
- renderBitmap( getLeavingBitmap(rViewEntry), rDestinationCanvas );
- }
-
-@@ -459,6 +460,7 @@ void MovingSlideChange::performOut(
- if (mbFirstPerformCall && maEnteringDirection.equalZero())
- {
- mbFirstPerformCall = false;
-+ rViewEntry.mpView->clearAll();
- renderBitmap( getEnteringBitmap(rViewEntry), rDestinationCanvas );
- }
-
-A hackweek project - doing XCanvas API natively in OpenGL
-
-From: Thorsten Behrens <thb at openoffice.org>
-
-
----
-
- .../inc/basegfx/polygon/b2dpolypolygontools.hxx | 20
- basegfx/inc/basegfx/tools/tools.hxx | 25
- basegfx/source/polygon/b2dpolypolygontools.cxx | 132 +++
- basegfx/source/tools/makefile.mk | 1
- basegfx/source/tools/numbertools.cxx | 79 +
- canvas/prj/build.lst | 1
- canvas/prj/d.lst | 2
- canvas/source/cairo/cairo_canvashelper.hxx | 1
- canvas/source/directx/dx_bitmapcanvashelper.hxx | 1
- canvas/source/null/null_canvashelper.hxx | 1
- canvas/source/opengl/exports.dxp | 3
- canvas/source/opengl/exports.map | 8
- canvas/source/opengl/makefile.mk | 67 +
- canvas/source/opengl/ogl_bitmapcanvashelper.cxx | 108 ++
- canvas/source/opengl/ogl_bitmapcanvashelper.hxx | 107 ++
- canvas/source/opengl/ogl_buffercontext.hxx | 38 +
- canvas/source/opengl/ogl_canvasbitmap.cxx | 63 +
- canvas/source/opengl/ogl_canvasbitmap.hxx | 82 ++
- canvas/source/opengl/ogl_canvascustomsprite.cxx | 265 +++++
- canvas/source/opengl/ogl_canvascustomsprite.hxx | 103 ++
- canvas/source/opengl/ogl_canvasfont.cxx | 88 ++
- canvas/source/opengl/ogl_canvasfont.hxx | 72 +
- canvas/source/opengl/ogl_canvashelper.cxx | 1019 +++++++++++++++++++
- canvas/source/opengl/ogl_canvashelper.hxx | 242 +++++
- canvas/source/opengl/ogl_canvastools.cxx | 147 +++
- canvas/source/opengl/ogl_canvastools.hxx | 41 +
- canvas/source/opengl/ogl_spritecanvas.cxx | 202 ++++
- canvas/source/opengl/ogl_spritecanvas.hxx | 126 ++
- canvas/source/opengl/ogl_spritedevicehelper.cxx | 1055 ++++++++++++++++++++
- canvas/source/opengl/ogl_spritedevicehelper.hxx | 176 +++
- canvas/source/opengl/ogl_textlayout.cxx | 222 ++++
- canvas/source/opengl/ogl_textlayout.hxx | 83 ++
- canvas/source/opengl/ogl_texturecache.cxx | 132 +++
- canvas/source/opengl/ogl_texturecache.hxx | 68 +
- canvas/source/opengl/ogl_tools.hxx | 35 +
- canvas/source/tools/canvastools.cxx | 10
- canvas/source/vcl/canvashelper.hxx | 1
- cppcanvas/inc/cppcanvas/spritecanvas.hxx | 4
- cppcanvas/source/wrapper/implspritecanvas.cxx | 4
- cppcanvas/source/wrapper/implspritecanvas.hxx | 4
- .../com/sun/star/presentation/XSlideShowView.idl | 10
- offapi/com/sun/star/rendering/XSpriteCanvas.idl | 13
- .../registry/data/org/openoffice/Office/Canvas.xcu | 1
- scp2/source/canvas/makefile.mk | 1
- scp2/source/canvas/openglcanvas.scp | 28 +
- scp2/util/makefile.mk | 4
- sd/source/ui/presenter/PresenterCanvas.cxx | 11
- sd/source/ui/presenter/PresenterCanvas.hxx | 4
- sd/source/ui/presenter/PresenterTextView.cxx | 1
- sd/source/ui/presenter/SlideRenderer.cxx | 1
- sd/source/ui/slideshow/slideshowimpl.cxx | 7
- sd/source/ui/slideshow/slideshowviewimpl.cxx | 13
- sd/source/ui/slideshow/slideshowviewimpl.hxx | 1
- sdext/source/presenter/PresenterSlideShowView.cxx | 48 +
- sdext/source/presenter/PresenterSlideShowView.hxx | 7
- slideshow/source/engine/waitsymbol.cxx | 13
- 56 files changed, 4936 insertions(+), 65 deletions(-)
- create mode 100644 basegfx/source/tools/numbertools.cxx
- create mode 100644 canvas/source/opengl/exports.dxp
- create mode 100644 canvas/source/opengl/exports.map
- create mode 100644 canvas/source/opengl/makefile.mk
- create mode 100644 canvas/source/opengl/ogl_bitmapcanvashelper.cxx
- create mode 100644 canvas/source/opengl/ogl_bitmapcanvashelper.hxx
- create mode 100644 canvas/source/opengl/ogl_buffercontext.hxx
- create mode 100644 canvas/source/opengl/ogl_canvasbitmap.cxx
- create mode 100644 canvas/source/opengl/ogl_canvasbitmap.hxx
- create mode 100644 canvas/source/opengl/ogl_canvascustomsprite.cxx
- create mode 100644 canvas/source/opengl/ogl_canvascustomsprite.hxx
- create mode 100644 canvas/source/opengl/ogl_canvasfont.cxx
- create mode 100644 canvas/source/opengl/ogl_canvasfont.hxx
- create mode 100644 canvas/source/opengl/ogl_canvashelper.cxx
- create mode 100644 canvas/source/opengl/ogl_canvashelper.hxx
- create mode 100644 canvas/source/opengl/ogl_canvastools.cxx
- create mode 100644 canvas/source/opengl/ogl_canvastools.hxx
- create mode 100644 canvas/source/opengl/ogl_spritecanvas.cxx
- create mode 100644 canvas/source/opengl/ogl_spritecanvas.hxx
- create mode 100644 canvas/source/opengl/ogl_spritedevicehelper.cxx
- create mode 100644 canvas/source/opengl/ogl_spritedevicehelper.hxx
- create mode 100644 canvas/source/opengl/ogl_textlayout.cxx
- create mode 100644 canvas/source/opengl/ogl_textlayout.hxx
- create mode 100644 canvas/source/opengl/ogl_texturecache.cxx
- create mode 100644 canvas/source/opengl/ogl_texturecache.hxx
- create mode 100644 canvas/source/opengl/ogl_tools.hxx
- create mode 100644 scp2/source/canvas/openglcanvas.scp
-
-
-diff --git basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
-index dd56633..d25558c 100644
---- basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
-+++ basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
-@@ -257,6 +257,26 @@ namespace basegfx
+diff -r 6ae934bd30f5 basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
+--- a/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx Tue Jan 19 22:12:52 2010 +0100
+@@ -257,6 +257,26 @@
*/
B2DPolyPolygon reSegmentPolyPolygonEdges(const B2DPolyPolygon& rCandidate, sal_uInt32 nSubEdges, bool bHandleCurvedEdges, bool bHandleStraightEdges);
@@ -194,11 +32,10 @@ index dd56633..d25558c 100644
//////////////////////////////////////////////////////////////////////
// comparators with tolerance for 2D PolyPolygons
bool equal(const B2DPolyPolygon& rCandidateA, const B2DPolyPolygon& rCandidateB, const double& rfSmallValue);
-diff --git basegfx/inc/basegfx/tools/tools.hxx basegfx/inc/basegfx/tools/tools.hxx
-index 62ad8de..cc89fb4 100644
---- basegfx/inc/basegfx/tools/tools.hxx
-+++ basegfx/inc/basegfx/tools/tools.hxx
-@@ -37,6 +37,7 @@ namespace basegfx
+diff -r 6ae934bd30f5 basegfx/inc/basegfx/tools/tools.hxx
+--- a/basegfx/inc/basegfx/tools/tools.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/basegfx/inc/basegfx/tools/tools.hxx Tue Jan 19 22:12:52 2010 +0100
+@@ -37,6 +37,7 @@
{
class B2DPoint;
class B2DRange;
@@ -206,7 +43,7 @@ index 62ad8de..cc89fb4 100644
namespace tools
{
-@@ -128,6 +129,30 @@ namespace basegfx
+@@ -128,6 +129,30 @@
::basegfx::B2DPoint& io_rRightBottom,
const ::basegfx::B2DRange& rFitTarget );
@@ -237,12 +74,11 @@ index 62ad8de..cc89fb4 100644
}
}
-diff --git basegfx/source/polygon/b2dpolypolygontools.cxx basegfx/source/polygon/b2dpolypolygontools.cxx
-index 485287f..06093c9 100644
---- basegfx/source/polygon/b2dpolypolygontools.cxx
-+++ basegfx/source/polygon/b2dpolypolygontools.cxx
-@@ -569,6 +569,138 @@ namespace basegfx
- return equal(rCandidateA, rCandidateB, fSmallValue);
+diff -r 6ae934bd30f5 basegfx/source/polygon/b2dpolypolygontools.cxx
+--- a/basegfx/source/polygon/b2dpolypolygontools.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/basegfx/source/polygon/b2dpolypolygontools.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -581,6 +581,138 @@
+ return aRetval;
}
+ B2DPolyPolygon createSevenSegmentPolyPolygon(sal_Char nNumber, bool bLitSegments)
@@ -380,23 +216,20 @@ index 485287f..06093c9 100644
} // end of namespace tools
} // end of namespace basegfx
-diff --git basegfx/source/tools/makefile.mk basegfx/source/tools/makefile.mk
-index df75a82..22b8e5c 100755
---- basegfx/source/tools/makefile.mk
-+++ basegfx/source/tools/makefile.mk
-@@ -45,6 +45,7 @@ SLOFILES= $(SLO)$/canvastools.obj \
- $(SLO)$/gradienttools.obj \
+diff -r 6ae934bd30f5 basegfx/source/tools/makefile.mk
+--- a/basegfx/source/tools/makefile.mk Mon Jan 18 21:14:50 2010 +0100
++++ b/basegfx/source/tools/makefile.mk Tue Jan 19 22:12:52 2010 +0100
+@@ -47,6 +47,7 @@
$(SLO)$/debugplotter.obj \
+ $(SLO)$/keystoplerp.obj \
$(SLO)$/liangbarsky.obj \
+ $(SLO)$/numbertools.obj \
$(SLO)$/tools.obj \
$(SLO)$/unopolypolygon.obj
-diff --git basegfx/source/tools/numbertools.cxx basegfx/source/tools/numbertools.cxx
-new file mode 100644
-index 0000000..91520c2
---- /dev/null
-+++ basegfx/source/tools/numbertools.cxx
+diff -r 6ae934bd30f5 basegfx/source/tools/numbertools.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/basegfx/source/tools/numbertools.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,79 @@
+/*************************************************************************
+ *
@@ -477,22 +310,19 @@ index 0000000..91520c2
+ }
+
+} }
-diff --git canvas/prj/build.lst canvas/prj/build.lst
-index df1f8e9..3f94041 100644
---- canvas/prj/build.lst
-+++ canvas/prj/build.lst
-@@ -6,6 +6,7 @@ cv canvas\source\vcl nmake - all cv_vcl cv_tools cv_inc NULL
+diff -r 6ae934bd30f5 canvas/prj/build.lst
+--- a/canvas/prj/build.lst Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/prj/build.lst Tue Jan 19 22:12:52 2010 +0100
+@@ -6,5 +6,6 @@
cv canvas\source\simplecanvas nmake - all cv_simplecanvas cv_tools cv_inc NULL
cv canvas\source\cairo nmake - all cv_cairo cv_tools cv_inc NULL
cv canvas\source\directx nmake - w cv_directx cv_tools cv_inc NULL
+cv canvas\source\opengl nmake - all cv_opengl cv_tools cv_inc NULL
cv canvas\source\null nmake - all cv_null cv_tools cv_inc NULL
- cv canvas\source\java nmake - all cv_java cv_inc NULL
cv canvas\source\factory nmake - all cv_factory cv_inc NULL
-diff --git canvas/prj/d.lst canvas/prj/d.lst
-index 986253a..dbffabf 100644
---- canvas/prj/d.lst
-+++ canvas/prj/d.lst
+diff -r 6ae934bd30f5 canvas/prj/d.lst
+--- a/canvas/prj/d.lst Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/prj/d.lst Tue Jan 19 22:12:52 2010 +0100
@@ -1,5 +1,6 @@
..\%__SRC%\bin\canvasto*.dll %_DEST%\bin%_EXT%\canvasto*.dll
..\%__SRC%\bin\cairocan*.dll %_DEST%\bin%_EXT%\cairocan*.dll
@@ -508,10 +338,9 @@ index 986253a..dbffabf 100644
..\%__SRC%\lib\vclcanvas.uno.so %_DEST%\lib%_EXT%\vclcanvas.uno.so
..\%__SRC%\lib\nullcanvas.uno.so %_DEST%\lib%_EXT%\nullcanvas.uno.so
..\%__SRC%\lib\simplecanvas.uno.so %_DEST%\lib%_EXT%\simplecanvas.uno.so
-diff --git canvas/source/cairo/cairo_canvashelper.hxx canvas/source/cairo/cairo_canvashelper.hxx
-index 3bbcf6c..a1f6a12 100644
---- canvas/source/cairo/cairo_canvashelper.hxx
-+++ canvas/source/cairo/cairo_canvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/cairo/cairo_canvashelper.hxx
+--- a/canvas/source/cairo/cairo_canvashelper.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/source/cairo/cairo_canvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -32,6 +32,7 @@
#define _CAIROCANVAS_CANVASHELPER_HXX_
@@ -520,10 +349,9 @@ index 3bbcf6c..a1f6a12 100644
#include <com/sun/star/rendering/XIntegerBitmap.hpp>
#include <basegfx/vector/b2isize.hxx>
-diff --git canvas/source/directx/dx_bitmapcanvashelper.hxx canvas/source/directx/dx_bitmapcanvashelper.hxx
-index 0d9c0b7..cd47368 100755
---- canvas/source/directx/dx_bitmapcanvashelper.hxx
-+++ canvas/source/directx/dx_bitmapcanvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/directx/dx_bitmapcanvashelper.hxx
+--- a/canvas/source/directx/dx_bitmapcanvashelper.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/source/directx/dx_bitmapcanvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -32,6 +32,7 @@
#define _DXCANVAS_BITMAPCANVASHELPER_HXX_
@@ -532,10 +360,9 @@ index 0d9c0b7..cd47368 100755
#include <basegfx/vector/b2isize.hxx>
#include <basegfx/vector/b2dsize.hxx>
-diff --git canvas/source/null/null_canvashelper.hxx canvas/source/null/null_canvashelper.hxx
-index 30c8ab6..5923814 100644
---- canvas/source/null/null_canvashelper.hxx
-+++ canvas/source/null/null_canvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/null/null_canvashelper.hxx
+--- a/canvas/source/null/null_canvashelper.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/source/null/null_canvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -32,6 +32,7 @@
#define _NULLCANVAS_CANVASHELPER_HXX_
@@ -544,20 +371,16 @@ index 30c8ab6..5923814 100644
#include <com/sun/star/rendering/XIntegerBitmap.hpp>
#include <basegfx/vector/b2isize.hxx>
-diff --git canvas/source/opengl/exports.dxp canvas/source/opengl/exports.dxp
-new file mode 100644
-index 0000000..9630d7e
---- /dev/null
-+++ canvas/source/opengl/exports.dxp
+diff -r 6ae934bd30f5 canvas/source/opengl/exports.dxp
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/exports.dxp Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,3 @@
+component_getImplementationEnvironment
+component_writeInfo
+component_getFactory
-diff --git canvas/source/opengl/exports.map canvas/source/opengl/exports.map
-new file mode 100644
-index 0000000..ff8f9ed
---- /dev/null
-+++ canvas/source/opengl/exports.map
+diff -r 6ae934bd30f5 canvas/source/opengl/exports.map
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/exports.map Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,8 @@
+CAN_1_0 {
+ global:
@@ -567,11 +390,9 @@ index 0000000..ff8f9ed
+ local:
+ *;
+};
-diff --git canvas/source/opengl/makefile.mk canvas/source/opengl/makefile.mk
-new file mode 100644
-index 0000000..90fb7ea
---- /dev/null
-+++ canvas/source/opengl/makefile.mk
+diff -r 6ae934bd30f5 canvas/source/opengl/makefile.mk
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/makefile.mk Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,67 @@
+#*************************************************************************
+#
@@ -640,11 +461,9 @@ index 0000000..90fb7ea
+# ==========================================================================
+
+.INCLUDE : target.mk
-diff --git canvas/source/opengl/ogl_bitmapcanvashelper.cxx canvas/source/opengl/ogl_bitmapcanvashelper.cxx
-new file mode 100644
-index 0000000..e3f516e
---- /dev/null
-+++ canvas/source/opengl/ogl_bitmapcanvashelper.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_bitmapcanvashelper.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_bitmapcanvashelper.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,108 @@
+/*************************************************************************
+ *
@@ -754,11 +573,9 @@ index 0000000..e3f516e
+ }
+
+}
-diff --git canvas/source/opengl/ogl_bitmapcanvashelper.hxx canvas/source/opengl/ogl_bitmapcanvashelper.hxx
-new file mode 100644
-index 0000000..2d2faeb
---- /dev/null
-+++ canvas/source/opengl/ogl_bitmapcanvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_bitmapcanvashelper.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_bitmapcanvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,107 @@
+/*************************************************************************
+ *
@@ -867,11 +684,9 @@ index 0000000..2d2faeb
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_buffercontext.hxx canvas/source/opengl/ogl_buffercontext.hxx
-new file mode 100644
-index 0000000..7cc2311
---- /dev/null
-+++ canvas/source/opengl/ogl_buffercontext.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_buffercontext.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_buffercontext.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,38 @@
+/*************************************************************************
+ *
@@ -911,11 +726,9 @@ index 0000000..7cc2311
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_canvasbitmap.cxx canvas/source/opengl/ogl_canvasbitmap.cxx
-new file mode 100644
-index 0000000..9853461
---- /dev/null
-+++ canvas/source/opengl/ogl_canvasbitmap.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvasbitmap.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvasbitmap.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,63 @@
+/*************************************************************************
+ *
@@ -980,11 +793,9 @@ index 0000000..9853461
+ return maCanvasHelper.renderRecordedActions();
+ }
+}
-diff --git canvas/source/opengl/ogl_canvasbitmap.hxx canvas/source/opengl/ogl_canvasbitmap.hxx
-new file mode 100644
-index 0000000..aa0d242
---- /dev/null
-+++ canvas/source/opengl/ogl_canvasbitmap.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvasbitmap.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvasbitmap.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,82 @@
+/*************************************************************************
+ *
@@ -1068,11 +879,9 @@ index 0000000..aa0d242
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_canvascustomsprite.cxx canvas/source/opengl/ogl_canvascustomsprite.cxx
-new file mode 100644
-index 0000000..e12ed7e
---- /dev/null
-+++ canvas/source/opengl/ogl_canvascustomsprite.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvascustomsprite.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvascustomsprite.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,265 @@
+/*************************************************************************
+ *
@@ -1339,11 +1148,9 @@ index 0000000..e12ed7e
+ return true;
+ }
+}
-diff --git canvas/source/opengl/ogl_canvascustomsprite.hxx canvas/source/opengl/ogl_canvascustomsprite.hxx
-new file mode 100644
-index 0000000..82f3777
---- /dev/null
-+++ canvas/source/opengl/ogl_canvascustomsprite.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvascustomsprite.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvascustomsprite.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,103 @@
+/*************************************************************************
+ *
@@ -1448,11 +1255,9 @@ index 0000000..82f3777
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_canvasfont.cxx canvas/source/opengl/ogl_canvasfont.cxx
-new file mode 100644
-index 0000000..9473fb3
---- /dev/null
-+++ canvas/source/opengl/ogl_canvasfont.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvasfont.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvasfont.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,88 @@
+/*************************************************************************
+ *
@@ -1542,11 +1347,9 @@ index 0000000..9473fb3
+ return maFontMatrix;
+ }
+}
-diff --git canvas/source/opengl/ogl_canvasfont.hxx canvas/source/opengl/ogl_canvasfont.hxx
-new file mode 100644
-index 0000000..3c84f11
---- /dev/null
-+++ canvas/source/opengl/ogl_canvasfont.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvasfont.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvasfont.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,72 @@
+/*************************************************************************
+ *
@@ -1620,12 +1423,10 @@ index 0000000..3c84f11
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_canvashelper.cxx canvas/source/opengl/ogl_canvashelper.cxx
-new file mode 100644
-index 0000000..5b05591
---- /dev/null
-+++ canvas/source/opengl/ogl_canvashelper.cxx
-@@ -0,0 +1,1019 @@
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvashelper.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvashelper.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -0,0 +1,1022 @@
+/*************************************************************************
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
@@ -1822,11 +1623,6 @@ index 0000000..5b05591
+ TransformationPreserver aPreserver;
+ setupState(rTransform, eSrcBlend, eDstBlend, rendering::ARGBColor());
+
-+ const rendering::ARGBColor aStartColor(
-+ rHelper.getDevice()->getDeviceColorSpace()->convertToARGB(rValues.maColors[0])[0]);
-+ const rendering::ARGBColor aEndColor(
-+ rHelper.getDevice()->getDeviceColorSpace()->convertToARGB(rValues.maColors[1])[0]);
-+
+ // convert to weird canvas textur coordinate system (not
+ // [0,1]^2, but path coordinate system)
+ ::basegfx::B2DHomMatrix aTextureTransform;
@@ -1840,24 +1636,32 @@ index 0000000..5b05591
+ aTextureTransform.translate(-aBounds.getMinX(), -aBounds.getMinY());
+ aTextureTransform.scale(1/aBounds.getWidth(), 1/aBounds.getHeight());
+
++ const sal_Int32 nNumCols=rValues.maColors.getLength();
++ uno::Sequence< rendering::ARGBColor > aColors(nNumCols);
++ rendering::ARGBColor* const pColors=aColors.getArray();
++ rendering::ARGBColor* pCurrCol=pColors;
++ for( sal_Int32 i=0; i<nNumCols; ++i )
++ *pCurrCol++ = rHelper.getDevice()->getDeviceColorSpace()->convertToARGB(rValues.maColors[i])[0];
++
++ OSL_ASSERT(nNumCols == rValues.maStops.getLength());
++
+ switch( rValues.meType )
+ {
-+ case ::canvas::ParametricPolyPolygon::GRADIENT_AXIAL:
+ case ::canvas::ParametricPolyPolygon::GRADIENT_LINEAR:
-+ rHelper.getDeviceHelper()->useLinearGradientShader(aStartColor,
-+ aEndColor,
++ rHelper.getDeviceHelper()->useLinearGradientShader(pColors,
++ rValues.maStops,
+ aTextureTransform);
+ break;
+
+ case ::canvas::ParametricPolyPolygon::GRADIENT_ELLIPTICAL:
-+ rHelper.getDeviceHelper()->useRadialGradientShader(aStartColor,
-+ aEndColor,
++ rHelper.getDeviceHelper()->useRadialGradientShader(pColors,
++ rValues.maStops,
+ aTextureTransform);
+ break;
+
+ case ::canvas::ParametricPolyPolygon::GRADIENT_RECTANGULAR:
-+ rHelper.getDeviceHelper()->useRectangularGradientShader(aStartColor,
-+ aEndColor,
++ rHelper.getDeviceHelper()->useRectangularGradientShader(pColors,
++ rValues.maStops,
+ aTextureTransform);
+ break;
+
@@ -2645,11 +2449,9 @@ index 0000000..5b05591
+ return mpRecordedActions->size();
+ }
+}
-diff --git canvas/source/opengl/ogl_canvashelper.hxx canvas/source/opengl/ogl_canvashelper.hxx
-new file mode 100644
-index 0000000..7ac6bd8
---- /dev/null
-+++ canvas/source/opengl/ogl_canvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvashelper.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,242 @@
+/*************************************************************************
+ *
@@ -2893,11 +2695,9 @@ index 0000000..7ac6bd8
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_canvastools.cxx canvas/source/opengl/ogl_canvastools.cxx
-new file mode 100644
-index 0000000..17f9b16
---- /dev/null
-+++ canvas/source/opengl/ogl_canvastools.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvastools.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvastools.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,147 @@
+/*************************************************************************
+ *
@@ -3046,11 +2846,9 @@ index 0000000..17f9b16
+ }
+ }
+}
-diff --git canvas/source/opengl/ogl_canvastools.hxx canvas/source/opengl/ogl_canvastools.hxx
-new file mode 100644
-index 0000000..69aa0c7
---- /dev/null
-+++ canvas/source/opengl/ogl_canvastools.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_canvastools.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_canvastools.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,41 @@
+/*************************************************************************
+ *
@@ -3093,11 +2891,9 @@ index 0000000..69aa0c7
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_spritecanvas.cxx canvas/source/opengl/ogl_spritecanvas.cxx
-new file mode 100644
-index 0000000..275adbc
---- /dev/null
-+++ canvas/source/opengl/ogl_spritecanvas.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_spritecanvas.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_spritecanvas.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,202 @@
+/*************************************************************************
+ *
@@ -3301,12 +3097,10 @@ index 0000000..275adbc
+
+// The C shared lib entry points
+COMPHELPER_SERVICEDECL_EXPORTS1(oglcanvas::oglSpriteCanvasDecl);
-diff --git canvas/source/opengl/ogl_spritecanvas.hxx canvas/source/opengl/ogl_spritecanvas.hxx
-new file mode 100644
-index 0000000..ea14bc7
---- /dev/null
-+++ canvas/source/opengl/ogl_spritecanvas.hxx
-@@ -0,0 +1,126 @@
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_spritecanvas.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_spritecanvas.hxx Tue Jan 19 22:12:52 2010 +0100
+@@ -0,0 +1,125 @@
+/*************************************************************************
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
@@ -3335,7 +3129,6 @@ index 0000000..ea14bc7
+#include <com/sun/star/rendering/XSpriteCanvas.hpp>
+#include <com/sun/star/rendering/XGraphicDevice.hpp>
+#include <com/sun/star/rendering/XBufferController.hpp>
-+#include <com/sun/star/rendering/XParametricPolyPolygon2DFactory.hpp>
+
+#include <cppuhelper/compbase8.hxx>
+#include <comphelper/uno3.hxx>
@@ -3353,13 +3146,13 @@ index 0000000..ea14bc7
+ class CanvasCustomSprite;
+
+ typedef ::cppu::WeakComponentImplHelper8< ::com::sun::star::rendering::XSpriteCanvas,
-+ ::com::sun::star::rendering::XGraphicDevice,
-+ ::com::sun::star::rendering::XParametricPolyPolygon2DFactory,
-+ ::com::sun::star::rendering::XBufferController,
-+ ::com::sun::star::awt::XWindowListener,
-+ ::com::sun::star::util::XUpdatable,
-+ ::com::sun::star::beans::XPropertySet,
-+ ::com::sun::star::lang::XServiceName > WindowGraphicDeviceBase_Base;
++ ::com::sun::star::rendering::XGraphicDevice,
++ ::com::sun::star::lang::XMultiServiceFactory,
++ ::com::sun::star::rendering::XBufferController,
++ ::com::sun::star::awt::XWindowListener,
++ ::com::sun::star::util::XUpdatable,
++ ::com::sun::star::beans::XPropertySet,
++ ::com::sun::star::lang::XServiceName > WindowGraphicDeviceBase_Base;
+ typedef ::canvas::BufferedGraphicDeviceBase< ::canvas::BaseMutexHelper< WindowGraphicDeviceBase_Base >,
+ SpriteDeviceHelper,
+ ::osl::MutexGuard,
@@ -3433,12 +3226,10 @@ index 0000000..ea14bc7
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_spritedevicehelper.cxx canvas/source/opengl/ogl_spritedevicehelper.cxx
-new file mode 100644
-index 0000000..92a0514
---- /dev/null
-+++ canvas/source/opengl/ogl_spritedevicehelper.cxx
-@@ -0,0 +1,1055 @@
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_spritedevicehelper.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_spritedevicehelper.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -0,0 +1,1258 @@
+/*************************************************************************
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
@@ -3519,7 +3310,7 @@ index 0000000..92a0514
+
+/** Two-color linear gradient
+ */
-+static const char linearGradientFragmentShader[] =
++static const char linearTwoColorGradientFragmentShader[] =
+{
+ "#version 120 \n"
+ "uniform vec4 v_startColor4d; "
@@ -3530,13 +3321,54 @@ index 0000000..92a0514
+ "{ "
+ " gl_FragColor = mix(v_startColor4d, "
+ " v_endColor4d, "
-+ " (m_transform * vec3(v_textureCoords2d,1)).s); "
++ " clamp( "
++ " (m_transform * vec3(v_textureCoords2d,1)).s, "
++ " 0.0, 1.0)); "
++ "} "
++};
++
++/** N-color linear gradient
++ */
++static const char linearMultiColorGradientFragmentShader[] =
++{
++ "#version 120 \n"
++ "uniform int i_nColors; "
++ "uniform sampler1D t_colorArray4d; "
++ "uniform sampler1D t_stopArray1d; "
++ "uniform mat3x2 m_transform; "
++ "varying vec2 v_textureCoords2d; "
++ " "
++ "int findBucket(float t) "
++ "{ "
++ " int nMinBucket=0; "
++ " while( nMinBucket < i_nColors && "
++ " texture1D(t_stopArray1d, nMinBucket).s < t ) "
++ " ++nMinBucket; "
++ " return max(nMinBucket-1,0); "
++ "} "
++ " "
++ "void main(void) "
++ "{ "
++ " const float fAlpha = "
++ " clamp( (m_transform * vec3(v_textureCoords2d,1)).s, "
++ " 0.0, 1.0 ); "
++ " "
++ " const int nMinBucket=findBucket( fAlpha ); "
++ " "
++ " const float fLerp = "
++ " (fAlpha-texture1D(t_stopArray1d, nMinBucket).s) / "
++ " (texture1D(t_stopArray1d, nMinBucket+1).s - "
++ " texture1D(t_stopArray1d, nMinBucket).s); "
++ " "
++ " gl_FragColor = mix(texture1D(t_colorArray4d, nMinBucket), "
++ " texture1D(t_colorArray4d, nMinBucket+1), "
++ " fLerp); "
+ "} "
+};
+
+/** Two-color radial gradient
+ */
-+static const char radialGradientFragmentShader[] =
++static const char radialTwoColorGradientFragmentShader[] =
+{
+ "#version 120 \n"
+ "uniform vec4 v_startColor4d; "
@@ -3555,9 +3387,51 @@ index 0000000..92a0514
+ "} "
+};
+
++/** Multi-color radial gradient
++ */
++static const char radialMultiColorGradientFragmentShader[] =
++{
++ "#version 120 \n"
++ "uniform int i_nColors; "
++ "uniform sampler1D t_colorArray4d; "
++ "uniform sampler1D t_stopArray1d; "
++ "uniform mat3x2 m_transform; "
++ "varying vec2 v_textureCoords2d; "
++ "const vec2 v_center2d = vec2(0,0); "
++ " "
++ "int findBucket(float t) "
++ "{ "
++ " int nMinBucket=0; "
++ " while( nMinBucket < i_nColors && "
++ " texture1D(t_stopArray1d, nMinBucket).s < t ) "
++ " ++nMinBucket; "
++ " return max(nMinBucket-1,0); "
++ "} "
++ " "
++ "void main(void) "
++ "{ "
++ " const float fAlpha = "
++ " clamp( 1.0 - distance( "
++ " vec2( m_transform * vec3(v_textureCoords2d,1)), "
++ " v_center2d), "
++ " 0.0, 1.0 ); "
++ " "
++ " const int nMinBucket=findBucket( fAlpha ); "
++ " "
++ " const float fLerp = "
++ " (fAlpha-texture1D(t_stopArray1d, nMinBucket).s) / "
++ " (texture1D(t_stopArray1d, nMinBucket+1).s - "
++ " texture1D(t_stopArray1d, nMinBucket).s); "
++ " "
++ " gl_FragColor = mix(texture1D(t_colorArray4d, nMinBucket), "
++ " texture1D(t_colorArray4d, nMinBucket+1), "
++ " fLerp); "
++ "} "
++};
++
+/** Two-color rectangular gradient
+ */
-+static const char rectangularGradientFragmentShader[] =
++static const char rectangularTwoColorGradientFragmentShader[] =
+{
+ "#version 120 \n"
+ "uniform vec4 v_startColor4d; "
@@ -3574,6 +3448,44 @@ index 0000000..92a0514
+ "} "
+};
+
++/** Multi-color rectangular gradient
++ */
++static const char rectangularMultiColorGradientFragmentShader[] =
++{
++ "#version 120 \n"
++ "uniform int i_nColors; "
++ "uniform sampler1D t_colorArray4d; "
++ "uniform sampler1D t_stopArray1d; "
++ "uniform mat3x2 m_transform; "
++ "varying vec2 v_textureCoords2d; "
++ " "
++ "int findBucket(float t) "
++ "{ "
++ " int nMinBucket=0; "
++ " while( nMinBucket < i_nColors && "
++ " texture1D(t_stopArray1d, nMinBucket).s < t ) "
++ " ++nMinBucket; "
++ " return max(nMinBucket-1,0); "
++ "} "
++ " "
++ "void main(void) "
++ "{ "
++ " const vec2 v = abs( vec2(m_transform * vec3(v_textureCoords2d,1)) ); "
++ " const float fAlpha = 1 - max(v.x, v.y); "
++ " "
++ " const int nMinBucket=findBucket( fAlpha ); "
++ " "
++ " const float fLerp = "
++ " (fAlpha-texture1D(t_stopArray1d, nMinBucket).s) / "
++ " (texture1D(t_stopArray1d, nMinBucket+1).s - "
++ " texture1D(t_stopArray1d, nMinBucket).s); "
++ " "
++ " gl_FragColor = mix(texture1D(t_colorArray4d, nMinBucket), "
++ " texture1D(t_colorArray4d, nMinBucket+1), "
++ " fLerp); "
++ "} "
++};
++
+static void initContext()
+{
+ // need the backside for mirror effects
@@ -3860,12 +3772,18 @@ index 0000000..92a0514
+ mpFBConfig(NULL),
+ mpTextureCache(new TextureCache()),
+ mnDummyVertexProgram(0),
-+ mnLinearGradientFragmentProgram(0),
-+ mnRadialGradientFragmentProgram(0),
-+ mnRectangularGradientFragmentProgram(0),
-+ mnLinearGradientProgram(0),
-+ mnRadialGradientProgram(0),
-+ mnRectangularGradientProgram(0)
++ mnLinearTwoColorGradientFragmentProgram(0),
++ mnLinearMultiColorGradientFragmentProgram(0),
++ mnRadialTwoColorGradientFragmentProgram(0),
++ mnRadialMultiColorGradientFragmentProgram(0),
++ mnRectangularTwoColorGradientFragmentProgram(0),
++ mnRectangularMultiColorGradientFragmentProgram(0),
++ mnLinearTwoColorGradientProgram(0),
++ mnLinearMultiColorGradientProgram(0),
++ mnRadialTwoColorGradientProgram(0),
++ mnRadialMultiColorGradientProgram(0),
++ mnRectangularTwoColorGradientProgram(0),
++ mnRectangularMultiColorGradientProgram(0)
+ {}
+
+ void SpriteDeviceHelper::init( Window& rWindow,
@@ -3978,24 +3896,42 @@ index 0000000..92a0514
+ compileShader(mnDummyVertexProgram,
+ GL_VERTEX_SHADER,
+ dummyVertexShader);
-+ compileShader(mnLinearGradientFragmentProgram,
++ compileShader(mnLinearTwoColorGradientFragmentProgram,
++ GL_FRAGMENT_SHADER,
++ linearTwoColorGradientFragmentShader);
++ compileShader(mnLinearMultiColorGradientFragmentProgram,
+ GL_FRAGMENT_SHADER,
-+ linearGradientFragmentShader);
-+ compileShader(mnRadialGradientFragmentProgram,
++ linearMultiColorGradientFragmentShader);
++ compileShader(mnRadialTwoColorGradientFragmentProgram,
+ GL_FRAGMENT_SHADER,
-+ radialGradientFragmentShader);
-+ compileShader(mnRectangularGradientFragmentProgram,
++ radialTwoColorGradientFragmentShader);
++ compileShader(mnRadialMultiColorGradientFragmentProgram,
+ GL_FRAGMENT_SHADER,
-+ rectangularGradientFragmentShader);
-+ linkShaders(mnLinearGradientProgram,
++ radialMultiColorGradientFragmentShader);
++ compileShader(mnRectangularTwoColorGradientFragmentProgram,
++ GL_FRAGMENT_SHADER,
++ rectangularTwoColorGradientFragmentShader);
++ compileShader(mnRectangularMultiColorGradientFragmentProgram,
++ GL_FRAGMENT_SHADER,
++ rectangularMultiColorGradientFragmentShader);
++ linkShaders(mnLinearTwoColorGradientProgram,
++ mnDummyVertexProgram,
++ mnLinearTwoColorGradientFragmentProgram);
++ linkShaders(mnLinearMultiColorGradientProgram,
+ mnDummyVertexProgram,
-+ mnLinearGradientFragmentProgram);
-+ linkShaders(mnRadialGradientProgram,
++ mnLinearMultiColorGradientFragmentProgram);
++ linkShaders(mnRadialTwoColorGradientProgram,
+ mnDummyVertexProgram,
-+ mnRadialGradientFragmentProgram);
-+ linkShaders(mnRectangularGradientProgram,
++ mnRadialTwoColorGradientFragmentProgram);
++ linkShaders(mnRadialMultiColorGradientProgram,
+ mnDummyVertexProgram,
-+ mnRectangularGradientFragmentProgram);
++ mnRadialMultiColorGradientFragmentProgram);
++ linkShaders(mnRectangularTwoColorGradientProgram,
++ mnDummyVertexProgram,
++ mnRectangularTwoColorGradientFragmentProgram);
++ linkShaders(mnRectangularMultiColorGradientProgram,
++ mnDummyVertexProgram,
++ mnRectangularMultiColorGradientFragmentProgram);
+
+ glXMakeCurrent(pDisplay, None, NULL);
+ }
@@ -4019,12 +3955,18 @@ index 0000000..92a0514
+
+ if( mpGLContext )
+ {
-+ glDeleteProgram( mnRectangularGradientProgram );
-+ glDeleteProgram( mnRadialGradientProgram );
-+ glDeleteProgram( mnLinearGradientProgram );
-+ glDeleteShader( mnRectangularGradientFragmentProgram );
-+ glDeleteShader( mnRadialGradientFragmentProgram );
-+ glDeleteShader( mnLinearGradientFragmentProgram );
++ glDeleteProgram( mnRectangularTwoColorGradientProgram );
++ glDeleteProgram( mnRectangularMultiColorGradientProgram );
++ glDeleteProgram( mnRadialTwoColorGradientProgram );
++ glDeleteProgram( mnRadialMultiColorGradientProgram );
++ glDeleteProgram( mnLinearTwoColorGradientProgram );
++ glDeleteProgram( mnLinearMultiColorGradientProgram );
++ glDeleteShader( mnRectangularTwoColorGradientFragmentProgram );
++ glDeleteShader( mnRectangularMultiColorGradientFragmentProgram );
++ glDeleteShader( mnRadialTwoColorGradientFragmentProgram );
++ glDeleteShader( mnRadialMultiColorGradientFragmentProgram );
++ glDeleteShader( mnLinearTwoColorGradientFragmentProgram );
++ glDeleteShader( mnLinearMultiColorGradientFragmentProgram );
+ glDeleteShader( mnDummyVertexProgram );
+
+ glXDestroyContext(reinterpret_cast<unx::Display*>(mpDisplay),
@@ -4295,11 +4237,69 @@ index 0000000..92a0514
+ maActiveSprites.erase(xSprite);
+ }
+
-+ static void setupUniforms( unsigned int nProgramId,
-+ const rendering::ARGBColor& rStartColor,
-+ const rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform )
++ static void setupUniforms( unsigned int nProgramId,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
++ {
++ const GLint nTransformLocation = glGetUniformLocation(nProgramId,
++ "m_transform" );
++ // OGL is column-major
++ float aTexTransform[] =
++ {
++ rTexTransform.get(0,0), rTexTransform.get(1,0),
++ rTexTransform.get(0,1), rTexTransform.get(1,1),
++ rTexTransform.get(0,2), rTexTransform.get(1,2)
++ };
++ glUniformMatrix3x2fv(nTransformLocation,1,false,aTexTransform);
++ }
++
++ static void setupUniforms( unsigned int nProgramId,
++ const rendering::ARGBColor* pColors,
++ const uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
+ {
++ glUseProgram(nProgramId);
++
++ GLuint nColorsTexture;
++ glActiveTexture(GL_TEXTURE0);
++ glGenTextures(1, &nColorsTexture);
++ glBindTexture(GL_TEXTURE_1D, nColorsTexture);
++
++ const sal_Int32 nColors=rStops.getLength();
++ glTexImage1D( GL_TEXTURE_1D, 0, GL_RGBA, nColors, 0, GL_RGBA, GL_DOUBLE, pColors );
++ glTexParameteri( GL_TEXTURE_1D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
++ glTexParameteri( GL_TEXTURE_1D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
++
++ GLuint nStopsTexture;
++ glActiveTexture(GL_TEXTURE1);
++ glGenTextures(1, &nStopsTexture);
++ glBindTexture(GL_TEXTURE_1D, nStopsTexture);
++
++ glTexImage1D( GL_TEXTURE_1D, 0, GL_ALPHA, nColors, 0, GL_ALPHA, GL_DOUBLE, rStops.getConstArray() );
++ glTexParameteri( GL_TEXTURE_1D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
++ glTexParameteri( GL_TEXTURE_1D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
++
++ const GLint nColorArrayLocation = glGetUniformLocation(nProgramId,
++ "t_colorArray4d" );
++ glUniform1i( nColorArrayLocation, 0 ); // unit 0
++
++ const GLint nStopArrayLocation = glGetUniformLocation(nProgramId,
++ "t_stopArray1d" );
++ glUniform1i( nStopArrayLocation, 1 ); // unit 1
++
++ const GLint nNumColorLocation = glGetUniformLocation(nProgramId,
++ "i_nColors" );
++ glUniform1i( nNumColorLocation, nColors-1 );
++
++ setupUniforms(nProgramId,rTexTransform);
++ }
++
++ static void setupUniforms( unsigned int nProgramId,
++ const rendering::ARGBColor& rStartColor,
++ const rendering::ARGBColor& rEndColor,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
++ {
++ glUseProgram(nProgramId);
++
+ const GLint nStartColorLocation = glGetUniformLocation(nProgramId,
+ "v_startColor4d" );
+ glUniform4f(nStartColorLocation,
@@ -4316,43 +4316,37 @@ index 0000000..92a0514
+ rEndColor.Blue,
+ rEndColor.Alpha);
+
-+ const GLint nTransformLocation = glGetUniformLocation(nProgramId,
-+ "m_transform" );
-+ // OGL is column-major
-+ float aTexTransform[] =
-+ {
-+ rTexTransform.get(0,0), rTexTransform.get(1,0),
-+ rTexTransform.get(0,1), rTexTransform.get(1,1),
-+ rTexTransform.get(0,2), rTexTransform.get(1,2)
-+ };
-+ glUniformMatrix3x2fv(nTransformLocation,1,false,aTexTransform);
++ setupUniforms(nProgramId,rTexTransform);
+ }
+
-+ void SpriteDeviceHelper::useLinearGradientShader( const rendering::ARGBColor& rStartColor,
-+ const rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform )
++ void SpriteDeviceHelper::useLinearGradientShader( const rendering::ARGBColor* pColors,
++ const uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
+ {
-+ glUseProgram(mnLinearGradientProgram);
-+
-+ setupUniforms(mnLinearGradientProgram, rStartColor, rEndColor, rTexTransform);
++ if( rStops.getLength() > 2 )
++ setupUniforms(mnLinearMultiColorGradientProgram, pColors, rStops, rTexTransform);
++ else
++ setupUniforms(mnLinearTwoColorGradientProgram, pColors[0], pColors[1], rTexTransform);
+ }
+
-+ void SpriteDeviceHelper::useRadialGradientShader( const rendering::ARGBColor& rStartColor,
-+ const rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform )
++ void SpriteDeviceHelper::useRadialGradientShader( const rendering::ARGBColor* pColors,
++ const uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
+ {
-+ glUseProgram(mnRadialGradientProgram);
-+
-+ setupUniforms(mnLinearGradientProgram, rStartColor, rEndColor, rTexTransform);
++ if( rStops.getLength() > 2 )
++ setupUniforms(mnRadialMultiColorGradientProgram, pColors, rStops, rTexTransform);
++ else
++ setupUniforms(mnRadialTwoColorGradientProgram, pColors[0], pColors[1], rTexTransform);
+ }
+
-+ void SpriteDeviceHelper::useRectangularGradientShader( const rendering::ARGBColor& rStartColor,
-+ const rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform )
++ void SpriteDeviceHelper::useRectangularGradientShader( const rendering::ARGBColor* pColors,
++ const uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform )
+ {
-+ glUseProgram(mnRectangularGradientProgram);
-+
-+ setupUniforms(mnLinearGradientProgram, rStartColor, rEndColor, rTexTransform);
++ if( rStops.getLength() > 2 )
++ setupUniforms(mnRectangularMultiColorGradientProgram, pColors, rStops, rTexTransform);
++ else
++ setupUniforms(mnRectangularTwoColorGradientProgram, pColors[0], pColors[1], rTexTransform);
+ }
+
+ bool SpriteDeviceHelper::activatePBufferContext(const ::basegfx::B2IVector& rSize,
@@ -4494,12 +4488,10 @@ index 0000000..92a0514
+ return *mpTextureCache;
+ }
+}
-diff --git canvas/source/opengl/ogl_spritedevicehelper.hxx canvas/source/opengl/ogl_spritedevicehelper.hxx
-new file mode 100644
-index 0000000..6c02829
---- /dev/null
-+++ canvas/source/opengl/ogl_spritedevicehelper.hxx
-@@ -0,0 +1,176 @@
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_spritedevicehelper.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_spritedevicehelper.hxx Tue Jan 19 22:12:52 2010 +0100
+@@ -0,0 +1,183 @@
+/*************************************************************************
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
@@ -4542,6 +4534,7 @@ index 0000000..6c02829
+ class TextureCache;
+ class SpriteCanvas;
+ class CanvasCustomSprite;
++ class CanvasHelper;
+
+ class SpriteDeviceHelper : private ::boost::noncopyable
+ {
@@ -4602,17 +4595,17 @@ index 0000000..6c02829
+ void hide( const ::rtl::Reference< CanvasCustomSprite >& );
+
+ /// enable linear gradient shader "texture" with given parameters
-+ void useLinearGradientShader( const ::com::sun::star::rendering::ARGBColor& rStartColor,
-+ const ::com::sun::star::rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform );
++ void useLinearGradientShader( const ::com::sun::star::rendering::ARGBColor* pColors,
++ const ::com::sun::star::uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform );
+ /// enable radial gradient shader "texture" with given parameters
-+ void useRadialGradientShader( const ::com::sun::star::rendering::ARGBColor& rStartColor,
-+ const ::com::sun::star::rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform );
++ void useRadialGradientShader( const ::com::sun::star::rendering::ARGBColor* pColors,
++ const ::com::sun::star::uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform );
+ /// enable rectangular gradient shader "texture" with given parameters
-+ void useRectangularGradientShader( const ::com::sun::star::rendering::ARGBColor& rStartColor,
-+ const ::com::sun::star::rendering::ARGBColor& rEndColor,
-+ const ::basegfx::B2DHomMatrix& rTexTransform );
++ void useRectangularGradientShader( const ::com::sun::star::rendering::ARGBColor* pColors,
++ const ::com::sun::star::uno::Sequence< double >& rStops,
++ const ::basegfx::B2DHomMatrix& rTexTransform );
+
+ /// create a pbuffer context (for rendering into background surface)
+ IBufferContextSharedPtr createBufferContext(const ::basegfx::B2IVector& rSize) const;
@@ -4666,21 +4659,25 @@ index 0000000..6c02829
+
+ unsigned int mnDummyVertexProgram;
+
-+ unsigned int mnLinearGradientFragmentProgram;
-+ unsigned int mnRadialGradientFragmentProgram;
-+ unsigned int mnRectangularGradientFragmentProgram;
-+ unsigned int mnLinearGradientProgram;
-+ unsigned int mnRadialGradientProgram;
-+ unsigned int mnRectangularGradientProgram;
++ unsigned int mnLinearTwoColorGradientFragmentProgram;
++ unsigned int mnLinearMultiColorGradientFragmentProgram;
++ unsigned int mnRadialTwoColorGradientFragmentProgram;
++ unsigned int mnRadialMultiColorGradientFragmentProgram;
++ unsigned int mnRectangularTwoColorGradientFragmentProgram;
++ unsigned int mnRectangularMultiColorGradientFragmentProgram;
++ unsigned int mnLinearTwoColorGradientProgram;
++ unsigned int mnLinearMultiColorGradientProgram;
++ unsigned int mnRadialTwoColorGradientProgram;
++ unsigned int mnRadialMultiColorGradientProgram;
++ unsigned int mnRectangularTwoColorGradientProgram;
++ unsigned int mnRectangularMultiColorGradientProgram;
+ };
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_textlayout.cxx canvas/source/opengl/ogl_textlayout.cxx
-new file mode 100644
-index 0000000..87d1a02
---- /dev/null
-+++ canvas/source/opengl/ogl_textlayout.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_textlayout.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_textlayout.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,222 @@
+/*************************************************************************
+ *
@@ -4904,11 +4901,9 @@ index 0000000..87d1a02
+ return true;
+ }
+}
-diff --git canvas/source/opengl/ogl_textlayout.hxx canvas/source/opengl/ogl_textlayout.hxx
-new file mode 100644
-index 0000000..f822a19
---- /dev/null
-+++ canvas/source/opengl/ogl_textlayout.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_textlayout.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_textlayout.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,83 @@
+/*************************************************************************
+ *
@@ -4993,11 +4988,9 @@ index 0000000..f822a19
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_texturecache.cxx canvas/source/opengl/ogl_texturecache.cxx
-new file mode 100644
-index 0000000..07ba85a
---- /dev/null
-+++ canvas/source/opengl/ogl_texturecache.cxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_texturecache.cxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_texturecache.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,132 @@
+/*************************************************************************
+ *
@@ -5131,11 +5124,9 @@ index 0000000..07ba85a
+ return nTexture;
+ }
+}
-diff --git canvas/source/opengl/ogl_texturecache.hxx canvas/source/opengl/ogl_texturecache.hxx
-new file mode 100644
-index 0000000..344e608
---- /dev/null
-+++ canvas/source/opengl/ogl_texturecache.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_texturecache.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_texturecache.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,68 @@
+/*************************************************************************
+ *
@@ -5205,11 +5196,9 @@ index 0000000..344e608
+}
+
+#endif
-diff --git canvas/source/opengl/ogl_tools.hxx canvas/source/opengl/ogl_tools.hxx
-new file mode 100644
-index 0000000..e7575d4
---- /dev/null
-+++ canvas/source/opengl/ogl_tools.hxx
+diff -r 6ae934bd30f5 canvas/source/opengl/ogl_tools.hxx
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/canvas/source/opengl/ogl_tools.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,35 @@
+/*************************************************************************
+ *
@@ -5246,11 +5235,10 @@ index 0000000..e7575d4
+}
+
+#endif
-diff --git canvas/source/tools/canvastools.cxx canvas/source/tools/canvastools.cxx
-index f0fc3e3..7b4b04e 100644
---- canvas/source/tools/canvastools.cxx
-+++ canvas/source/tools/canvastools.cxx
-@@ -434,7 +434,7 @@ namespace canvas
+diff -r 6ae934bd30f5 canvas/source/tools/canvastools.cxx
+--- a/canvas/source/tools/canvastools.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/source/tools/canvastools.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -435,7 +435,7 @@
*pOut++ = vcl::unotools::toDoubleColor(*pIn++);
*pOut++ = vcl::unotools::toDoubleColor(*pIn++);
*pOut++ = vcl::unotools::toDoubleColor(*pIn++);
@@ -5259,7 +5247,7 @@ index f0fc3e3..7b4b04e 100644
}
return aRes;
}
-@@ -499,7 +499,7 @@ namespace canvas
+@@ -500,7 +500,7 @@
for( sal_Size i=0; i<nLen; i+=4 )
{
*pOut++ = rendering::ARGBColor(
@@ -5268,7 +5256,7 @@ index f0fc3e3..7b4b04e 100644
vcl::unotools::toDoubleColor(pIn[0]),
vcl::unotools::toDoubleColor(pIn[1]),
vcl::unotools::toDoubleColor(pIn[2]));
-@@ -520,7 +520,7 @@ namespace canvas
+@@ -521,7 +521,7 @@
rendering::ARGBColor* pOut( aRes.getArray() );
for( sal_Size i=0; i<nLen; i+=4 )
{
@@ -5277,7 +5265,7 @@ index f0fc3e3..7b4b04e 100644
*pOut++ = rendering::ARGBColor(
vcl::unotools::toDoubleColor(nAlpha),
vcl::unotools::toDoubleColor(nAlpha*pIn[0]),
-@@ -561,7 +561,7 @@ namespace canvas
+@@ -562,7 +562,7 @@
*pColors++ = vcl::unotools::toByteColor(pIn->Red);
*pColors++ = vcl::unotools::toByteColor(pIn->Green);
*pColors++ = vcl::unotools::toByteColor(pIn->Blue);
@@ -5286,7 +5274,7 @@ index f0fc3e3..7b4b04e 100644
++pIn;
}
return aRes;
-@@ -579,7 +579,7 @@ namespace canvas
+@@ -580,7 +580,7 @@
*pColors++ = vcl::unotools::toByteColor(pIn->Red/pIn->Alpha);
*pColors++ = vcl::unotools::toByteColor(pIn->Green/pIn->Alpha);
*pColors++ = vcl::unotools::toByteColor(pIn->Blue/pIn->Alpha);
@@ -5295,10 +5283,9 @@ index f0fc3e3..7b4b04e 100644
++pIn;
}
return aRes;
-diff --git canvas/source/vcl/canvashelper.hxx canvas/source/vcl/canvashelper.hxx
-index 30d9677..923d02d 100644
---- canvas/source/vcl/canvashelper.hxx
-+++ canvas/source/vcl/canvashelper.hxx
+diff -r 6ae934bd30f5 canvas/source/vcl/canvashelper.hxx
+--- a/canvas/source/vcl/canvashelper.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/canvas/source/vcl/canvashelper.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -32,6 +32,7 @@
#define _VCLCANVAS_CANVASHELPER_HXX_
@@ -5307,10 +5294,9 @@ index 30d9677..923d02d 100644
#include <com/sun/star/rendering/XIntegerBitmap.hpp>
#include <vcl/outdev.hxx>
-diff --git cppcanvas/inc/cppcanvas/spritecanvas.hxx cppcanvas/inc/cppcanvas/spritecanvas.hxx
-index 287b1a4..9263b54 100644
---- cppcanvas/inc/cppcanvas/spritecanvas.hxx
-+++ cppcanvas/inc/cppcanvas/spritecanvas.hxx
+diff -r 6ae934bd30f5 cppcanvas/inc/cppcanvas/spritecanvas.hxx
+--- a/cppcanvas/inc/cppcanvas/spritecanvas.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/cppcanvas/inc/cppcanvas/spritecanvas.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -38,7 +38,7 @@
#include <boost/shared_ptr.hpp>
@@ -5320,7 +5306,7 @@ index 287b1a4..9263b54 100644
#include <cppcanvas/sprite.hxx>
#include <cppcanvas/customsprite.hxx>
-@@ -59,7 +59,7 @@ namespace cppcanvas
+@@ -59,7 +59,7 @@
/** SpriteCanvas interface
*/
@@ -5329,11 +5315,10 @@ index 287b1a4..9263b54 100644
{
public:
virtual bool updateScreen( bool bUpdateAll ) const = 0;
-diff --git cppcanvas/source/wrapper/implspritecanvas.cxx cppcanvas/source/wrapper/implspritecanvas.cxx
-index 1f66544..3402665 100644
---- cppcanvas/source/wrapper/implspritecanvas.cxx
-+++ cppcanvas/source/wrapper/implspritecanvas.cxx
-@@ -64,8 +64,6 @@ namespace cppcanvas
+diff -r 6ae934bd30f5 cppcanvas/source/wrapper/implspritecanvas.cxx
+--- a/cppcanvas/source/wrapper/implspritecanvas.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/cppcanvas/source/wrapper/implspritecanvas.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -64,8 +64,6 @@
ImplSpriteCanvas::ImplSpriteCanvas( const uno::Reference< rendering::XSpriteCanvas >& rCanvas ) :
ImplCanvas( uno::Reference< rendering::XCanvas >(rCanvas,
uno::UNO_QUERY) ),
@@ -5342,7 +5327,7 @@ index 1f66544..3402665 100644
mxSpriteCanvas( rCanvas ),
mpTransformArbiter( new TransformationArbiter() )
{
-@@ -74,10 +72,8 @@ namespace cppcanvas
+@@ -74,10 +72,8 @@
ImplSpriteCanvas::ImplSpriteCanvas(const ImplSpriteCanvas& rOrig) :
Canvas(),
@@ -5353,10 +5338,9 @@ index 1f66544..3402665 100644
mxSpriteCanvas( rOrig.getUNOSpriteCanvas() ),
mpTransformArbiter( new TransformationArbiter() )
{
-diff --git cppcanvas/source/wrapper/implspritecanvas.hxx cppcanvas/source/wrapper/implspritecanvas.hxx
-index b43e2a9..3909c10 100644
---- cppcanvas/source/wrapper/implspritecanvas.hxx
-+++ cppcanvas/source/wrapper/implspritecanvas.hxx
+diff -r 6ae934bd30f5 cppcanvas/source/wrapper/implspritecanvas.hxx
+--- a/cppcanvas/source/wrapper/implspritecanvas.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/cppcanvas/source/wrapper/implspritecanvas.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -44,14 +44,14 @@
#include <cppcanvas/spritecanvas.hxx>
@@ -5374,45 +5358,9 @@ index b43e2a9..3909c10 100644
{
public:
ImplSpriteCanvas( const ::com::sun::star::uno::Reference<
-diff --git offapi/com/sun/star/presentation/XSlideShowView.idl offapi/com/sun/star/presentation/XSlideShowView.idl
-index a9a3723..935a013 100644
---- offapi/com/sun/star/presentation/XSlideShowView.idl
-+++ offapi/com/sun/star/presentation/XSlideShowView.idl
-@@ -37,9 +37,6 @@
- #ifndef __com_sun_star_rendering_XSpriteCanvas_idl__
- #include <com/sun/star/rendering/XSpriteCanvas.idl>
- #endif
--#ifndef __com_sun_star_geometry_RealRectangle2D_idl__
--#include <com/sun/star/geometry/RealRectangle2D.idl>
--#endif
- #ifndef __com_sun_star_util_XModifyListener_idl__
- #include <com/sun/star/util/XModifyListener.idl>
- #endif
-@@ -52,6 +49,9 @@
- #ifndef __com_sun_star_awt_XMouseMotionListener_idl__
- #include <com/sun/star/awt/XMouseMotionListener.idl>
- #endif
-+#ifndef __com_sun_star_awt_Rectangle_idl__
-+#include <com/sun/star/awt/Rectangle.idl>
-+#endif
-
- module com { module sun { module star { module presentation {
-
-@@ -179,6 +179,10 @@ interface XSlideShowView : ::com::sun::star::uno::XInterface
- */
- void setMouseCursor( [in] short nPointerShape );
-
-+ /** Get rectangle defining area inside of canvas device which
-+ this slideshow view uses.
-+ */
-+ ::com::sun::star::awt::Rectangle getCanvasArea();
- };
-
- }; }; }; };
-diff --git offapi/com/sun/star/rendering/XSpriteCanvas.idl offapi/com/sun/star/rendering/XSpriteCanvas.idl
-index b3717b2..85a3ca8 100644
---- offapi/com/sun/star/rendering/XSpriteCanvas.idl
-+++ offapi/com/sun/star/rendering/XSpriteCanvas.idl
+diff -r 6ae934bd30f5 offapi/com/sun/star/rendering/XSpriteCanvas.idl
+--- a/offapi/com/sun/star/rendering/XSpriteCanvas.idl Mon Jan 18 21:14:50 2010 +0100
++++ b/offapi/com/sun/star/rendering/XSpriteCanvas.idl Tue Jan 19 22:12:52 2010 +0100
@@ -33,7 +33,7 @@
#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
#include <com/sun/star/lang/IllegalArgumentException.idl>
@@ -5422,7 +5370,7 @@ index b3717b2..85a3ca8 100644
#include <com/sun/star/rendering/XBitmapCanvas.idl>
#endif
#ifndef __com_sun_star_rendering_XAnimation_idl__
-@@ -49,7 +49,7 @@ interface XSprite;
+@@ -49,7 +49,7 @@
interface XAnimatedSprite;
interface XCustomSprite;
@@ -5431,7 +5379,7 @@ index b3717b2..85a3ca8 100644
(called sprites) are supported.<p>
@attention The screen output of canvas drawing operations is
-@@ -63,9 +63,9 @@ interface XCustomSprite;
+@@ -63,9 +63,9 @@
(because there's a defined moment in time where content display
can happen, namely the XBufferController::showBuffer()) call. If
you don't need sprite functionality, and don't want the
@@ -5443,7 +5391,7 @@ index b3717b2..85a3ca8 100644
{
/** Create a sprite object from the specified animation
sequence. A sprite is a back-buffered object with its own,
-@@ -117,9 +117,8 @@ interface XSpriteCanvas : XBitmapCanvas
+@@ -117,9 +117,8 @@
object.
The cloned sprite always shows the same content as its
@@ -5455,11 +5403,10 @@ index b3717b2..85a3ca8 100644
@param original
The original sprite to copy the content from. This sprite must
-diff --git officecfg/registry/data/org/openoffice/Office/Canvas.xcu officecfg/registry/data/org/openoffice/Office/Canvas.xcu
-index 40a757d..4bafc24 100755
---- officecfg/registry/data/org/openoffice/Office/Canvas.xcu
-+++ officecfg/registry/data/org/openoffice/Office/Canvas.xcu
-@@ -37,6 +37,7 @@
+diff -r 6ae934bd30f5 officecfg/registry/data/org/openoffice/Office/Canvas.xcu
+--- a/officecfg/registry/data/org/openoffice/Office/Canvas.xcu Mon Jan 18 21:14:50 2010 +0100
++++ b/officecfg/registry/data/org/openoffice/Office/Canvas.xcu Tue Jan 19 22:12:52 2010 +0100
+@@ -52,6 +52,7 @@
<prop oor:name="PreferredImplementations" oor:type="oor:string-list">
<value oor:separator=",">com.sun.star.comp.rendering.SpriteCanvas.DX9,
com.sun.star.comp.rendering.SpriteCanvas.DX5,
@@ -5467,11 +5414,10 @@ index 40a757d..4bafc24 100755
com.sun.star.comp.rendering.SpriteCanvas.Cairo,
com.sun.star.comp.rendering.SpriteCanvas.GL,
com.sun.star.comp.rendering.SpriteCanvas.Java,
-diff --git scp2/source/canvas/makefile.mk scp2/source/canvas/makefile.mk
-index 9bfc24d..6cc5c6e 100644
---- scp2/source/canvas/makefile.mk
-+++ scp2/source/canvas/makefile.mk
-@@ -51,6 +51,7 @@ SCPDEFS+=-DSYSTEM_AGG
+diff -r 6ae934bd30f5 scp2/source/canvas/makefile.mk
+--- a/scp2/source/canvas/makefile.mk Mon Jan 18 21:14:50 2010 +0100
++++ b/scp2/source/canvas/makefile.mk Tue Jan 19 22:12:52 2010 +0100
+@@ -51,6 +51,7 @@
.ENDIF
PARFILES= canvascommons.par \
@@ -5479,11 +5425,9 @@ index 9bfc24d..6cc5c6e 100644
vclcanvas.par
.IF "$(ENABLE_CAIRO)" == "TRUE"
-diff --git scp2/source/canvas/openglcanvas.scp scp2/source/canvas/openglcanvas.scp
-new file mode 100644
-index 0000000..4ea2d47
---- /dev/null
-+++ scp2/source/canvas/openglcanvas.scp
+diff -r 6ae934bd30f5 scp2/source/canvas/openglcanvas.scp
+--- /dev/null Thu Jan 01 00:00:00 1970 +0000
++++ b/scp2/source/canvas/openglcanvas.scp Tue Jan 19 22:12:52 2010 +0100
@@ -0,0 +1,28 @@
+/*************************************************************************
+ *
@@ -5513,11 +5457,10 @@ index 0000000..4ea2d47
+ Name = "oglcanvas.uno.dll";
+ #endif
+End
-diff --git scp2/util/makefile.mk scp2/util/makefile.mk
-index 57652db..9dec807 100644
---- scp2/util/makefile.mk
-+++ scp2/util/makefile.mk
-@@ -167,8 +167,8 @@ SCP1FILES += \
+diff -r 6ae934bd30f5 scp2/util/makefile.mk
+--- a/scp2/util/makefile.mk Mon Jan 18 21:14:50 2010 +0100
++++ b/scp2/util/makefile.mk Tue Jan 19 22:12:52 2010 +0100
+@@ -179,8 +179,8 @@
file_crashrep_dynamic.par
.ENDIF
@@ -5528,11 +5471,10 @@ index 57652db..9dec807 100644
.IF "$(ENABLE_CAIRO)" == "TRUE"
SCP1FILES += cairocanvas.par
-diff --git sd/source/ui/presenter/PresenterCanvas.cxx sd/source/ui/presenter/PresenterCanvas.cxx
-index 7b0302b..d8575df 100644
---- sd/source/ui/presenter/PresenterCanvas.cxx
-+++ sd/source/ui/presenter/PresenterCanvas.cxx
-@@ -809,17 +809,6 @@ sal_Bool SAL_CALL PresenterCanvas::hasAlpha (void)
+diff -r 6ae934bd30f5 sd/source/ui/presenter/PresenterCanvas.cxx
+--- a/sd/source/ui/presenter/PresenterCanvas.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/presenter/PresenterCanvas.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -809,17 +809,6 @@
@@ -5550,10 +5492,9 @@ index 7b0302b..d8575df 100644
Reference<rendering::XBitmap> SAL_CALL PresenterCanvas::getScaledBitmap(
const css::geometry::RealSize2D& rNewSize,
sal_Bool bFast)
-diff --git sd/source/ui/presenter/PresenterCanvas.hxx sd/source/ui/presenter/PresenterCanvas.hxx
-index 8ed05c7..53f002a 100644
---- sd/source/ui/presenter/PresenterCanvas.hxx
-+++ sd/source/ui/presenter/PresenterCanvas.hxx
+diff -r 6ae934bd30f5 sd/source/ui/presenter/PresenterCanvas.hxx
+--- a/sd/source/ui/presenter/PresenterCanvas.hxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/presenter/PresenterCanvas.hxx Tue Jan 19 22:12:52 2010 +0100
@@ -41,6 +41,7 @@
#include <com/sun/star/lang/XInitialization.hpp>
#include <com/sun/star/lang/IllegalArgumentException.hpp>
@@ -5562,7 +5503,7 @@ index 8ed05c7..53f002a 100644
#include <com/sun/star/rendering/VolatileContentDestroyedException.hpp>
#include <cppuhelper/basemutex.hxx>
#include <cppuhelper/compbase4.hxx>
-@@ -387,9 +388,6 @@ public:
+@@ -387,9 +388,6 @@
virtual sal_Bool SAL_CALL hasAlpha (void)
throw (css::uno::RuntimeException);
@@ -5572,22 +5513,20 @@ index 8ed05c7..53f002a 100644
virtual css::uno::Reference<css::rendering::XBitmap> SAL_CALL getScaledBitmap(
const css::geometry::RealSize2D& rNewSize,
sal_Bool bFast)
-diff --git sd/source/ui/presenter/PresenterTextView.cxx sd/source/ui/presenter/PresenterTextView.cxx
-index f9cd42a..9fa3cfc 100644
---- sd/source/ui/presenter/PresenterTextView.cxx
-+++ sd/source/ui/presenter/PresenterTextView.cxx
-@@ -51,6 +51,7 @@
+diff -r 6ae934bd30f5 sd/source/ui/presenter/PresenterTextView.cxx
+--- a/sd/source/ui/presenter/PresenterTextView.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/presenter/PresenterTextView.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -52,6 +52,7 @@
#include <com/sun/star/awt/FontDescriptor.hpp>
#include <com/sun/star/awt/Size.hpp>
#include <com/sun/star/rendering/XSpriteCanvas.hpp>
+#include <com/sun/star/rendering/XBitmapCanvas.hpp>
#include <com/sun/star/util/Color.hpp>
+ #include <com/sun/star/i18n/ScriptType.hpp>
- using namespace ::com::sun::star;
-diff --git sd/source/ui/presenter/SlideRenderer.cxx sd/source/ui/presenter/SlideRenderer.cxx
-index 9145ef2..ff1a17b 100644
---- sd/source/ui/presenter/SlideRenderer.cxx
-+++ sd/source/ui/presenter/SlideRenderer.cxx
+diff -r 6ae934bd30f5 sd/source/ui/presenter/SlideRenderer.cxx
+--- a/sd/source/ui/presenter/SlideRenderer.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/presenter/SlideRenderer.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -34,6 +34,7 @@
#include "SlideRenderer.hxx"
#include "sdpage.hxx"
@@ -5596,29 +5535,25 @@ index 9145ef2..ff1a17b 100644
#include <vos/mutex.hxx>
#include <vcl/svapp.hxx>
#include <cppcanvas/vclfactory.hxx>
-diff --git sd/source/ui/slideshow/slideshowimpl.cxx sd/source/ui/slideshow/slideshowimpl.cxx
-index 0038858..beb4f2d 100644
---- sd/source/ui/slideshow/slideshowimpl.cxx
-+++ sd/source/ui/slideshow/slideshowimpl.cxx
-@@ -1852,7 +1852,12 @@ IMPL_LINK( SlideshowImpl, updateHdl, Timer*, EMPTYARG )
- else
- */
- {
-- const float MIN_UPDATE = 0.05f; // do not wait less than 50 ms
-+ // Avoid busy loop when the previous call to update()
-+ // returns 0. The minimum value is small enough to allow
-+ // high frame rates. Values larger than 0 are typically
-+ // also larger then the small minimum value and thus are
-+ // used to determine the frame rate.
-+ const float MIN_UPDATE = 0.01f; // 10ms corresponds to 100 frames per second.
- if( fUpdate < MIN_UPDATE )
- fUpdate = MIN_UPDATE;
- else
-diff --git sd/source/ui/slideshow/slideshowviewimpl.cxx sd/source/ui/slideshow/slideshowviewimpl.cxx
-index e20921c..f3532bb 100644
---- sd/source/ui/slideshow/slideshowviewimpl.cxx
-+++ sd/source/ui/slideshow/slideshowviewimpl.cxx
-@@ -57,7 +57,6 @@ using ::comphelper::ImplementationReference;
+diff -r 6ae934bd30f5 sd/source/ui/slideshow/slideshowimpl.cxx
+--- a/sd/source/ui/slideshow/slideshowimpl.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/slideshow/slideshowimpl.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -1915,9 +1915,9 @@
+ // returns a small positive number but not 0 (which is
+ // handled above). Also, make sure that calls to update()
+ // have a minimum frequency.
+- // => Allow up to 60 frames per second. Call at least once
++ // => Allow up to 100 frames per second. Call at least once
+ // every 4 seconds.
+- const static sal_Int32 mnMaximumFrameCount (60);
++ const static sal_Int32 mnMaximumFrameCount (100);
+ const static double mnMinimumTimeout (1.0 / mnMaximumFrameCount);
+ const static double mnMaximumTimeout (4.0);
+ fUpdate = ::basegfx::clamp(fUpdate, mnMinimumTimeout, mnMaximumTimeout);
+diff -r 6ae934bd30f5 sd/source/ui/slideshow/slideshowviewimpl.cxx
+--- a/sd/source/ui/slideshow/slideshowviewimpl.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/sd/source/ui/slideshow/slideshowviewimpl.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -59,7 +59,6 @@
using ::rtl::OUString;
using namespace ::com::sun::star;
@@ -5626,169 +5561,65 @@ index e20921c..f3532bb 100644
namespace sd
{
-@@ -487,6 +486,18 @@ void SAL_CALL SlideShowView::setMouseCursor( sal_Int16 nPointerShape ) throw (Ru
- mxWindowPeer->setPointer( mxPointer );
- }
+diff -r 6ae934bd30f5 slideshow/source/engine/slideview.cxx
+--- a/slideshow/source/engine/slideview.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/slideshow/source/engine/slideview.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -898,6 +898,11 @@
+ if( !mxView.is() || !mpCanvas )
+ return;
-+awt::Rectangle SAL_CALL SlideShowView::getCanvasArea( ) throw (RuntimeException)
-+{
-+ awt::Rectangle aRectangle;
-+
-+ if( mxWindow.is() )
-+ return mxWindow->getPosSize();
-+
-+ aRectangle.X = aRectangle.Y = aRectangle.Width = aRectangle.Height = 0;
-+
-+ return aRectangle;
-+}
++ mpCanvas->clear(); // this is unnecessary, strictly speaking. but
++ // it makes the SlideView behave exactly like a
++ // sprite-based SlideViewLayer, because those
++ // are created from scratch after a resize
+
- void SlideShowView::updateimpl( ::osl::ClearableMutexGuard& rGuard, SlideshowImpl* pSlideShow )
- {
- if( pSlideShow )
-diff --git sd/source/ui/slideshow/slideshowviewimpl.hxx sd/source/ui/slideshow/slideshowviewimpl.hxx
-index 4e8f3cc..b68d4e0 100644
---- sd/source/ui/slideshow/slideshowviewimpl.hxx
-+++ sd/source/ui/slideshow/slideshowviewimpl.hxx
-@@ -236,6 +236,7 @@ public:
- virtual void SAL_CALL addMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL removeMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL setMouseCursor( sal_Int16 nPointerShape ) throw (::com::sun::star::uno::RuntimeException);
-+ virtual ::com::sun::star::awt::Rectangle SAL_CALL getCanvasArea( ) throw (::com::sun::star::uno::RuntimeException);
-
- // XWindowListener methods
- virtual void SAL_CALL windowResized( const ::com::sun::star::awt::WindowEvent& e ) throw (::com::sun::star::uno::RuntimeException);
-diff --git sdext/source/presenter/PresenterSlideShowView.cxx sdext/source/presenter/PresenterSlideShowView.cxx
-index 1da7db7..68417a8 100644
---- sdext/source/presenter/PresenterSlideShowView.cxx
-+++ sdext/source/presenter/PresenterSlideShowView.cxx
-@@ -79,6 +79,8 @@ PresenterSlideShowView::PresenterSlideShowView (
- mxPointer(),
- mxWindow(),
- mxViewWindow(),
-+ mxTopPane(),
-+ mxPresenterHelper(),
- mxBackgroundPolygon1(),
- mxBackgroundPolygon2(),
- mbIsViewAdded(false),
-@@ -111,6 +113,13 @@ void PresenterSlideShowView::LateInit (void)
- if (xSlideShowComponent.is())
- xSlideShowComponent->addEventListener(static_cast<awt::XWindowListener*>(this));
+ // clear whole view
+ mxView->clear();
+ }
+@@ -1113,10 +1118,6 @@
+ if( !mpCanvas || !mxView.is())
+ return;
+
+- mpCanvas->clear(); // this is unnecessary, strictly speaking. but
+- // it makes the SlideView behave exactly like a
+- // sprite-based SlideViewLayer, because those
+- // are created from scratch after a resize
+ clearAll();
+ mpCanvas->setTransformation( getTransformation() );
+ mpCanvas->setClip(
+diff -r 6ae934bd30f5 slideshow/source/engine/transitions/slidechangebase.cxx
+--- a/slideshow/source/engine/transitions/slidechangebase.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/slideshow/source/engine/transitions/slidechangebase.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -247,6 +247,7 @@
-+ Reference<lang::XMultiComponentFactory> xFactory (
-+ mxComponentContext->getServiceManager(), UNO_QUERY_THROW);
-+ mxPresenterHelper.set (xFactory->createInstanceWithContext(
-+ OUString::createFromAscii("com.sun.star.comp.Draw.PresenterHelper"),
-+ mxComponentContext),
-+ UNO_QUERY_THROW);
-+
- // Use view id and controller to retrieve window and canvas from
- // configuration controller.
- Reference<XControllerManager> xCM (mxController, UNO_QUERY_THROW);
-@@ -118,6 +127,8 @@ void PresenterSlideShowView::LateInit (void)
+ const SlideBitmapSharedPtr pSlideBitmap( getEnteringBitmap( *aCurr ));
+ pSlideBitmap->clip( basegfx::B2DPolyPolygon() /* no clipping */ );
++ aCurr->mpView->clearAll();
+ renderBitmap( pSlideBitmap,
+ aCurr->mpView->getCanvas() );
- if (xCC.is())
+diff -r 6ae934bd30f5 slideshow/source/engine/transitions/slidetransitionfactory.cxx
+--- a/slideshow/source/engine/transitions/slidetransitionfactory.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/slideshow/source/engine/transitions/slidetransitionfactory.cxx Tue Jan 19 22:12:52 2010 +0100
+@@ -562,6 +562,7 @@
+ if (mbFirstPerformCall && maLeavingDirection.equalZero())
{
-+ mxTopPane.set(xCC->getResource(mxViewId->getAnchor()->getAnchor()), UNO_QUERY);
-+
- Reference<XPane> xPane (xCC->getResource(mxViewId->getAnchor()), UNO_QUERY_THROW);
-
- mxWindow = xPane->getWindow();
-@@ -139,8 +150,8 @@ void PresenterSlideShowView::LateInit (void)
- // Create a window for the actual slide show view. It is places
- // centered and with maximal size inside the pane.
- mxViewWindow = CreateViewWindow(mxWindow);
-- mxViewCanvas = CreateViewCanvas(mxViewWindow,
-- Reference<XPane>(xCC->getResource(mxViewId->getAnchor()->getAnchor()), UNO_QUERY));
-+
-+ mxViewCanvas = CreateViewCanvas(mxViewWindow);
-
- if (mxViewWindow.is())
+ mbFirstPerformCall = false;
++ rViewEntry.mpView->clearAll();
+ renderBitmap( getLeavingBitmap(rViewEntry), rDestinationCanvas );
+ }
+
+@@ -600,6 +601,7 @@
+ if (mbFirstPerformCall && maEnteringDirection.equalZero())
{
-@@ -540,6 +551,19 @@ void SAL_CALL PresenterSlideShowView::setMouseCursor(::sal_Int16 nPointerShape)
-
-
-
-+awt::Rectangle SAL_CALL PresenterSlideShowView::getCanvasArea( ) throw (RuntimeException)
-+{
-+ if( mxViewWindow.is() && mxTopPane.is() )
-+ return mxPresenterHelper->getWindowExtentsRelative( mxViewWindow, mxTopPane->getWindow() );
-+
-+ awt::Rectangle aRectangle;
-+
-+ aRectangle.X = aRectangle.Y = aRectangle.Width = aRectangle.Height = 0;
-+
-+ return aRectangle;
-+}
-+
-+
-
- //----- lang::XEventListener --------------------------------------------------
-
-@@ -973,22 +997,14 @@ Reference<awt::XWindow> PresenterSlideShowView::CreateViewWindow (
-
-
- Reference<rendering::XCanvas> PresenterSlideShowView::CreateViewCanvas (
-- const Reference<awt::XWindow>& rxViewWindow,
-- const Reference<XPane>& rxParentPane) const
-+ const Reference<awt::XWindow>& rxViewWindow) const
- {
- // Create a canvas for the view window.
-- Reference<lang::XMultiComponentFactory> xFactory (
-- mxComponentContext->getServiceManager(), UNO_QUERY_THROW);
-- Reference<drawing::XPresenterHelper> xPresenterHelper(
-- xFactory->createInstanceWithContext(
-- OUString::createFromAscii("com.sun.star.comp.Draw.PresenterHelper"),
-- mxComponentContext),
-- UNO_QUERY_THROW);
-- return xPresenterHelper->createSharedCanvas(
-- Reference<rendering::XSpriteCanvas>(rxParentPane->getCanvas(), UNO_QUERY),
-- rxParentPane->getWindow(),
-- rxParentPane->getCanvas(),
-- rxParentPane->getWindow(),
-+ return mxPresenterHelper->createSharedCanvas(
-+ Reference<rendering::XSpriteCanvas>(mxTopPane->getCanvas(), UNO_QUERY),
-+ mxTopPane->getWindow(),
-+ mxTopPane->getCanvas(),
-+ mxTopPane->getWindow(),
- rxViewWindow);
- }
-
-diff --git sdext/source/presenter/PresenterSlideShowView.hxx sdext/source/presenter/PresenterSlideShowView.hxx
-index 0270752..145a6d3 100644
---- sdext/source/presenter/PresenterSlideShowView.hxx
-+++ sdext/source/presenter/PresenterSlideShowView.hxx
-@@ -149,6 +149,8 @@ public:
- virtual void SAL_CALL setMouseCursor(::sal_Int16 nPointerShape)
- throw (css::uno::RuntimeException);
-
-+ virtual ::com::sun::star::awt::Rectangle SAL_CALL getCanvasArea( )
-+ throw (::com::sun::star::uno::RuntimeException);
+ mbFirstPerformCall = false;
++ rViewEntry.mpView->clearAll();
+ renderBitmap( getEnteringBitmap(rViewEntry), rDestinationCanvas );
+ }
- // lang::XEventListener
- virtual void SAL_CALL disposing (const css::lang::EventObject& rEvent)
-@@ -236,6 +238,8 @@ private:
- css::uno::Reference<css::awt::XPointer> mxPointer;
- css::uno::Reference<css::awt::XWindow> mxWindow;
- css::uno::Reference<css::awt::XWindow> mxViewWindow;
-+ css::uno::Reference<css::drawing::framework::XPane> mxTopPane;
-+ css::uno::Reference<css::drawing::XPresenterHelper> mxPresenterHelper;
- css::uno::Reference<css::rendering::XPolyPolygon2D> mxBackgroundPolygon1;
- css::uno::Reference<css::rendering::XPolyPolygon2D> mxBackgroundPolygon2;
- bool mbIsViewAdded;
-@@ -267,8 +271,7 @@ private:
- css::uno::Reference<css::awt::XWindow> CreateViewWindow (
- const css::uno::Reference<css::awt::XWindow>& rxParentWindow) const;
- css::uno::Reference<css::rendering::XCanvas> CreateViewCanvas (
-- const css::uno::Reference<css::awt::XWindow>& rxWindow,
-- const css::uno::Reference<css::drawing::framework::XPane>& rxParentPane) const;
-+ const css::uno::Reference<css::awt::XWindow>& rxWindow) const;
-
- void Resize (void);
-
-diff --git slideshow/source/engine/waitsymbol.cxx slideshow/source/engine/waitsymbol.cxx
-index 4dafb23..ecd8442 100644
---- slideshow/source/engine/waitsymbol.cxx
-+++ slideshow/source/engine/waitsymbol.cxx
+diff -r 6ae934bd30f5 slideshow/source/engine/waitsymbol.cxx
+--- a/slideshow/source/engine/waitsymbol.cxx Mon Jan 18 21:14:50 2010 +0100
++++ b/slideshow/source/engine/waitsymbol.cxx Tue Jan 19 22:12:52 2010 +0100
@@ -41,6 +41,7 @@
#include <basegfx/vector/b2dvector.hxx>
@@ -5797,7 +5628,7 @@ index 4dafb23..ecd8442 100644
#include "waitsymbol.hxx"
#include "eventmultiplexer.hxx"
-@@ -115,13 +116,13 @@ void WaitSymbol::setVisible( const bool bVisible )
+@@ -115,13 +116,13 @@
basegfx::B2DPoint WaitSymbol::calcSpritePos(
UnoViewSharedPtr const & rView ) const
{
More information about the ooo-build-commit
mailing list