2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        Reduce FrameView.h includes to speed up build times
        https://bugs.webkit.org/show_bug.cgi?id=40408

        More attempted build fixes for Tiger and Qt.

        * page/Frame.cpp:
        * page/Frame.h:
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        Reduce FrameView.h includes to speed up build times
        https://bugs.webkit.org/show_bug.cgi?id=40408

        * webkit/webkitwebinspector.cpp:
         - Include RenderLayer.h

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60947 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        Reduce FrameView.h includes to speed up build times
        https://bugs.webkit.org/show_bug.cgi?id=40408

        Another fix for Qt.

        * page/Frame.h:
         - Include CSSMutableStyleDeclaration.h since it's used by m_typingStyle = 0;

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60948 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        Reduce FrameView.h includes to speed up build times
        https://bugs.webkit.org/show_bug.cgi?id=40408

        * Api/qwebframe.cpp:
         - Include RenderLayer.h since it's used in this file.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60949 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        Reduce FrameView.h includes to speed up build times
        https://bugs.webkit.org/show_bug.cgi?id=40408

        Another fix for Windows.

        * WebView.cpp:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60950 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-09  MORITA Hajime  <morrita@google.com>

        Reviewed by Kent Tamura.

        Refactoring: Simple shadow elements should be factored out .
        https://bugs.webkit.org/show_bug.cgi?id=40400

        Pulled ShadowElement class up from SliderThumbElement,
        ProgressValueElement, ShadowInputElement.
        And renamed ProgressValueElement to ShadowBlockElement.

        No new tests. Because there is no functional change.

        * CMakeLists.txt:
        * GNUmakefile.am:
        * WebCore.gypi:
        * WebCore.pro:
        * WebCore.vcproj/WebCore.vcproj:
        * WebCore.xcodeproj/project.pbxproj:
        * rendering/RenderFileUploadControl.cpp:
        * rendering/RenderProgress.cpp:
        (WebCore::RenderProgress::updateValuePartState):
        * rendering/RenderProgress.h:
        * rendering/RenderSlider.cpp:
        (WebCore::SliderThumbElement::SliderThumbElement):
        (WebCore::SliderThumbElement::defaultEventHandler):
        (WebCore::SliderThumbElement::detach):
        * rendering/ShadowElement.cpp: Added.
        (WebCore::ShadowBlockElement::create):
        (WebCore::ShadowBlockElement::ShadowBlockElement):
        (WebCore::ShadowInputElement::create):
        (WebCore::ShadowInputElement::ShadowInputElement):
        * rendering/ShadowElement.h: Added.
        (WebCore::ShadowElement::ShadowElement):
        (WebCore::ShadowElement::isShadowNode):
        (WebCore::ShadowElement::shadowParentNode):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60951 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-09  Andrei Popescu  <andreip@google.com>

        Reviewed by Adam Barth.

        CodeGeneratorJS.pm incorrectly increments $paramIndex when a method is declared with [CallWith]
        https://bugs.webkit.org/show_bug.cgi?id=40372

        Use two variables to keep track of the number of arguments passed from JavaScript vs the number
        of arguments passed to the corresponding C++ method. These numbers can be different since
        the parameter declared via [CallWith] is generated in the bindings instead of being passed
        from JavaScript.

        The layout tests added here test both that the parameters are read correctly as well as
        tests some basic indexed database functionality. There are also bindings specific
        tests added in TestObj.idl.

        * storage/indexeddb/idb-objectstore-request-expected.txt: Added.
        * storage/indexeddb/idb-objectstore-request.html: Added.
        * storage/indexeddb/script-tests/idb-objectstore-request.js: Added.
        (openSuccess):
        (createSuccess):
        (createObjectStore):
        (doCreateOrOpen):
        (test):
