Closed
Bug 740252
Opened 12 years ago
Closed 12 years ago
EventListenerManager disables various things in RemoveEventListener even if there can be still listeners
Categories
(Core :: DOM: Events, defect)
Tracking
()
RESOLVED
FIXED
mozilla14
People
(Reporter: smaug, Assigned: dougt)
References
Details
Attachments
(1 file, 4 obsolete files)
4.59 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
One shouldn't call window->Disable* if there are still listeners for those features.
Reporter | ||
Comment 1•12 years ago
|
||
Oh, and coding style is if (expr) { stmt; }
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → doug.turner
Comment 3•12 years ago
|
||
Is this enough to fix the bug?
Assignee: doug.turner → jwein
Attachment #610441 -
Flags: feedback?(bugs)
Updated•12 years ago
|
Assignee: jwein → doug.turner
Updated•12 years ago
|
Attachment #610441 -
Attachment is obsolete: true
Attachment #610441 -
Flags: feedback?(bugs)
Assignee | ||
Comment 4•12 years ago
|
||
style improvements.
Attachment #610439 -
Attachment is obsolete: true
Attachment #610439 -
Flags: review?(bugs)
Attachment #610453 -
Flags: review?(bugs)
Assignee | ||
Comment 5•12 years ago
|
||
Attachment #610453 -
Attachment is obsolete: true
Attachment #610453 -
Flags: review?(bugs)
Attachment #610461 -
Flags: review?(bugs)
Assignee | ||
Comment 6•12 years ago
|
||
Attachment #610461 -
Attachment is obsolete: true
Attachment #610461 -
Flags: review?(bugs)
Attachment #610464 -
Flags: review?(bugs)
Reporter | ||
Comment 7•12 years ago
|
||
Comment on attachment 610464 [details] [diff] [review] patch v.3 >+nsEventListenerManager::DisableDevice(PRUint32 aType) >+{ >+ nsPIDOMWindow* window = GetInnerWindowForTarget(); >+ if (!window) { >+ return; >+ } >+ if (aType == NS_DEVICE_ORIENTATION) { >+ window->DisableDeviceSensor(SENSOR_ORIENTATION); >+ } else if (aType == NS_DEVICE_MOTION) { >+ window->DisableDeviceSensor(SENSOR_ACCELERATION); >+ window->DisableDeviceSensor(SENSOR_LINEAR_ACCELERATION); >+ window->DisableDeviceSensor(SENSOR_GYROSCOPE); >+ } >+} This could also use switch-case
Attachment #610464 -
Flags: review?(bugs) → review+
Comment 8•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/c85e435f8041
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla14
You need to log in
before you can comment on or make changes to this bug.
Description
•