summaryrefslogtreecommitdiff
path: root/svx/inc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-04-13 09:26:12 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-04-13 10:28:00 +0100
commitf17489f80020dfd7a9de66c0d580dcf23f7d3c09 (patch)
tree1e02138d914507e5fc84b8883e5ffcb510063404 /svx/inc
parent291ec5e9708352a1d98c54814dad8db7ce38fdb9 (diff)
ofz: fix leak
this is still an ugly beast, but at least its new/delete on the same type now Change-Id: I7560eb30c2a43f2cf56a956144fbec66d7d163a6
Diffstat (limited to 'svx/inc')
-rw-r--r--svx/inc/sdr/properties/itemsettools.hxx8
1 files changed, 6 insertions, 2 deletions
diff --git a/svx/inc/sdr/properties/itemsettools.hxx b/svx/inc/sdr/properties/itemsettools.hxx
index cef08ef4907f..0e1f760e0777 100644
--- a/svx/inc/sdr/properties/itemsettools.hxx
+++ b/svx/inc/sdr/properties/itemsettools.hxx
@@ -21,6 +21,7 @@
#define INCLUDED_SVX_INC_SDR_PROPERTIES_ITEMSETTOOLS_HXX
#include <sal/types.h>
+#include <vcl/region.hxx>
class SdrObject;
class SfxItemSet;
@@ -34,14 +35,17 @@ namespace sdr
{
class ItemChangeBroadcaster
{
- sal_uInt32 mnCount;
+ bool mbSingleRect;
void* mpData;
public:
explicit ItemChangeBroadcaster(const SdrObject& rObj);
~ItemChangeBroadcaster();
- sal_uInt32 GetRectangleCount() const { return mnCount; }
+ sal_uInt32 GetRectangleCount() const
+ {
+ return mbSingleRect ? 1 : static_cast<RectangleVector*>(mpData)->size();
+ }
const tools::Rectangle& GetRectangle(sal_uInt32 nIndex) const;
};
} // end of namespace properties