2010-06-09  Andrei Popescu  <andreip@google.com>

        Reviewed by Adam Barth.

        CodeGeneratorJS.pm incorrectly increments $paramIndex when a method is declared with [CallWith]
        https://bugs.webkit.org/show_bug.cgi?id=40372

        Use two variables to keep track of the number of arguments passed from JavaScript vs the number
        of arguments passed to the corresponding C++ method. These numbers can be different since
        the parameter declared via [CallWith] is generated in the bindings instead of being passed
        from JavaScript.

        Test: storage/indexeddb/idb-objectstore-request.html

        * bindings/scripts/CodeGeneratorJS.pm:
        * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
        (WebDOMTestObj::withScriptExecutionContext):
        * bindings/scripts/test/CPP/WebDOMTestObj.h:
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndArg):
        (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndOptionalArg):
        (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndUserGesture):
        (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndUserGestureASAD):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60952 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Jungshik Shin  <jshin@chromium.org>

        Reviewed by Kent Tamura

        Bug 38224 - [chromium] Enable rendering of Ethiopic, Lao, Tibetan
                    and a few other scripts on Win XP

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

        Make it possible to specify a list of fonts for per-script
        fallback instead of a single font per script. This is
        necessary for Malayalam (for which Windows font doesn't
        support Unicode 5.x fully on Vista or earlier), Ethiopic
        (we want to support on XP with a 3rd party font because XP
        doesn't have any Ethiopic font out of the box) and some other
        scripts. This is a short-term 'fix' until we have per-script
        font preferences.

        No layout test is added because the test results would be
        dependent on which fonts are present.

        * platform/graphics/chromium/FontUtilsChromiumWin.cpp:
        (WebCore::):
        (WebCore::FontMap::ScriptToFontFamilies::):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60953 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Vangelis Kokkevis  <vangelis@chromium.org>

        Reviewed by Dimitri Glazkov.

        [chromium] Adding the ANGLE project to the DEPS file as it's required
        by the gpu-accelerated compositor.
        https://bugs.webkit.org/show_bug.cgi?id=40379

        * DEPS:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60954 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Mike Belshe  <mbelshe@chromium.org>

        Reviewed by David Levin

        Track whether a resource is loaded via a proxy.

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

        * platform/network/chromium/ResourceResponse.h:
        (WebCore::ResourceResponse::wasFetchedViaProxy):
        (WebCore::ResourceResponse::setWasFetchedViaProxy):
2010-06-10  Mike Belshe  <mbelshe@google.com>

        Reviewed by David Levin

        Track whether a resource is loaded via a proxy.

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

        * public/WebURLResponse.h:
        * src/WebURLResponse.cpp:
        (WebKit::WebURLResponse::wasFetchedViaProxy):
        (WebKit::WebURLResponse::setWasFetchedViaProxy):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60955 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Marcus Bulach  <bulach@google.com>

        Reviewed by Jeremy Orlow.

        [chromium] Upstream layout tests expectations for Geolocation.
        Rebaseline fast/dom/Geolocation/callback-exception-expected.html due to JSC x V8 messages.
        https://bugs.webkit.org/show_bug.cgi?id=39721

        * platform/chromium/fast/dom/Geolocation/callback-exception-expected.txt: Added.
        * platform/chromium/test_expectations.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60956 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Daniel Cheng  <dcheng@chromium.org>

        Reviewed by Jian Li.

        Don't convert filenames to URLs in edit drags.
        https://bugs.webkit.org/show_bug.cgi?id=38826

        For security reasons, we don't want to expose file system paths to web
        content, so we filter them out of edit drags.

        * editing/pasteboard/file-drag-to-editable-expected.txt: Added.
        * editing/pasteboard/file-drag-to-editable.html: Added.
        * editing/pasteboard/script-tests/file-drag-to-editable.js: Added.
        * platform/gtk/Skipped:
        * platform/mac/Skipped:
        * platform/qt/Skipped:
        * platform/win/Skipped:
2010-06-10  Daniel Cheng  <dcheng@chromium.org>

        Reviewed by Jian Li.

        Don't convert filenames to URLs in edit drags.
        https://bugs.webkit.org/show_bug.cgi?id=38826

        For security reasons, we don't want to expose file system paths to web
        content, so we filter them out of edit drags.

        Test: editing/pasteboard/file-drag-to-editable.html

        * page/DragController.cpp:
        (WebCore::documentFragmentFromDragData):
        * platform/DragData.h:
        (WebCore::DragData::):
        * platform/android/DragDataAndroid.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/chromium/DragDataChromium.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/efl/DragDataEfl.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/gtk/DragDataGtk.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/haiku/DragDataHaiku.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/mac/DragDataMac.mm:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/qt/DragDataQt.cpp:
        (WebCore::DragData::asPlainText):
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/win/ClipboardUtilitiesWin.cpp:
        (WebCore::getURL):
        (WebCore::getPlainText):
        * platform/win/ClipboardUtilitiesWin.h:
        * platform/win/ClipboardWin.cpp:
        (WebCore::ClipboardWin::getData):
        * platform/win/DragDataWin.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/wince/DragDataWince.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):
        * platform/wx/DragDataWx.cpp:
        (WebCore::DragData::containsURL):
        (WebCore::DragData::asURL):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60957 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Raine Makelainen  <raine.makelainen@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Impossible to set input method hints based HTML5 input types
        https://bugs.webkit.org/show_bug.cgi?id=40107

        Helper methods for checking "tel", "number", "email",
        and "url" input element types.

        * html/HTMLInputElement.h:
        (WebCore::HTMLInputElement::isTelephoneField):
        (WebCore::HTMLInputElement::isNumberField):
        (WebCore::HTMLInputElement::isEmailField):
        (WebCore::HTMLInputElement::isUrlField):
