summaryrefslogtreecommitdiff
path: root/slideshow/source/inc
diff options
context:
space:
mode:
authorthb <thb@openoffice.org>2010-02-19 12:46:18 +0100
committerthb <thb@openoffice.org>2010-02-19 12:46:18 +0100
commit542222f04c17b7534d34c79d40d609b8eb6ec2fd (patch)
treed7a75d99f87a9b3dd7dafc197531df167773d9a2 /slideshow/source/inc
parentfc69c9694e7e10309aee1015107e4ef279e31474 (diff)
parent02f1b698feb68c70166be96eae9f557fbf076ac2 (diff)
Merged with dev300_m71
Diffstat (limited to 'slideshow/source/inc')
-rw-r--r--slideshow/source/inc/eventmultiplexer.hxx27
-rw-r--r--slideshow/source/inc/rgbcolor.hxx3
-rw-r--r--slideshow/source/inc/shapeimporter.hxx22
-rw-r--r--slideshow/source/inc/slide.hxx47
-rw-r--r--slideshow/source/inc/tools.hxx3
-rw-r--r--slideshow/source/inc/userpainteventhandler.hxx6
6 files changed, 86 insertions, 22 deletions
diff --git a/slideshow/source/inc/eventmultiplexer.hxx b/slideshow/source/inc/eventmultiplexer.hxx
index 303ae4dda898..a1c932252d7b 100644
--- a/slideshow/source/inc/eventmultiplexer.hxx
+++ b/slideshow/source/inc/eventmultiplexer.hxx
@@ -486,6 +486,33 @@ public:
*/
bool notifyUserPaintColor( RGBColor const& rUserColor );
+ /** Notify a new user paint width
+
+ Sending this notification also implies that user paint is
+ enabled. .
+
+ @return true, if this event was processed by
+ anybody. If false is returned, no handler processed
+ this event (and probably, nothing will happen at all)
+ */
+ bool notifyUserPaintStrokeWidth( double rUserStrokeWidth );
+
+
+ /** Notify a new user paint erase all ink mode
+
+ Sending this notification also implies that user paint is
+ enabled. User paint denotes the feature to draw colored lines
+ on top of the slide content.
+
+ @return true, if this event was processed by
+ anybody. If false is returned, no handler processed
+ this event (and probably, nothing will happen at all)
+ */
+ bool notifyEraseAllInk( bool const& rEraseAllInk );
+ bool notifySwitchPenMode();
+ bool notifySwitchEraserMode();
+ bool notifyEraseInkWidth( sal_Int32 rEraseInkSize );
+
/** Notify that user paint is disabled
User paint denotes the feature to draw colored lines on top of
diff --git a/slideshow/source/inc/rgbcolor.hxx b/slideshow/source/inc/rgbcolor.hxx
index 1ea168ee80c3..73f14558b494 100644
--- a/slideshow/source/inc/rgbcolor.hxx
+++ b/slideshow/source/inc/rgbcolor.hxx
@@ -90,6 +90,9 @@ namespace slideshow
*/
::cppcanvas::Color::IntSRGBA getIntegerColor() const;
+ RGBColor(const RGBColor& rLHS);
+ RGBColor& operator=( const RGBColor& rLHS);
+
struct RGBTriple
{
RGBTriple();
diff --git a/slideshow/source/inc/shapeimporter.hxx b/slideshow/source/inc/shapeimporter.hxx
index d5e95ac45568..6b3ff7eb2057 100644
--- a/slideshow/source/inc/shapeimporter.hxx
+++ b/slideshow/source/inc/shapeimporter.hxx
@@ -33,6 +33,9 @@
#include <com/sun/star/drawing/XDrawPage.hpp>
#include <com/sun/star/drawing/XShapes.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/drawing/XLayer.hpp>
+#include "unoviewcontainer.hxx"
+#include "unoview.hxx"
#include "shape.hxx"
@@ -43,6 +46,10 @@ namespace internal {
struct SlideShowContext;
+typedef ::std::vector< ::cppcanvas::PolyPolygonSharedPtr> PolyPolygonVector;
+typedef ::boost::shared_ptr< UnoView > UnoViewSharedPtr;
+typedef ::std::vector< UnoViewSharedPtr > UnoViewVector;
+
/** This class imports all shapes from a given XShapes object
*/
class ShapeImporter
@@ -75,6 +82,8 @@ public:
::com::sun::star::drawing::XDrawPage >& xPage,
const ::com::sun::star::uno::Reference<
::com::sun::star::drawing::XDrawPage >& xActualPage,
+ const ::com::sun::star::uno::Reference<
+ ::com::sun::star::drawing::XDrawPagesSupplier>& xPagesSupplier,
const SlideShowContext& rContext,
sal_Int32 nOrdNumStart,
bool bConvertingMasterPage );
@@ -95,11 +104,13 @@ public:
importShape() call.
*/
bool isImportDone() const;
-
+ PolyPolygonVector getPolygons();
private:
bool isSkip( ::com::sun::star::uno::Reference<
::com::sun::star::beans::XPropertySet> const& xPropSet,
- ::rtl::OUString const& shapeType ) const;
+ ::rtl::OUString const& shapeType,
+ ::com::sun::star::uno::Reference<
+ ::com::sun::star::drawing::XLayer> const& xLayer);
ShapeSharedPtr createShape(
::com::sun::star::uno::Reference<
@@ -108,6 +119,8 @@ private:
::com::sun::star::beans::XPropertySet> const& xPropSet,
::rtl::OUString const& shapeType ) const;
+ void importPolygons(::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > const& xPropSet) ;
+
struct XShapesEntry
{
ShapeSharedPtr const mpGroupShape;
@@ -130,10 +143,11 @@ private:
::com::sun::star::uno::Reference<
::com::sun::star::drawing::XDrawPage> mxPage;
+ ::com::sun::star::uno::Reference<
+ ::com::sun::star::drawing::XDrawPagesSupplier> mxPagesSupplier;
const SlideShowContext& mrContext;
-
+ PolyPolygonVector maPolygons;
XShapesStack maShapesStack;
-
double mnAscendingPrio;
bool mbConvertingMasterPage;
};
diff --git a/slideshow/source/inc/slide.hxx b/slideshow/source/inc/slide.hxx
index 90cc7cf6d1b1..9a467c164a96 100644
--- a/slideshow/source/inc/slide.hxx
+++ b/slideshow/source/inc/slide.hxx
@@ -42,6 +42,7 @@
namespace com { namespace sun { namespace star {
namespace drawing {
class XDrawPage;
+ class XDrawPagesSupplier;
}
namespace uno {
class XComponentContext;
@@ -63,7 +64,7 @@ namespace slideshow
{
class RGBColor;
class ScreenUpdater;
-
+ typedef ::std::vector< ::cppcanvas::PolyPolygonSharedPtr> PolyPolygonVector;
class Slide
{
public:
@@ -117,6 +118,14 @@ namespace slideshow
virtual ::com::sun::star::uno::Reference<
::com::sun::star::animations::XAnimationNode > getXAnimationNode() const = 0;
+ ///Gets the slide Polygons
+ virtual PolyPolygonVector getPolygons() = 0;
+
+ ///Draw the slide Polygons
+ virtual void drawPolygons() const = 0;
+
+ ///Check if slide is already active
+ virtual bool isPaintOverlayActive() const = 0;
// Slide bitmaps
// -------------------------------------------------------------------
@@ -183,24 +192,28 @@ namespace slideshow
UserEeventQueue
*/
SlideSharedPtr createSlide( const ::com::sun::star::uno::Reference<
- ::com::sun::star::drawing::XDrawPage >& xDrawPage,
+ ::com::sun::star::drawing::XDrawPage >& xDrawPage,
+ const ::com::sun::star::uno::Reference<
+ ::com::sun::star::drawing::XDrawPagesSupplier >& xDrawPages,
const ::com::sun::star::uno::Reference<
- ::com::sun::star::animations::XAnimationNode >& xRootNode,
- EventQueue& rEventQueue,
- EventMultiplexer& rEventMultiplexer,
- ScreenUpdater& rScreenUpdater,
- ActivitiesQueue& rActivitiesQueue,
- UserEventQueue& rUserEventQueue,
- CursorManager& rCursorManager,
- const UnoViewContainer& rViewContainer,
+ ::com::sun::star::animations::XAnimationNode >& xRootNode,
+ EventQueue& rEventQueue,
+ EventMultiplexer& rEventMultiplexer,
+ ScreenUpdater& rScreenUpdater,
+ ActivitiesQueue& rActivitiesQueue,
+ UserEventQueue& rUserEventQueue,
+ CursorManager& rCursorManager,
+ const UnoViewContainer& rViewContainer,
const ::com::sun::star::uno::Reference<
- ::com::sun::star::uno::XComponentContext >& xContext,
- const ShapeEventListenerMap& rShapeListenerMap,
- const ShapeCursorMap& rShapeCursorMap,
- RGBColor const& aUserPaintColor,
- bool bUserPaintEnabled,
- bool bIntrinsicAnimationsAllowed,
- bool bDisableAnimationZOrder );
+ ::com::sun::star::uno::XComponentContext >& xContext,
+ const ShapeEventListenerMap& rShapeListenerMap,
+ const ShapeCursorMap& rShapeCursorMap,
+ const PolyPolygonVector& rPolyPolygonVector,
+ RGBColor const& aUserPaintColor,
+ double dUserPaintStrokeWidth,
+ bool bUserPaintEnabled,
+ bool bIntrinsicAnimationsAllowed,
+ bool bDisableAnimationZOrder );
}
}
diff --git a/slideshow/source/inc/tools.hxx b/slideshow/source/inc/tools.hxx
index bb10864419cb..71d2aae74fc1 100644
--- a/slideshow/source/inc/tools.hxx
+++ b/slideshow/source/inc/tools.hxx
@@ -289,6 +289,9 @@ namespace slideshow
/** Convert a plain UNO API 32 bit int to RGBColor
*/
RGBColor unoColor2RGBColor( sal_Int32 );
+ /** Convert an IntSRGBA to plain UNO API 32 bit int
+ */
+ sal_Int32 RGBAColor2UnoColor( cppcanvas::Color::IntSRGBA );
/** Fill a plain rectangle on the given canvas with the given color
*/
diff --git a/slideshow/source/inc/userpainteventhandler.hxx b/slideshow/source/inc/userpainteventhandler.hxx
index c688af984197..01919e0ae7e0 100644
--- a/slideshow/source/inc/userpainteventhandler.hxx
+++ b/slideshow/source/inc/userpainteventhandler.hxx
@@ -51,8 +51,12 @@ namespace slideshow
{
public:
virtual ~UserPaintEventHandler() {}
-
virtual bool colorChanged( RGBColor const& rUserColor ) = 0;
+ virtual bool widthChanged( double nUserStrokeWidth ) = 0;
+ virtual bool eraseAllInkChanged(bool const& rEraseAllInk) =0;
+ virtual bool eraseInkWidthChanged(sal_Int32 rEraseInkSize) =0;
+ virtual bool switchEraserMode() = 0;
+ virtual bool switchPenMode() = 0;
virtual bool disable() = 0;
};