summaryrefslogtreecommitdiff
path: root/include/vcl/vclevent.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-06-20 15:56:35 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-06-23 06:28:00 +0000
commitaa0d0536a444fb26d9e570bd6bf6c1bdc3596cf3 (patch)
tree8b2a5207e77fa4054a37b33c25378c23a00af8ed /include/vcl/vclevent.hxx
parentb722f3d6fc72877e8caaaae7291d5d736ddc494d (diff)
tdf#97527 - vcl: reference-count Menu
some places are marked with "dodgy"- need to check those to see what is going on, because they are leaving dangling pointers behind in the Menu class Change-Id: I41d5c7c0fec2f70ce9e3ffdc48cd03d26c0a869b Reviewed-on: https://gerrit.libreoffice.org/26516 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'include/vcl/vclevent.hxx')
-rw-r--r--include/vcl/vclevent.hxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/vcl/vclevent.hxx b/include/vcl/vclevent.hxx
index 83bcd5721009..b37605428ab5 100644
--- a/include/vcl/vclevent.hxx
+++ b/include/vcl/vclevent.hxx
@@ -222,14 +222,14 @@ public:
class VCL_DLLPUBLIC VclMenuEvent : public VclSimpleEvent
{
private:
- Menu* pMenu;
+ VclPtr<Menu> pMenu;
sal_uInt16 mnPos;
public:
- VclMenuEvent( Menu* pM, sal_uLong n, sal_uInt16 nPos ) : VclSimpleEvent(n) { pMenu = pM; mnPos = nPos; }
- virtual ~VclMenuEvent() {}
+ VclMenuEvent( Menu* pM, sal_uLong n, sal_uInt16 nPos );
+ virtual ~VclMenuEvent();
- Menu* GetMenu() const { return pMenu; }
+ Menu* GetMenu() const;
sal_uInt16 GetItemPos() const { return mnPos; }
};