2010-06-10  Raine Makelainen  <raine.makelainen@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Impossible to set input method hints based HTML5 input types
        https://bugs.webkit.org/show_bug.cgi?id=40107

        EditorClientQt to set input method hints for "number", "tel",
        "email", and "url" HTML input elements.

        Tests for HTML input elements and input method hints added for
        QGraphicsWebView and QWebView.

        * WebCoreSupport/EditorClientQt.cpp:
        (WebCore::EditorClientQt::setInputMethodState):
        * tests/qgraphicswebview/resources/input_types.html: Added.
        * tests/qgraphicswebview/tst_qgraphicswebview.cpp:
        (GraphicsWebView::GraphicsWebView):
        (GraphicsWebView::fireMouseClick):
        (tst_QGraphicsWebView::focusInputTypes):
        * tests/qgraphicswebview/tst_qgraphicswebview.qrc: Added.
        * tests/qwebview/resources/input_types.html: Added.
        * tests/qwebview/tst_qwebview.cpp:
        (WebView::fireMouseClick):
        (tst_QWebView::focusInputTypes):
        * tests/qwebview/tst_qwebview.qrc:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Diego Gonzalez  <diegohcg@webkit.org>

        Reviewed by Kenneth Rohde Christiansen.

        [Qt] DRT EventSender support to graphics mouse events activation
        https://bugs.webkit.org/show_bug.cgi?id=40017

        * DumpRenderTree/qt/EventSenderQt.cpp:
        (EventSender::mouseDown):
        (EventSender::mouseUp):
        (EventSender::mouseMoveTo):
        (EventSender::keyDown):
        (EventSender::contextClick):
        (EventSender::sendTouchEvent):
        (EventSender::sendOrQueueEvent):
        (EventSender::eventFilter):
        (EventSender::createGraphicsSceneMouseEvent):
        (EventSender::sendEvent):
        * DumpRenderTree/qt/EventSenderQt.h:
        (EventSender::isGraphicsBased):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60959 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Support for loading notification icons
        https://bugs.webkit.org/show_bug.cgi?id=40396

        * http/tests/notifications: Added.
        * http/tests/notifications/icon-does-not-exist-expected.txt: Added.
        * http/tests/notifications/icon-does-not-exist.html: Added.
        * http/tests/notifications/icon-exists-cancel-expected.txt: Added.
        * http/tests/notifications/icon-exists-cancel.html: Added.
        * http/tests/notifications/icon-exists-expected.txt: Added.
        * http/tests/notifications/icon-exists-show-alert-during-load-expected.txt: Added.
        * http/tests/notifications/icon-exists-show-alert-during-load.html: Added.
        * http/tests/notifications/icon-exists.html: Added.
        * http/tests/notifications/icon-requires-auth-expected.txt: Added.
        * http/tests/notifications/icon-requires-auth.html: Added.
        * http/tests/notifications/resources: Added.
        * http/tests/notifications/resources/icon-exists.png: Added.
        * http/tests/notifications/resources/icon-requires-auth.php: Added.
        * platform/chromium/test_expectations.txt:
        * platform/gtk/Skipped:
        * platform/mac/Skipped:
        * platform/win/Skipped:
