Ignore:
Timestamp:
Jul 26, 2010, 1:53:50 AM (15 years ago)
Author:
Simon Hausmann
Message:

[Qt] Use the default timeout interval for JS as the HTML tokenizer delay for setHtml()

Patch by Tor Arne Vestbø <[email protected]> on 2009-10-30
Reviewed by Kenneth Rohde Christiansen.

This ensures that long-running JavaScript (for example due to a modal alert() dialog),
will not trigger a deferred load after only 500ms (the default tokenizer delay) while
still giving a reasonable timeout (10 seconds) to prevent deadlock.

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

JavaScriptCore:

  • runtime/TimeoutChecker.h: Add getter for the timeout interval

WebKit/qt:

  • Api/qwebframe.cpp: Document the behaviour
  • WebCoreSupport/FrameLoaderClientQt.cpp: set the custom tokenizer delay for substitute loads
  • tests/qwebframe/tst_qwebframe.cpp: Add test
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/runtime/TimeoutChecker.h

    r41126 r64036  
    4141
    4242        void setTimeoutInterval(unsigned timeoutInterval) { m_timeoutInterval = timeoutInterval; }
     43        unsigned timeoutInterval() const { return m_timeoutInterval; }
    4344       
    4445        unsigned ticksUntilNextCheck() { return m_ticksUntilNextCheck; }
Note: See TracChangeset for help on using the changeset viewer.