summaryrefslogtreecommitdiffstats
path: root/widget/cocoa/MOZMenuOpeningCoordinator.mm
diff options
context:
space:
mode:
Diffstat (limited to 'widget/cocoa/MOZMenuOpeningCoordinator.mm')
-rw-r--r--widget/cocoa/MOZMenuOpeningCoordinator.mm3
1 files changed, 3 insertions, 0 deletions
diff --git a/widget/cocoa/MOZMenuOpeningCoordinator.mm b/widget/cocoa/MOZMenuOpeningCoordinator.mm
index 3ac4d8385f..bc78b3778c 100644
--- a/widget/cocoa/MOZMenuOpeningCoordinator.mm
+++ b/widget/cocoa/MOZMenuOpeningCoordinator.mm
@@ -122,6 +122,9 @@ static BOOL sNeedToUnwindForMenuClosing = NO;
- (void)cancelAsynchronousOpening:(NSInteger)aHandle {
if (mPendingOpening && mPendingOpening.handle == aHandle) {
+ [NSObject cancelPreviousPerformRequestsWithTarget:self
+ selector:@selector(_runMenu)
+ object:nil];
[mPendingOpening release];
mPendingOpening = nil;
}