2010-06-10  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Support for loading notification icons
        https://bugs.webkit.org/show_bug.cgi?id=40396

        Make notification objects download the icon needed for displaying the
        notification before calling the NotificationPresenter to display the
        notification.

        An error during the download would cause the notification to be displayed
        without an icon.

        If a notification is in the process of download, and a new notification
        is created with the same ReplaceId, the download is not cancelled
        immediately and the notification is removed only after the download is
        complete.

        Tests: http/tests/notifications/icon-does-not-exist.html
               http/tests/notifications/icon-exists-cancel.html
               http/tests/notifications/icon-exists-show-alert-during-load.html
               http/tests/notifications/icon-exists.html
               http/tests/notifications/icon-requires-auth.html

        * notifications/Notification.cpp:
        (WebCore::Notification::Notification):
        (WebCore::Notification::~Notification):
        (WebCore::Notification::show):
        (WebCore::Notification::cancel):
        (WebCore::Notification::startLoading):
        (WebCore::Notification::stopLoading):
        (WebCore::Notification::didReceiveResponse):
        (WebCore::Notification::didReceiveData):
        (WebCore::Notification::didFinishLoading):
        (WebCore::Notification::didFail):
        (WebCore::Notification::didFailRedirectCheck):
        (WebCore::Notification::didReceiveAuthenticationCancellation):
        (WebCore::Notification::finishLoading):
        * notifications/Notification.h:
        (WebCore::Notification::iconData):
        (WebCore::Notification::releaseIconData):
        (WebCore::Notification::):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60960 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Chang Shu  <chang.shu@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        [Qt] Unskip canvas/philip/tests/2d.shadow.enable.blur.html.

        * platform/qt/Skipped:
