summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-12-13 12:05:19 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2014-01-29 08:09:19 +0100
commit7a24673115ca7492c3176034321f6beb77576b7d (patch)
tree0774f4af6ad7a1358e63b770369016d47d9c0db1 /include
parentI give up on patching glm (diff)
downloadcore-7a24673115ca7492c3176034321f6beb77576b7d.tar.gz
core-7a24673115ca7492c3176034321f6beb77576b7d.zip
add ugly hack to work around SvxDrawPage::add only accepting SvxShape
Change-Id: I77c292b088a1a1797fba10cc514167a1f3dca917
Diffstat (limited to 'include')
-rw-r--r--include/svx/unoshape.hxx23
1 files changed, 23 insertions, 0 deletions
diff --git a/include/svx/unoshape.hxx b/include/svx/unoshape.hxx
index 538bc130639f..ce78e2aa90b6 100644
--- a/include/svx/unoshape.hxx
+++ b/include/svx/unoshape.hxx
@@ -875,6 +875,29 @@ private:
OUString referer_;
};
+/*
+ * This is a really ugly hack for the chart2 OpenGL backend
+ * SvxShapeGroup::add only accepts objects derived from SvxShape and silently drops
+ * other objects. This fixes my life time problems but I will burn for it in hell.
+ *
+ * The object does nothing and should not be painted. It is just there to ensure that the
+ * wrapped object is not deleted prematurely.
+ */
+class SVX_DLLPUBLIC SvxDummyShapeContainer : public SvxShape
+{
+private:
+ com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >
+ m_xDummyObject;
+
+public:
+ SvxDummyShapeContainer( com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > xWrappedObject );
+ virtual ~SvxDummyShapeContainer() throw();
+
+ com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > getWrappedShape()
+ { return m_xDummyObject; }
+
+};
+
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */