Closed Bug 600406 Opened 14 years ago Closed 12 years ago

rollup event consuming behavior is non-deterministic

Categories

(Core :: Widget: Cocoa, defect)

defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: Gavin, Unassigned)

References

Details

gConsumeRollupEvent in nsCocoaWindow.mm is not initialized, so whether or not we consume rollup events on Mac for a given popup is random, unless it's explicitly specified (via setConsumeRollupEvent).
Blocks: 415440
Summary: default rollup event consuming is non-deterministic → default rollup event consuming behavior depends the value of uninitialized memory
Actually, I may have misdiagnosed this. Initializing it doesn't seem to help - I still seem to see seemingly-random behavior. Need to investigate more.
Summary: default rollup event consuming behavior depends the value of uninitialized memory → rollup event consuming behavior is non-deterministic
My test case is http://gavinsharp.com/tmp/geo.html . It triggers a popup notification, and clicking the link while the popup is up let's you see whether the event is consumed. If I reload and click continuously, I occasionally get the event consumed, and occasionally don't.
When the event isn't consumed, ConsumeOutsideClicks() returns false because mConsumeRollupEvent == nsIPopupBoxObject::ROLLUP_NO_CONSUME.

When it is consumed, ConsumeOutsideClicks() returns true because (mConsumeRollupEvent == nsIPopupBoxObject::ROLLUP_DEFAULT), and none of the special cases are hit.
It looks like rollups where the event is consumed are always preceded by rollups where we don't get into the if (shouldRollup) block in maybeRollup.
Some changes have been made to the rollup code recently for bug 701760 to is this still a problem? I cannot reproduce.
Flags: needinfo?(gavin.sharp)
I can't reproduce this anymore.
Status: NEW → RESOLVED
Closed: 12 years ago
Flags: needinfo?(gavin.sharp)
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.