2010-06-10  Shu Chang  <chang.shu@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Change the type of ShadowBlur from int to float in GraphicsContext.
        Using int for ShadowBlur loses precision and fails the test.
        Note: This code change fixes Qt port but Mac is still failing due to
        platform issue. Function CGContextSetShadowWithColor() does not take
        a blur value less than 0.5.

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

        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::setShadow):
        (WebCore::GraphicsContext::getShadow):
        * platform/graphics/GraphicsContext.h:
        * platform/graphics/GraphicsContextPrivate.h:
        * platform/graphics/cairo/FontCairo.cpp:
        (WebCore::Font::drawGlyphs):
        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::calculateShadowBufferDimensions):
        (WebCore::drawPathShadow):
        (WebCore::drawBorderlessRectShadow):
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/cairo/ImageCairo.cpp:
        (WebCore::BitmapImage::draw):
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/chromium/FontChromiumWin.cpp:
        (WebCore::TransparencyAwareFontPainter::TransparencyAwareGlyphPainter::drawGlyphs):
        (WebCore::Font::drawComplexText):
        * platform/graphics/gtk/FontGtk.cpp:
        (WebCore::Font::drawComplexText):
        * platform/graphics/haiku/GraphicsContextHaiku.cpp:
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/mac/FontMac.mm:
        (WebCore::Font::drawGlyphs):
        * platform/graphics/openvg/GraphicsContextOpenVG.cpp:
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/qt/FontQt.cpp:
        (WebCore::Font::drawComplexText):
        * platform/graphics/qt/GraphicsContextQt.cpp:
        (WebCore::GraphicsContext::drawRect):
        (WebCore::GraphicsContext::drawLine):
        (WebCore::GraphicsContext::strokeArc):
        (WebCore::GraphicsContext::drawConvexPolygon):
        (WebCore::drawFilledShadowPath):
        (WebCore::GraphicsContext::strokePath):
        (WebCore::drawBorderlessRectShadow):
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/qt/ImageQt.cpp:
        (WebCore::BitmapImage::draw):
        * platform/graphics/skia/GraphicsContextSkia.cpp:
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/skia/SkiaFontWin.cpp:
        (WebCore::windowsCanHandleDrawTextShadow):
        * platform/graphics/win/FontCGWin.cpp:
        (WebCore::drawGDIGlyphs):
        (WebCore::Font::drawGlyphs):
        * platform/graphics/wince/GraphicsContextWince.cpp:
        (WebCore::GraphicsContext::fillRoundedRect):
        (WebCore::GraphicsContext::setPlatformShadow):
        (WebCore::GraphicsContext::drawText):
        * platform/graphics/wx/GraphicsContextWx.cpp:
        (WebCore::GraphicsContext::setPlatformShadow):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60961 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Kwang Yul Seo  <skyul@company100.net>

        Reviewed by Kent Tamura.

        Add ENABLE(DATABASE) guard for DatabaseAuthorizer.cpp
        https://bugs.webkit.org/show_bug.cgi?id=40399

        Build fix for ENABLE(DATABASE)=0.

        * storage/DatabaseAuthorizer.cpp:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60962 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Mahesh Kulkarni  <mahesh.kulkarni@nokia.com>

        Reviewed by Simon Hausmann.

        [Qt] Memory leak in qwebpage unit test cases
        https://bugs.webkit.org/show_bug.cgi?id=40405

        * tests/qwebpage/tst_qwebpage.cpp:
        (tst_QWebPage::infiniteLoopJS):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60963 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Adam Barth  <abarth@webkit.org>

        Reviewed by Eric Seidel.

        Use allowRequestIfNoIllegalURICharacters instead of context for XSSAuditor::canLoadExternalScriptFromSrc
        https://bugs.webkit.org/show_bug.cgi?id=40404

        We originally added the context parameter to
        canLoadExternalScriptFromSrc to work around some false positives caused
        by folks checking external script URLs on the server.  Our thought was
        that we could tell these were not real XSS attacks because the
        surrounding context wouldn't match in the URL and the document.

        Implementing this feature in the HTML5 parser is hard because it
        pierces a layer of abstraction (the token abstraction of the input
        stream).  We could hack this into the new parser, but instead I think
        it's better to switch to using the allowRequestIfNoIllegalURICharacters
        heuristic.

        We designed the allowRequestIfNoIllegalURICharacters after the context
        heuristic to deal with other cases where the server was validating
        input before echoing it.  However, we never tried applying it to
        canLoadExternalScriptFromSrc.

        It's possible that this will cause false positives and will need to be
        reverted, which is why I've left in some of the infrustructure for
        computing context.  We don't have a good way to know if that will
        happen except to try.  We do know, however, that this heuristic will
        work for the original false positives we saw.

        * html/HTML5Tokenizer.cpp:
        (WebCore::HTML5Tokenizer::shouldLoadExternalScriptFromSrc):
        * html/HTMLTokenizer.cpp:
        (WebCore::HTMLTokenizer::parseTag):
        * page/XSSAuditor.cpp:
        (WebCore::XSSAuditor::canLoadExternalScriptFromSrc):
        * page/XSSAuditor.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60964 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Yury Semikhatsky  <yurys@chromium.org>

        Reviewed by Pavel Feldman.

        Web Inspector: to reduce the front end start up time don't push script
        sources to frontend if debugger is always enabled, instead request
        script content lazily at the moment it should be displyed. It is critical for
        always enabled debugger because in that case lots of script may have
        already been parsed when the front end is opening and pushing all
        of them at once may slow things down(even though the script sources will never
        be used if scripts panel isn't open).
        https://bugs.webkit.org/show_bug.cgi?id=40364

        * inspector/InspectorBackend.cpp:
        (WebCore::InspectorBackend::getScriptSource):
        * inspector/InspectorBackend.h:
        * inspector/InspectorBackend.idl:
        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::didCommitLoad):
        (WebCore::InspectorController::getScriptSource):
        (WebCore::InspectorController::didParseSource):
        * inspector/InspectorController.h:
        * inspector/InspectorFrontend.cpp:
        (WebCore::InspectorFrontend::didGetScriptSource):
        * inspector/InspectorFrontend.h:
        * inspector/front-end/InspectorBackendStub.js:
        (.WebInspector.InspectorBackendStub.prototype.editScriptSource):
        (.WebInspector.InspectorBackendStub.prototype.getScriptSource):
        * inspector/front-end/ScriptView.js:
        (WebInspector.ScriptView.prototype.setupSourceFrameIfNeeded):
        (WebInspector.ScriptView.prototype._didGetScriptSource):
        (WebInspector.ScriptView.prototype._sourceFrameSetupFinished):
