summaryrefslogtreecommitdiff
path: root/include/vcl/menu.hxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-05-07 11:49:46 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-05-07 11:49:46 +0200
commit93f5d5a9190e0e03bf4822663652a4b068c44f75 (patch)
tree9ac61601b056acad6a6c83d728c684661d3f3271 /include/vcl/menu.hxx
parentc6fdd34c16f415629222348631141c3e13af6d4a (diff)
The opaque PostUserEvent IDs are actually pointers
...so declare them as such. This avoids the recurring mistake of storing such IDs as sal_uInt32, truncating in 64 bit environments, causing RemoveUserEvent to potentially not remove the event, it thus firing "too late" and probably causing a crash. While at it, consolidate the trivially unnecessary overloads of both Application::PostUserEvent and Window::PostUserEvent. And in each of them, it looks like deleting the mpLink member was missing from the failure branch. Change-Id: Iab13afbb06e12ac15dec6a6b5b85a7e402a3c654
Diffstat (limited to 'include/vcl/menu.hxx')
-rw-r--r--include/vcl/menu.hxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index 10ac7889e3b1..9f31b20421cf 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -30,6 +30,7 @@
#include <vcl/vclevent.hxx>
#include <com/sun/star/uno/Reference.hxx>
+struct ImplSVEvent;
struct MenuItemData;
class Point;
class Size;
@@ -128,7 +129,7 @@ private:
OUString aTitleText; // PopupMenu text
- sal_uLong nEventId;
+ ImplSVEvent * nEventId;
sal_uInt16 mnHighlightedItemPos; // for native menus: keeps track of the highlighted item
sal_uInt16 nMenuFlags;
sal_uInt16 nDefaultItem; // Id of default item