[Webkit-unassigned] [Bug 48077] HTMLParserScheduler should be suspended when page loading is deferred

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Dec 21 01:15:24 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=48077


Adam Barth <abarth at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #73422|review?                     |review+
               Flag|                            |




--- Comment #25 from Adam Barth <abarth at webkit.org>  2010-12-21 01:15:24 PST ---
(From update of attachment 73422)
View in context: https://bugs.webkit.org/attachment.cgi?id=73422&action=review

> WebCore/dom/DocumentParser.h:95
> +    virtual void willDeferLoading();
> +    virtual void didResumeLoading();

These really want to be named suspend and resume, respectively.  The only problem is that calling suspend doesn't actually suspend the parser.  It just stops the parser from running its scheduled callback.

I think the code content of this patch is fine, I'm just struggling to find the right names for these functions.  I don't want to hold your patch hostage any longer, but we might want to come back and think of better names here.  Maybe add a FIXME comment?

> WebCore/page/PageGroupLoadDeferrer.cpp:54
>                      frame->document()->suspendActiveDOMObjects(ActiveDOMObject::WillShowDialog);
>                      frame->document()->asyncScriptRunner()->suspend();
> +                    if (DocumentParser* parser = frame->document()->parser())
> +                        parser->willDeferLoading();

I understand that you don't want to add a FIXME for grouping these operations, but can you add a FIXME about moving this work to Document at some point?

> WebCore/page/PageGroupLoadDeferrer.cpp:76
>                  frame->document()->resumeActiveDOMObjects();
>                  frame->document()->asyncScriptRunner()->resume();
> +                if (DocumentParser* parser = frame->document()->parser())
> +                    parser->didResumeLoading();

Same here.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list