Summary: | Simplifying DOMTimer lifetime management code | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Dmitry Titov <dimich> | ||||||
Component: | DOM | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Minor | CC: | ap, darin | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Attachments: |
|
Description
Dmitry Titov
2008-12-29 14:22:02 PST
Created attachment 26300 [details]
Proposed patch
Comment on attachment 26300 [details] Proposed patch > - static_cast<Document*>(context)->removeTimeout(timeoutId); > + DOMTimer* timer = static_cast<Document*>(context)->findTimeout(timeoutId); > + delete timer; I personally would like this to just be a one liner without a local variable. > - ActiveDOMObject::contextDestroyed(); > + ActiveDOMObject::contextDestroyed(); // Clears m_scriptExecutionContext. Is adding this comment really an improvement? Normally we use one space before the "//". r=me Created attachment 26387 [details]
Patch with changes after review
Thanks Darin!!
All comments addressed. Seems ready to be landed.
|