2010-06-10  Yury Semikhatsky  <yurys@chromium.org>

        Reviewed by Pavel Feldman.

        Web Inspector: to reduce the front end start up time don't push script
        sources to frontend if debugger is always enabled, instead request
        script content lazily at the moment it should be displyed. It is critical for
        always enabled debugger because in that case lots of script may have
        already been parsed when the front end is opening and pushing all
        of them at once may slow things down(even though the script sources will never
        be used if scripts panel isn't open).
        https://bugs.webkit.org/show_bug.cgi?id=40364

        * src/js/DevTools.js:
        * src/js/InspectorControllerImpl.js:
        (devtools.InspectorBackendImpl):
        (.devtools.InspectorBackendImpl.prototype.getScriptSource):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60965 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        HTML5 Parser should continue parsing after script execution
        https://bugs.webkit.org/show_bug.cgi?id=40416

        The previous code was just wrong.  We were always blocking
        the parser after any script execution.  Now we correctly continue
        parsing after a successful script execution and only block the
        parser when we weren't able to execute the script immediately.

        Added a new haveParsingBlockingScript() function to HTML5ScriptRunner
        to make some of the code more self-documenting.

       Test: fast/tokenizer/write-multiple-scripts.html
             fast/js/implicit-call-with-global-reentry.html

        * html/HTML5ScriptRunner.cpp:
        (WebCore::HTML5ScriptRunner::execute):
         - Remove some old (now bogus) FIXMEs and notImplemented() calls.
         - Fix the logic to match the HTML5 spec by continuing parsing
           after script execution and only blocking the parser when the
           script wasn't able to immediately run.
        (WebCore::HTML5ScriptRunner::haveParsingBlockingScript):
         - New function to make some of the code read better.
        (WebCore::HTML5ScriptRunner::executeParsingBlockingScripts):
         - Use haveParsingBlockingScript().
        (WebCore::HTML5ScriptRunner::executeScriptsWaitingForLoad):
         - Use haveParsingBlockingScript().
        (WebCore::HTML5ScriptRunner::runScript):
         - Use haveParsingBlockingScript().
        * html/HTML5ScriptRunner.h:
2010-06-10  Eric Seidel  <eric@webkit.org>

        Reviewed by Adam Barth.

        HTML5 Parser should continue parsing after script execution
        https://bugs.webkit.org/show_bug.cgi?id=40416

        Test the ordering of script execution with multiple calls to
        document.write().

        * fast/tokenizer/write-multiple-scripts-expected.txt: Added.
        * fast/tokenizer/write-multiple-scripts.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@60966 268f45cc-cd09-0410-ab3c-d52691b4dbfc