Closed
Bug 500214
Opened 15 years ago
Closed 15 years ago
tabbrowser.xml and browser-tabPreviews.js use mutation event listeners
Categories
(Firefox :: Tabbed Browser, defect)
Firefox
Tabbed Browser
Tracking
()
VERIFIED
FIXED
Firefox 3.7a1
People
(Reporter: smaug, Assigned: dao)
References
(Blocks 1 open bug)
Details
(Keywords: dev-doc-complete, perf)
Attachments
(1 file)
(deleted),
patch
|
vlad
:
review+
mconnor
:
superreview+
|
Details | Diff | Splinter Review |
Using mutation event listeners slows down all the dom mutations in the document they are used. We should try to avoid them in chrome.
Assignee | ||
Comment 1•15 years ago
|
||
The event listeners are only added when the ctrl-tab panel opens and removed when it closes. Is that really a problem?
Reporter | ||
Comment 2•15 years ago
|
||
Currently just adding a mutation listener sets a flag to the window object, which
triggers checks for the particular mutation event.
Removing listener doesn't remove the flag.
We could fix that by using a counter and not a flag, but not sure if it is
really worth it.
Would it be possible to change tabPreviews to not to use mutation events?
Assignee | ||
Comment 3•15 years ago
|
||
It's certainly possible, but it seems like a non-trivial task, and it would duplicate the existing infrastructure that updates the tab attributes.
Updated•15 years ago
|
Reporter | ||
Comment 4•15 years ago
|
||
(In reply to comment #2)
> We could fix that by using a counter and not a flag, but not sure if it is
> really worth it.
And this is certainly not trivial way to fix this bug.
Blocks: 465076
Flags: blocking-firefox3.6?
Assignee | ||
Comment 5•15 years ago
|
||
Note that the legacy all tabs popup also uses mutation events, and did so for ages.
Reporter | ||
Comment 6•15 years ago
|
||
Ah, perhaps this shouldn't then block 3.6. But should be fixed anyway.
Comment 7•15 years ago
|
||
As per comment 6
Flags: wanted-firefox3.6+
Flags: blocking-firefox3.6?
Flags: blocking-firefox3.6-
Assignee | ||
Updated•15 years ago
|
Assignee: nobody → dao
Assignee | ||
Comment 8•15 years ago
|
||
Attachment #407253 -
Flags: superreview?(mconnor)
Attachment #407253 -
Flags: review?(vladimir)
Assignee | ||
Updated•15 years ago
|
Summary: browser-tabPreviews.js uses mutation event listeners → tabbrowser.xml and browser-tabPreviews.js use mutation event listeners
Attachment #407253 -
Flags: review?(vladimir) → review+
Updated•15 years ago
|
Attachment #407253 -
Flags: superreview?(mconnor) → superreview+
Assignee | ||
Comment 9•15 years ago
|
||
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 3.7a1
Comment 10•15 years ago
|
||
Ctrl-Tab and All-Tabs panel work fine. Verified fixed with Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.3a1pre) Gecko/20091221 Minefield/3.7a1pre ID:20091221034526
Status: RESOLVED → VERIFIED
Assignee | ||
Comment 11•14 years ago
|
||
need to document the TabAttrModified event
Keywords: dev-doc-needed
Comment 12•14 years ago
|
||
Documented:
https://developer.mozilla.org/en/Code_snippets/Tabbed_browser#Notification_when_a_tab%27s_attributes_change
And added to the Fx4 for developers page.
Keywords: dev-doc-needed → dev-doc-complete
You need to log in
before you can comment on or make changes to this bug.
Description
•