1. 05 Apr, 2010 13 commits
    • robert@webkit.org's avatar
      2010-04-05 Robert Hogan <robert@webkit.org> · 543a7f86
      robert@webkit.org authored
              Reviewed by Kenneth Rohde-Christiansen.
      
              [Qt] Fix infinite redirection loop in QNetworkReplyHandler
      
              Qt enters an infinite loop if a redirect response redirects to itself.
      
              Fixes http/tests/xmlhttprequest/connection-error-sync.html
      
              https://bugs.webkit.org/show_bug.cgi?id=37097
      
              * platform/network/qt/QNetworkReplyHandler.cpp:
              (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
      
      2010-04-05  Robert Hogan  <robert@webkit.org>
      
              Reviewed by Kenneth Rohde-Christiansen.
      
              [Qt] Fix infinite redirection loop in QNetworkReplyHandler
      
              Unskip http/tests/xmlhttprequest/connection-error-sync.html
      
              https://bugs.webkit.org/show_bug.cgi?id=37097
      
              * platform/qt/Skipped:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57085 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      543a7f86
    • yurys@chromium.org's avatar
      2010-04-05 Yury Semikhatsky <yurys@chromium.org> · 9f68e8db
      yurys@chromium.org authored
              Unreviewed, revert r57078.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57082 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9f68e8db
    • dglazkov@chromium.org's avatar
      2010-04-05 Dimitri Glazkov <dglazkov@chromium.org> · d3762f6e
      dglazkov@chromium.org authored
              Reviewed by Darin Adler.
      
              Style update done due to mutation event dispatching in textarea can be
              used to corrupt the render tree.
              https://bugs.webkit.org/show_bug.cgi?id=36864
      
              Modified listbox-selection.html to correctly set the size during
              creation. Otherwise, options added to it as a menuList, resulting
              in a default selection of the first item.
      
              Added a few more tests to ensure we capture correct behavior for
              select elements and their default selection, as well as the influence
              of when layout occurs.
      
              * fast/forms/listbox-selection.html:
              * fast/forms/select-change-listbox-to-popup-roundtrip.html: Added.
              * fast/forms/select-change-popup-to-listbox-roundtrip.html: Added.
              * fast/forms/textarea-and-mutation-events.html: Added.
      2010-04-05  Dimitri Glazkov  <dglazkov@chromium.org>
      
              Reviewed by Darin Adler.
      
              Style update done due to mutation event dispatching in textarea can be
              used to corrupt the render tree.
              https://bugs.webkit.org/show_bug.cgi?id=36864
      
              Tests: fast/forms/select-change-listbox-to-popup-roundtrip.html
                     fast/forms/select-change-popup-to-listbox-roundtrip.html
                     fast/forms/textarea-and-mutation-events.html
      
              * dom/Node.cpp:
              (WebCore::Node::dispatchGenericEvent): Removed invocation of
                  Document::updateStyleForAllDocuments
              * html/HTMLSelectElement.cpp:
              (WebCore::HTMLSelectElement::parseMappedAttribute): Added explicit
                  recalc to ensure accuracy of representation, especially for
                  menuList/listBox switches.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57081 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d3762f6e
    • kenneth@webkit.org's avatar
      iframe flattening doesn't flatten · 508a9397
      kenneth@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=36798
      
      Reviewed by Dave Hyatt.
      
      Fixed to the iframe flattening code so that the iframes on
      http://www.samisite.com/test-csb2nf/id43.htm are actually
      flattened.
      
      Covered by current tests.
      
      * page/FrameView.cpp: Propagate contents changes of iframes
      and subframes in framesets to the parent so that it is relayouted
      (WebCore::FrameView::setContentsSize):
      (WebCore::FrameView::adjustViewSize):
      (WebCore::FrameView::scheduleRelayout):
      * rendering/RenderPart.cpp: HTMLIFrameElement do not inherit from
      HTMLFrameElement, but HTMLFrameElementBase, correct cast. Correct
      the use of inset border values. Avoid a sometimes unnecessary
      relayout.
      (WebCore::RenderPart::layoutWithFlattening):
      * rendering/RenderPartObject.cpp: Make the calcHeight and calcWidth
      return the right values, considering scrolling and fixed width/height
      (WebCore::RenderPartObject::flattenFrame):
      (WebCore::RenderPartObject::calcHeight):
      (WebCore::RenderPartObject::calcWidth):
      (WebCore::RenderPartObject::layout):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57080 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      508a9397
    • vitalyr@chromium.org's avatar
      2010-04-05 Vitaly Repeshko <vitalyr@chromium.org> · eaf6bfb1
      vitalyr@chromium.org authored
              Reviewed by Yury Semikhatsky.
      
              [V8] Extend the set of types supported by SerializedScriptValue
              https://bugs.webkit.org/show_bug.cgi?id=37052
      
              New types include sparse arrays, Uint32, Date, and ImageData.
      
              Serialization process became more flexible. A state can either
              directly write primitive values (instead of returning them like
              iterator) or construct a new state for serializing complex values
              that will return to the current state when done.
      
              Deserialization process now avoids exposing the tags using a set
              of factory functions for complex objects instead.
      
              Internal buffer type changed to uint8_t to be independent of
              whether char is signed or not.
      
              * bindings/v8/SerializedScriptValue.cpp:
              (WebCore::):
              (WebCore::Writer::Writer):
              (WebCore::Writer::writeString):
              (WebCore::Writer::writeUint32):
              (WebCore::Writer::writeDate):
              (WebCore::Writer::writeNumber):
              (WebCore::Writer::writeImageData):
              (WebCore::Writer::writeArray):
              (WebCore::Writer::writeObject):
              (WebCore::Writer::writeSparseArray):
              (WebCore::Writer::doWriteUint32):
              (WebCore::Writer::doWriteNumber):
              (WebCore::Writer::append):
              (WebCore::Writer::fillHole):
              (WebCore::Writer::byteAt):
              (WebCore::Serializer::Serializer):
              (WebCore::Serializer::serialize):
              (WebCore::Serializer::writeArray):
              (WebCore::Serializer::writeObject):
              (WebCore::Serializer::writeSparseArray):
              (WebCore::Serializer::StateBase::StateBase):
              (WebCore::Serializer::ErrorState::ErrorState):
              (WebCore::Serializer::ErrorState::advance):
              (WebCore::Serializer::State::composite):
              (WebCore::Serializer::State::State):
              (WebCore::Serializer::ArrayState::ArrayState):
              (WebCore::Serializer::ArrayState::advance):
              (WebCore::Serializer::AbstractObjectState::AbstractObjectState):
              (WebCore::Serializer::AbstractObjectState::advance):
              (WebCore::Serializer::ObjectState::ObjectState):
              (WebCore::Serializer::ObjectState::objectDone):
              (WebCore::Serializer::SparseArrayState::SparseArrayState):
              (WebCore::Serializer::SparseArrayState::objectDone):
              (WebCore::Serializer::push):
              (WebCore::Serializer::pop):
              (WebCore::Serializer::handleError):
              (WebCore::Serializer::checkComposite):
              (WebCore::Serializer::writeString):
              (WebCore::Serializer::writeImageData):
              (WebCore::Serializer::newArrayState):
              (WebCore::Serializer::newObjectState):
              (WebCore::Serializer::doSerialize):
              (WebCore::Reader::Reader):
              (WebCore::Reader::read):
              (WebCore::Reader::readString):
              (WebCore::Reader::readUint32):
              (WebCore::Reader::readDate):
              (WebCore::Reader::readNumber):
              (WebCore::Reader::readImageData):
              (WebCore::Reader::doReadUint32):
              (WebCore::Reader::doReadNumber):
              (WebCore::Deserializer::Deserializer):
              (WebCore::Deserializer::createArray):
              (WebCore::Deserializer::createObject):
              (WebCore::Deserializer::createSparseArray):
              (WebCore::Deserializer::initializeObject):
              (WebCore::Deserializer::doDeserialize):
              (WebCore::Deserializer::stackDepth):
              (WebCore::SerializedScriptValue::deserialize):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57079 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      eaf6bfb1
    • yurys@chromium.org's avatar
      2010-04-05 Yury Semikhatsky <yurys@chromium.org> · 4a016ace
      yurys@chromium.org authored
              Reviewed by Pavel Feldman.
      
              Refactored error reporting mechanizm on Worker Global Objects.
              Unlike other event listeners which accept single argument(Event)
              onerror handler on worker global object should be a function
              accepting three arguments. This error reporting was implementedas
              EventListener::reportError method which had custom implementations
              for v8 and JSC. This patch removes EventListener::reportError and
              moves its functionality into custom bindings(V8WorkerContextErrorHandler
              and JSWorkerContextErrorHandler) that implement EventListener inerface
              for the onerror handler.
      
              This patch also makes uncaught exceptions that happen in the onerror
              listener be reported to the Worker's onerror handler.
      
              https://bugs.webkit.org/show_bug.cgi?id=36375
      
              * WebCore.gypi:
              * WebCore.pro:
              * WebCore.xcodeproj/project.pbxproj:
              * bindings/js/JSEventListener.cpp:
              * bindings/js/JSEventListener.h:
              * bindings/js/JSWorkerContextErrorHandler.cpp: Added.
              (WebCore::JSWorkerContextErrorHandler::JSWorkerContextErrorHandler):
              (WebCore::JSWorkerContextErrorHandler::~JSWorkerContextErrorHandler):
              (WebCore::JSWorkerContextErrorHandler::handleEvent):
              * bindings/js/JSWorkerContextErrorHandler.h: Added.
              (WebCore::JSWorkerContextErrorHandler::create):
              (WebCore::createJSWorkerContextErrorHandler):
              * bindings/scripts/CodeGeneratorJS.pm:
              * bindings/scripts/CodeGeneratorV8.pm:
              * bindings/v8/V8WorkerContextErrorHandler.cpp: Added.
              (WebCore::V8WorkerContextErrorHandler::V8WorkerContextErrorHandler):
              (WebCore::V8WorkerContextErrorHandler::callListenerFunction):
              * bindings/v8/V8WorkerContextErrorHandler.h: Added.
              (WebCore::V8WorkerContextErrorHandler::create):
              * bindings/v8/V8WorkerContextEventListener.cpp:
              * bindings/v8/V8WorkerContextEventListener.h:
              * dom/EventListener.h: Removed reportError method that was used only for reporting worker errors.
              * workers/WorkerContext.cpp:
              (WebCore::WorkerContext::WorkerContext):
              (WebCore::WorkerContext::reportException):
      
      2010-04-05  Yury Semikhatsky  <yurys@chromium.org>
      
              Reviewed by Pavel Feldman.
      
              Test that exception which occurs in onerror handler is reported to the Worker object.
      
              https://bugs.webkit.org/show_bug.cgi?id=36375
      
              * fast/workers/worker-script-error-expected.txt:
              * fast/workers/worker-script-error.html:
              * workers/WorkerContext.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57078 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4a016ace
    • tonikitoo@webkit.org's avatar
      Fix some "explicit braces to avoid ambiguous 'else'" warnings · d83fd03d
      tonikitoo@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=37088
      
      Reviewed by Darin Adler.
      Patch by Antonio Gomes (tonikitoo@webkit.org)
      
      * dom/Node.cpp:
      (WebCore::Node::dispatchGenericEvent):
      * page/DOMWindow.cpp:
      (WebCore::DOMWindow::dispatchEvent):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57077 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d83fd03d
    • laszlo.1.gombos@nokia.com's avatar
      2010-04-05 Laszlo Gombos <laszlo.1.gombos@nokia.com> · 3c67e74d
      laszlo.1.gombos@nokia.com authored
              Reviewed by Kenneth Rohde Christiansen.
      
              Consolidate the definition of SKIP_STATIC_CONSTRUCTORS_ON_GCC
      
              Instead of defining and undefining it later, let's not
              define SKIP_STATIC_CONSTRUCTORS_ON_GCC for WINSCW.
      
              No new tests as there is no new functionality.
      
              * config.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57076 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3c67e74d
    • eric@webkit.org's avatar
      2010-04-05 Laszlo Gombos <laszlo.1.gombos@nokia.com> · e1321122
      eric@webkit.org authored
              Reviewed by Kenneth Rohde Christiansen.
      
              [Qt] [Symbian] Remove obsolete build flags for Symbian
              https://bugs.webkit.org/show_bug.cgi?id=37083
      
              Symbian port of QtWebKit port does not use icu, so it does
              not need U_HAVE_* defines.
      
              Symbian now has inttypes.h as part of OpenC.
      
              stdio.h, limits.h and MathExtras.h are already included in
              more appropriate locations.
      
              No new tests as there is no new functionality.
      
              * config.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57074 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e1321122
    • pfeldman@chromium.org's avatar
      2010-04-05 Pavel Feldman <pfeldman@chromium.org> · baa79630
      pfeldman@chromium.org authored
              Not reviewed: chromium build fix.
      
              * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
              (WebCore::V8InspectorFrontendHost::platformCallback):
              (WebCore::V8InspectorFrontendHost::portCallback):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      baa79630
    • pfeldman@chromium.org's avatar
      2010-04-05 Pavel Feldman <pfeldman@chromium.org> · 1e19a83d
      pfeldman@chromium.org authored
              Reviewed by Yury Semikhatsky.
      
              Web Inspector: [REGRESSION] platform detection in Chromium
              has regressed to unknown.
      
              https://bugs.webkit.org/show_bug.cgi?id=37081
      
              * bindings/js/JSInspectorFrontendHostCustom.cpp:
              (WebCore::JSInspectorFrontendHost::platform):
              (WebCore::JSInspectorFrontendHost::port):
              * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
              (WebCore::V8InspectorFrontendHost::platform):
              (WebCore::V8InspectorFrontendHost::port):
              * inspector/InspectorFrontendHost.cpp:
              * inspector/InspectorFrontendHost.h:
              * inspector/InspectorFrontendHost.idl:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57069 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      1e19a83d
    • eric@webkit.org's avatar
      2010-04-05 Andrey Kosyakov <caseq@chromium.org> · 8624fd2a
      eric@webkit.org authored
              Reviewed by Yury Semikhatsky.
      
              Remove logging of successful XHR and worker's importScript()
              to inspector console
              https://bugs.webkit.org/show_bug.cgi?id=37078
      
              * bindings/js/JSWorkerContextCustom.cpp:
              (WebCore::JSWorkerContext::importScripts):
              * bindings/v8/custom/V8WorkerContextCustom.cpp:
              (WebCore::V8WorkerContext::importScriptsCallback):
              * workers/DedicatedWorkerContext.cpp:
              (WebCore::DedicatedWorkerContext::importScripts):
              * workers/DedicatedWorkerContext.h:
              * workers/WorkerContext.cpp:
              (WebCore::WorkerContext::importScripts):
              * workers/WorkerContext.h:
              * xml/XMLHttpRequest.cpp:
              (WebCore::XMLHttpRequest::didFinishLoading):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57068 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8624fd2a
    • pfeldman@chromium.org's avatar
      2010-04-04 Pavel Feldman <pfeldman@chromium.org> · 32dee7a4
      pfeldman@chromium.org authored
              Not reviewed. Rolling out chromium changes r57028 and r57032
              for breaking chromium layout tests.
      
              * WebCore.gyp/WebCore.gyp:
              * WebCore.gypi:
              * platform/chromium/DragImageChromium.cpp: Added.
              (WebCore::dragImageSize):
              (WebCore::deleteDragImage):
              (WebCore::scaleDragImage):
              (WebCore::dissolveDragImageToFraction):
              (WebCore::createDragImageFromImage):
              (WebCore::createDragImageIconForCachedImage):
              * platform/chromium/DragImageChromiumMac.cpp: Removed.
              * platform/chromium/DragImageChromiumSkia.cpp: Removed.
              * platform/chromium/DragImageRef.h:
              
              WebKit/chromium:
              * public/WebViewClient.h:
              (WebKit::WebViewClient::startDragging):
              * src/DragClientImpl.cpp:
              (WebKit::DragClientImpl::startDrag):
              * src/WebViewImpl.cpp:
              (WebKit::WebViewImpl::startDragging):
              * src/WebViewImpl.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57064 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      32dee7a4
  2. 04 Apr, 2010 2 commits
    • tonikitoo@webkit.org's avatar
      2010-03-29 Antonio Gomes <tonikitoo@webkit.org> · 42907ccc
      tonikitoo@webkit.org authored
              Reviewed by Simon Fraser.
              Patch by Antonio Gomes <tonikitoo@webkit.org>
      
              Spatial Navigation: Initial code simplification in FocusController.cpp and SpatialNavigation.cpp
      
              WebCore::distanceInDirection method was handling much of the logic not
              strictly only related to the distance between nodes acquisition. This
              method was simplified and renamed to 'WebCore::distanceDataForNode'.
              The latter is now responsible for only getting the distance and alignment
              data, while all assignement logic previously in distanceInDirection method
              was moved place to updateFocusCandidateIfCloser.
      
              Parent document distance and alignment acquisitions, in turn, have also
              changed location: they are both got from deepFindFocusableNodeInDirection,
              and passed in a recursive call to findFocusableNodeInDirection via the
              candidateParent variable (optional parameter). In addition, the need for
              the 'focusCandidateCopy' variable in deepFindFocusableNodeInDirection method
              was removed, making the code much cleaner.
      
              No behaviour change at this point. Mostly moving code around to the place
              where it should live in.
      
              * page/FocusController.cpp:
              (WebCore::FocusController::advanceFocusDirectionally):
              (WebCore::updateFocusCandidateIfCloser):
              (WebCore::FocusController::findFocusableNodeInDirection):
              (WebCore::FocusController::deepFindFocusableNodeInDirection):
              * page/FocusController.h:
              * page/SpatialNavigation.cpp:
              (WebCore::distanceDataForNode):
              (WebCore::renderRectRelativeToRootDocument):
              * page/SpatialNavigation.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57061 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      42907ccc
    • eric@webkit.org's avatar
      2010-04-04 Pavel Feldman <pfeldman@chromium.org> · 0236640e
      eric@webkit.org authored
              Reviewed by Timothy Hatcher.
      
              Web Inspector: In the inherited styles, do not render non-inherited properties as overriden.
      
              https://bugs.webkit.org/show_bug.cgi?id=37072
      
              * inspector/front-end/StylesSidebarPane.js:
              (WebInspector.StylePropertiesSection.prototype.isPropertyOverloaded):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57060 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0236640e
  3. 03 Apr, 2010 4 commits
    • eric@webkit.org's avatar
      2010-04-03 yael aharon <yael.aharon@nokia.com> · 40e6ef33
      eric@webkit.org authored
              Reviewed by Darin Adler.
      
              Enable HTMLProgressElement for Safari on OSX
              https://bugs.webkit.org/show_bug.cgi?id=36961
      
              * Configurations/FeatureDefines.xcconfig:
      2010-04-03  Kenneth Russell  <kbr@google.com>
      
              Reviewed by Darin Fisher.
      
              Inconsistent failure modes from uniform[Matrix]* with null WebGLUniformLocation
              https://bugs.webkit.org/show_bug.cgi?id=36574
      
              Fixed bugs in JavaScript bindings for uniform[Matrix]* entry
              points causing them to throw exceptions rather than synthesize GL
              errors. Fixed the implementations to synthesize INVALID_VALUE
              rather than INVALID_OPERATION to comply to the WebGL spec. Updated
              uniform-location-expected.txt to incorporate the correct error.
              Tested in Safari and Chromium.
      
              * fast/canvas/webgl/null-uniform-location-expected.txt: Added.
              * fast/canvas/webgl/null-uniform-location.html: Added.
              * fast/canvas/webgl/script-tests/null-uniform-location.js: Added.
              (callUniformFunction):
              * fast/canvas/webgl/uniform-location-expected.txt:
      2010-04-03  yael aharon  <yael.aharon@nokia.com>
      
              Reviewed by Darin Adler.
      
              Enable HTMLProgressElement for Safari on OSX
              https://bugs.webkit.org/show_bug.cgi?id=36961
      
              * Configurations/FeatureDefines.xcconfig:
              * WebCore.xcodeproj/project.pbxproj:
              * rendering/RenderThemeMac.h:
              * rendering/RenderThemeMac.mm:
              (WebCore::RenderThemeMac::animationRepeatIntervalForProgressBar):
              (WebCore::RenderThemeMac::animationDurationForProgressBar):
              (WebCore::RenderThemeMac::adjustProgressBarStyle):
              (WebCore::RenderThemeMac::paintProgressBar):
      2010-04-03  yael aharon  <yael.aharon@nokia.com>
      
              Reviewed by Darin Adler.
      
              Enable HTMLProgressElement for Safari on OSX
              https://bugs.webkit.org/show_bug.cgi?id=36961
      
              * Configurations/FeatureDefines.xcconfig:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57051 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      40e6ef33
    • jwieczorek@webkit.org's avatar
      2010-04-03 Jakub Wieczorek <jwieczorek@webkit.org> · eacf3e1f
      jwieczorek@webkit.org authored
              Unreviewed.
      
              Fix debug build with GCC >= 4.3.
      
              * platform/graphics/GraphicsLayer.cpp: Include stdio.h explicitly.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57050 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      eacf3e1f
    • eric@webkit.org's avatar
      2010-04-03 Kenneth Russell <kbr@google.com> · a4aa05f3
      eric@webkit.org authored
              Reviewed by Darin Fisher.
      
              Inconsistent failure modes from uniform[Matrix]* with null WebGLUniformLocation
              https://bugs.webkit.org/show_bug.cgi?id=36574
      
              Fixed bugs in JavaScript bindings for uniform[Matrix]* entry
              points causing them to throw exceptions rather than synthesize GL
              errors. Fixed the implementations to synthesize INVALID_VALUE
              rather than INVALID_OPERATION to comply to the WebGL spec. Updated
              uniform-location-expected.txt to incorporate the correct error.
              Tested in Safari and Chromium.
      
              * fast/canvas/webgl/null-uniform-location-expected.txt: Added.
              * fast/canvas/webgl/null-uniform-location.html: Added.
              * fast/canvas/webgl/script-tests/null-uniform-location.js: Added.
              (callUniformFunction):
              * fast/canvas/webgl/uniform-location-expected.txt:
      2010-04-03  Kenneth Russell  <kbr@google.com>
      
              Reviewed by Darin Fisher.
      
              Inconsistent failure modes from uniform[Matrix]* with null WebGLUniformLocation
              https://bugs.webkit.org/show_bug.cgi?id=36574
      
              Fixed bugs in JavaScript bindings for uniform[Matrix]* entry
              points causing them to throw exceptions rather than synthesize GL
              errors. Fixed the implementations to synthesize INVALID_VALUE
              rather than INVALID_OPERATION to comply to the WebGL spec. Updated
              uniform-location-expected.txt to incorporate the correct error.
              Tested in Safari and Chromium.
      
              Test: fast/canvas/webgl/null-uniform-location.html
      
              * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
              (WebCore::V8WebGLRenderingContext::getUniformCallback):
              (WebCore::vertexAttribAndUniformHelperf):
              (WebCore::uniformHelperi):
              (WebCore::uniformMatrixHelper):
              * html/canvas/WebGLRenderingContext.cpp:
              (WebCore::WebGLRenderingContext::uniform1f):
              (WebCore::WebGLRenderingContext::uniform1fv):
              (WebCore::WebGLRenderingContext::uniform1i):
              (WebCore::WebGLRenderingContext::uniform1iv):
              (WebCore::WebGLRenderingContext::uniform2f):
              (WebCore::WebGLRenderingContext::uniform2fv):
              (WebCore::WebGLRenderingContext::uniform2i):
              (WebCore::WebGLRenderingContext::uniform2iv):
              (WebCore::WebGLRenderingContext::uniform3f):
              (WebCore::WebGLRenderingContext::uniform3fv):
              (WebCore::WebGLRenderingContext::uniform3i):
              (WebCore::WebGLRenderingContext::uniform3iv):
              (WebCore::WebGLRenderingContext::uniform4f):
              (WebCore::WebGLRenderingContext::uniform4fv):
              (WebCore::WebGLRenderingContext::uniform4i):
              (WebCore::WebGLRenderingContext::uniform4iv):
              (WebCore::WebGLRenderingContext::uniformMatrix2fv):
              (WebCore::WebGLRenderingContext::uniformMatrix3fv):
              (WebCore::WebGLRenderingContext::uniformMatrix4fv):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57049 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a4aa05f3
    • abarth@webkit.org's avatar
      2010-04-02 Andy Estes <aestes@apple.com> · b4fefb8a
      abarth@webkit.org authored
              Reviewed by Adam Barth.
      
              Tests for https://bugs.webkit.org/show_bug.cgi?id=37008.
      
              * fast/events/popup-allowed-from-gesture-initiated-event-expected.txt: Added.
              * fast/events/popup-allowed-from-gesture-initiated-event.html: Added.
              * fast/events/popup-blocked-from-fake-button-click-expected.txt: Added.
              * fast/events/popup-blocked-from-fake-button-click.html: Added.
              * fast/events/popup-blocked-from-fake-focus-expected.txt: Added.
              * fast/events/popup-blocked-from-fake-focus.html: Added.
      2010-04-02  Andy Estes  <aestes@apple.com>
      
              Reviewed by Adam Barth.
      
              The previous mechanism for testing whether an event was due to a user
              gesture only checked the event type, not the source of the event.  This
              allowed scripts to defeat popup blocking by programatically emitting
              certain types of events.
      
              Change the user gesture detection to check for a flag that is only set
              when the event in question was generated through the platform and not
              through the DOM.
      
              https://bugs.webkit.org/show_bug.cgi?id=37008
      
              Tests: fast/events/popup-allowed-from-gesture-initiated-event.html
                     fast/events/popup-blocked-from-fake-button-click.html
                     fast/events/popup-blocked-from-fake-focus.html
      
              * Android.mk: Add UserGestureIndicator.{cpp, h}.
              * GNUmakefile.am: Same.
              * WebCore.gypi: Same.
              * WebCore.pro: Same.
              * WebCore.vcproj/WebCore.vcproj: Same.
              * WebCore.xcodeproj/project.pbxproj: Same.
              * bindings/v8/ScriptController.cpp:
              (WebCore::ScriptController::processingUserGesture): Check the value of
              UserGesureIndicator::processingUserGesture().
              * dom/Document.cpp:
              (WebCore::Document::createEvent): Remove call to
              Event::setCreatedByDOM().
              * dom/Event.cpp:
              (WebCore::Event::Event): Remove initializers for m_createdByDOM.
              (WebCore::Event::fromUserGesture): Check the value of
              UserGestureIndicator::processingUserGesture().
              * dom/Event.h: Remove m_createdByDOM.
              * dom/UserGestureIndicator.cpp: Added.
              (WebCore::UserGestureIndicator::UserGestureIndicator): Save the previous
              value of s_processingUserGesture before setting it to true.
              (WebCore::UserGestureIndicator::~UserGestureIndicator): Restore
              s_processingUserGesture to its previous value.
              * dom/UserGestureIndicator.h: Added.
              (WebCore::UserGestureIndicator::processingUserGesture): Return the value
              of s_processingUserGesture.
              * page/EventHandler.cpp:
              (WebCore::EventHandler::handleMousePressEvent): Instantiate a
              UserGestureIndicator object on the stack to indicate a user gesture is
              being processed.
              (WebCore::EventHandler::handleMouseDoubleClickEvent): Same.
              (WebCore::EventHandler::handleMouseReleaseEvent): Same.
              (WebCore::EventHandler::keyEvent): Same.
              (WebCore::EventHandler::handleTouchEvent): Same.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57045 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b4fefb8a
  4. 02 Apr, 2010 21 commits
    • abarth@webkit.org's avatar
      2010-04-02 Justin Schuh <jschuh@chromium.org> · 7a8fde5a
      abarth@webkit.org authored
              Reviewed by Alexey Proskuryakov.
      
              XHR allows arbitrary XSRF across domains
              https://bugs.webkit.org/show_bug.cgi?id=36843
      
              Added a one-line change to prevent bypassing the XDC check on
              synchronous preflighted requests. Added layout tests to cover
              variations of this problem.
      
              * http/tests/xmlhttprequest/access-control-preflight-async-header-denied-expected.txt: Added.
              * http/tests/xmlhttprequest/access-control-preflight-async-header-denied.html: Added.
              * http/tests/xmlhttprequest/access-control-preflight-async-method-denied-expected.txt: Added.
              * http/tests/xmlhttprequest/access-control-preflight-async-method-denied.html: Added.
              * http/tests/xmlhttprequest/access-control-preflight-sync-header-denied-expected.txt: Added.
              * http/tests/xmlhttprequest/access-control-preflight-sync-header-denied.html: Added.
              * http/tests/xmlhttprequest/access-control-preflight-sync-method-denied-expected.txt: Added.
              * http/tests/xmlhttprequest/access-control-preflight-sync-method-denied.html: Added.
              * http/tests/xmlhttprequest/resources/access-control-preflight-denied-xsrf.php: Added.
      2010-04-02  Justin Schuh  <jschuh@chromium.org>
      
              Reviewed by Alexey Proskuryakov.
      
              XHR allows arbitrary XSRF across domains
              https://bugs.webkit.org/show_bug.cgi?id=36843
      
              Added a one-line change to prevent bypassing the XDC check on
              synchronous preflighted requests. Added layout tests to cover
              variations of this problem.
      
              Tests: http/tests/xmlhttprequest/access-control-preflight-async-header-denied.html
                     http/tests/xmlhttprequest/access-control-preflight-async-method-denied.html
                     http/tests/xmlhttprequest/access-control-preflight-sync-header-denied.html
                     http/tests/xmlhttprequest/access-control-preflight-sync-method-denied.html
      
              * loader/DocumentThreadableLoader.cpp:
              (WebCore::DocumentThreadableLoader::preflightFailure):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57041 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7a8fde5a
    • simon.fraser@apple.com's avatar
      2010-04-02 Simon Fraser <simon.fraser@apple.com> · 63b06ae8
      simon.fraser@apple.com authored
              Reviewed by Darin Adler.
      
              Very bad scrolling-performance with the Trackpad at http://www.apple.com/ipad/app-store/
              https://bugs.webkit.org/show_bug.cgi?id=36978
      
              When we update compositing layers (which can happen on scrolling, when there are fixed position elements
              on the page), we can end up redundantly setting images as layer contents if we have to color-correct
              the image. This is because we call CGImageCreateCopyWithColorSpace(), which hands back a new image
              every time.
      
              Avoid this by storing a reference to the original uncorrected image, which is used to then
              avoid work if the image does not change.
      
              * platform/graphics/mac/GraphicsLayerCA.h:
              * platform/graphics/mac/GraphicsLayerCA.mm:
              (WebCore::GraphicsLayerCA::setContentsToImage):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57039 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      63b06ae8
    • eric@webkit.org's avatar
      2010-04-02 Nayan Kumar K <nayankk@gmail.com> · 26ef9bee
      eric@webkit.org authored
              Reviewed by Eric Seidel.
      
              Fix for WML enabled build failure.
      
              https://bugs.webkit.org/show_bug.cgi?id=36648
      
              * wml/WMLOptionElement.cpp:
              (WebCore::WMLOptionElement::disabled):
              * wml/WMLOptionElement.h:
              * wml/WMLSelectElement.cpp:
              (WebCore::WMLSelectElement::listBoxSelectItem):
              * wml/WMLSelectElement.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57038 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      26ef9bee
    • eric@webkit.org's avatar
      2010-04-02 MORITA Hajime <morrita@google.com> · 663af777
      eric@webkit.org authored
              Reviewed by Alexey Proskuryakov.
      
              https://bugs.webkit.org/show_bug.cgi?id=37011
              Position::primaryDirection() should not use its own accessor.
      
              No new tests. This is small clenaup with no behaviour change.
      
              * dom/Position.cpp:
              (WebCore::Position::primaryDirection):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57037 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      663af777
    • eric@webkit.org's avatar
      2010-04-02 Eric Uhrhane <ericu@chromium.org> · dbee62b3
      eric@webkit.org authored
              Reviewed by Brady Eidson.
      
              window.openDatabase() always fails for new databases when using WebKit nightly with Safari 4.0.5.  This is caused by a SecurityOrigin pointer comparison that I should have switched to be a hash comparison in r56293 [bug 34991].
              https://bugs.webkit.org/show_bug.cgi?id=36671
      
              No new tests.  Requires testing on Safari on Windows.
      
              * storage/DatabaseTracker.cpp:
              (WebCore::DatabaseTracker::fullPathForDatabaseNoLock): Convert a pointer comparison to use SecurityOriginHash::hash() instead, and move it to the end of the clause for speed in the easy-out case.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57036 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      dbee62b3
    • eric@webkit.org's avatar
      2010-04-02 Michael Nordman <michaeln@google.com> · 7c7b0955
      eric@webkit.org authored
              Reviewed by Nate Chapin.
      
              Set the close policy used by the DatabaseCloseTask in a constructor argument
              instead of hard coding it.
              https://bugs.webkit.org/show_bug.cgi?id=37037
      
              No new tests, new new functionality.
      
              * storage/Database.cpp: This callsite passes in DoNotRemoveFromDatabaseContext to retain its current behavior.
              (WebCore::Database::markAsDeletedAndClose):
              * storage/DatabaseTask.cpp:
              (WebCore::DatabaseCloseTask::DatabaseCloseTask):
              (WebCore::DatabaseCloseTask::doPerformTask):
              * storage/DatabaseTask.h:
              (WebCore::DatabaseCloseTask::create):
      2010-04-02  Michael Nordman  <michaeln@google.com>
      
              Reviewed by Nate Chapin.
      
              Set the close policy used by the DatabaseCloseTask at this callsite to
              RemoveDatabaseFromContext. This restores its behavior to what it was prior to
              r56293.
              https://bugs.webkit.org/show_bug.cgi?id=37037
      
              * src/WebDatabase.cpp:
              (WebKit::WebDatabase::closeDatabaseImmediately):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57034 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7c7b0955
    • jamesr@google.com's avatar
      2010-04-02 James Robinson <jamesr@chromium.org> · c43f0de4
      jamesr@google.com authored
              Reviewed by Simon Fraser.
      
              Remove an ASSERT that sometimes flakes due to time dependent animations
              https://bugs.webkit.org/show_bug.cgi?id=37048
      
              The outline repaint rectangle for a layer might change between two calls
              if there are animations involved, even if nothing in the DOM has actually
              changed between the calls.
      
              No change in behavior, no new tests.
      
              * rendering/RenderLayer.cpp:
              (WebCore::RenderLayer::updateLayerPositions):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57033 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c43f0de4
    • abarth@webkit.org's avatar
      2010-04-02 Evan Stade <estade@chromium.org> · de5779b6
      abarth@webkit.org authored
              Reviewed by Adam Barth.
      
              [chromium] need DragImage implementation
              https://bugs.webkit.org/show_bug.cgi?id=35811
      
              Add two files that failed to get added in my previous patch.
      
              * platform/chromium/DragImageChromiumMac.cpp: Added.
              (WebCore::dragImageSize):
              (WebCore::deleteDragImage):
              (WebCore::scaleDragImage):
              (WebCore::dissolveDragImageToFraction):
              (WebCore::createDragImageFromImage):
              (WebCore::createDragImageIconForCachedImage):
              * platform/chromium/DragImageChromiumSkia.cpp: Added.
              (WebCore::dragImageSize):
              (WebCore::deleteDragImage):
              (WebCore::scaleDragImage):
              (WebCore::dissolveDragImageToFraction):
              (WebCore::createDragImageFromImage):
              (WebCore::createDragImageIconForCachedImage):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57032 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      de5779b6
    • eric.carlson@apple.com's avatar
      2010-04-02 Jer Noble <jer.noble@apple.com> · ebcff5e1
      eric.carlson@apple.com authored
              Reviewed by Eric Carlson.
      
              Configure multi-language movies: when QuickTime has sufficiently loaded
              the movie, call into wkQTMovieSelectPreferredAlternates to select the
              movie's alternate tracks according to the user's language preferences.
      
              https://bugs.webkit.org/show_bug.cgi?id=36624
      
              * WebCore.base.exp:
              * platform/graphics/mac/MediaPlayerPrivateQTKit.mm: 
              (WebCore::MediaPlayerPrivate::updateStates): If the movie is sufficiently loaded,
              call wkQTMovieSelectPreferredAlternates to set up the alternate tracks.
              * platform/mac/WebCoreSystemInterface.h: Declare WKQTMovieSelectPreferredAlternates.
              * platform/mac/WebCoreSystemInterface.mm: Add WKQTMovieSelectPreferredAlternates.
      
      2010-04-02  Jer Noble  <jer.noble@apple.com>
      
              Reviewed by Eric Carlson.
              
              https://bugs.webkit.org/show_bug.cgi?id=36624
      
              Update WebKitSystemInterface
      
              * WebKitSystemInterface.h: add WKQTMovieSelectPreferredAlternates.
              * libWebKitSystemInterfaceLeopard.a:
              * libWebKitSystemInterfaceSnowLeopard.a:
              * libWebKitSystemInterfaceTiger.a:
      
      2010-04-02  Jer Noble  <jer.noble@apple.com>
      
              Reviewed by Eric Carlson.
      
              https://bugs.webkit.org/show_bug.cgi?id=36624
              Add an INIT macro for the WebKitSystemInterface function wkQTMovieSelectPreferredAlternates.
      
              * WebCoreSupport/WebSystemInterface.m:
              (InitWebCoreSystemInterface):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57031 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ebcff5e1
    • jamesr@google.com's avatar
      2010-04-02 James Robinson <jamesr@chromium.org> · 19548ad3
      jamesr@google.com authored
              Reviewed by Darin Adler.
      
              Splits RenderBlock::layoutInline into smaller functions
              https://bugs.webkit.org/show_bug.cgi?id=36921
      
              RenderBlock::layoutInlineChildren is 351 lines long and very difficult
              to comprehend or edit safely. This patch splits it up into a few
              slightly smaller functions.  Most of the code is now in the 241 line
              layoutRunsAndFloats() which is a slight improvement.
      
              Perf neutral on the page cyclers.  This doesn't introduce any function
              calls into the hottest layout paths inside layoutRunsAndFloats and
              findNextLineBreak.
      
              No change in behavior, no new tests.
      
              * rendering/RenderBlock.h:
              (WebCore::RenderBlock::FloatWithRect::FloatWithRect):
              * rendering/RenderBlockLineLayout.cpp:
              (WebCore::RenderBlock::layoutReplacedElements):
              (WebCore::RenderBlock::createLineBoxesForResolver):
              (WebCore::RenderBlock::layoutRunsAndFloats):
              (WebCore::RenderBlock::layoutInlineChildren):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57030 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      19548ad3
    • eric@webkit.org's avatar
      2010-04-02 Evan Stade <estade@chromium.org> · 6ae9603a
      eric@webkit.org authored
              Reviewed by Eric Seidel.
      
              [chromium] need DragImage implementation
              https://bugs.webkit.org/show_bug.cgi?id=35811
      
              Basic implementation using SkBitmap. Transformations are not supported
              yet. No implementation for mac.
      
              * WebCore.gyp/WebCore.gyp:
              * WebCore.gypi:
              * platform/chromium/DragImageChromium.cpp:
              * platform/chromium/DragImageRef.h:
      2010-04-02  Evan Stade  <estade@chromium.org>
      
              Reviewed by Eric Seidel.
      
              [chromium] need DragImage implementation
              https://bugs.webkit.org/show_bug.cgi?id=35811
      
              Use the DragImageRef that the DragController passes to us.
      
              * public/WebViewClient.h:
              (WebKit::WebViewClient::startDragging):
              * src/DragClientImpl.cpp:
              (WebKit::DragClientImpl::startDrag):
              * src/WebViewImpl.cpp:
              (WebKit::WebViewImpl::startDragging):
              * src/WebViewImpl.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57028 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6ae9603a
    • eric@webkit.org's avatar
      2010-04-02 Evan Martin <evan@chromium.org> · ad7819be
      eric@webkit.org authored
              Reviewed by Eric Seidel.
      
              [chromium] font fallback for generic fonts picks wrong font
              https://bugs.webkit.org/show_bug.cgi?id=37033
      
              When a page specifies the generic "monospace" font and the user's
              browser-configured monospace font doesn't exist, we previously relied
              on getLastResortFallbackFont to eventually pick a monospace font for us.
      
              But that doesn't quite work: WebKit first falls back to the user's
              "preferred standard font" before hitting the last resort code path.
              So if the above conditions hold but this font exists, we'll end up
              never hitting the last resort codepath.
      
              The fix is to allow OS-level font fallback when first attempting to
              resolve monospace.  The existing code tried to do this, but the logic
              was wrong.  We would eventually fall back to the correct font anyway
              so we didn't notice the logic was wrong.
      
              This code is all handling cases where particular fonts aren't installed,
              so I can't think of a way to test it; existing tests should still pass.
      
              * platform/graphics/chromium/FontCacheLinux.cpp:
              (WebCore::FontCache::createFontPlatformData):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57027 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ad7819be
    • scherkus@chromium.org's avatar
      2010-04-02 Andrew Scherkus <scherkus@chromium.org> · e479546e
      scherkus@chromium.org authored
              Reviewed by Eric Carlson and Eric Seidel.
      
              Don't stop the playback event timer when media resource loading has suspended.
              https://bugs.webkit.org/show_bug.cgi?id=37003
      
              When a user agent decides to suspend media resource loading and enters the
              NETWORK_IDLE state we are supposed to only stop the progress event timer but
              keep the playback timer running.
      
              Test: http/tests/media/video-play-suspend.html
      
              * html/HTMLMediaElement.cpp:
              (WebCore::HTMLMediaElement::setNetworkState): Only stop the progress event timer.
      
      2010-04-02  Andrew Scherkus  <scherkus@chromium.org>
      
              Reviewed by Eric Carlson and Eric Seidel.
      
              Don't stop the playback event timer when media resource loading has suspended.
              https://bugs.webkit.org/show_bug.cgi?id=37003
      
              When a user agent decides to suspend media resource loading and enters the
              NETWORK_IDLE state we are supposed to only stop the progress event timer but
              keep the playback timer running.
      
              Currently Chromium is the only platform that fires the suspend event
              hence most platforms skipping this test.
      
              * http/tests/media/video-play-suspend-expected.txt: Added.
              * http/tests/media/video-play-suspend.html: Added.
              * platform/gtk/Skipped: Doesn't fire a suspend event.
              * platform/mac/Skipped: Ditto.
              * platform/win/Skipped: Ditto.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57023 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e479546e
    • darin@apple.com's avatar
      Fix mispelling that broke the build. · 9a7b1ead
      darin@apple.com authored
      * html/canvas/CanvasRenderingContext2D.cpp:
      * html/canvas/CanvasRenderingContext2D.h:
      Dashbard -> Dashboard.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57022 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9a7b1ead
    • levin@chromium.org's avatar
      (non-generated) code should only use CanvasRenderingContext::canvas as a CanvasSurface. · 61fc3bb1
      levin@chromium.org authored
      https://bugs.webkit.org/show_bug.cgi?id=36906
      
      Reviewed by Darin Adler.
      
      WebCore:
      
      * dom/CanvasSurface.cpp: Added methods for items that depended on
      CanvasRenderingContext::canvas() being an HTMLElement(), so that this usage
      can be dealt with in one place.
      (WebCore::CanvasSurface::securityOrigin): Only used by methods that are
      only run in the document context.
      (WebCore::CanvasSurface::renderBox): Will likely return 0 in a worker context.
      (WebCore::CanvasSurface::computedStyle): Used by setFont. Return value is TBD for
      the worker context.
      (WebCore::CanvasSurface::styleSelector): Ditto.
      * dom/CanvasSurface.h:
      * html/HTMLCanvasElement.cpp:
      (WebCore::HTMLCanvasElement::getContext): Passing in information into
      the CanvasRenderingContext2D constructor to eliminate some uses of document
      inside of the CanvasRenderingContext2D class.
      * html/HTMLCanvasElement.h:
      (WebCore::HTMLCanvasElement::renderBox): Added to disambiguate between the
      two parent class versions of the method.
      (WebCore::HTMLCanvasElement::computedStyle): Ditto.
      * html/canvas/CanvasRenderingContext2D.cpp: All of these changes are about
      removing document usage either by using a bool that is set in the constructor or
      by calling one of the new methods added to CanvasSurface.
      (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
      (WebCore::CanvasRenderingContext2D::clearPathForDashboardBackwardCompatibilityMode):
      (WebCore::CanvasRenderingContext2D::checkOrigin):
      (WebCore::CanvasRenderingContext2D::prepareGradientForDashboard):
      (WebCore::CanvasRenderingContext2D::createPattern):
      (WebCore::CanvasRenderingContext2D::setFont):
      (WebCore::CanvasRenderingContext2D::drawTextInternal):
      * html/canvas/CanvasRenderingContext2D.h:
      * html/canvas/WebGLRenderingContext.cpp: Removed some duplicate includes.
      (WebCore::WebGLRenderingContext::markContextChanged): Reduced calls to renderBox
       as it may become slightly more expensive in the future.
      (WebCore::WebGLRenderingContext::reshape): Ditto.
      
      LayoutTests:
      
      * fast/canvas/script-tests/canvas-gradient-addStop-error.js: Changed the test
      to create a new canvas after switching to dashboard compatiblity mode, which is
      needed now that the compatibility mode is cached in the canvas.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57020 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      61fc3bb1
    • eric@webkit.org's avatar
      2010-04-02 Zhenyao Mo <zmo@google.com> · 326c1776
      eric@webkit.org authored
              Reviewed by Eric Seidel.
      
              Implement and test new framebuffer object attachment behavior.
              https://bugs.webkit.org/show_bug.cgi?id=35611
      
              * fast/canvas/webgl/framebuffer-object-attachment-expected.txt: Added, test framebuffer object attachment behavior.
              * fast/canvas/webgl/framebuffer-object-attachment.html: Added, framebuffer object attachment behavior.
              * fast/canvas/webgl/script-tests/gl-object-get-calls.js: DEPTH_COMPONENT is no longer a valid input, use DEPTH_COMPONENT16 instead.
              * platform/mac-snowleopard/Skipped: The bot does not support EXT_packed_depth_stencil, skip the framebuffer-object-attachment.html test.
      2010-04-02  Zhenyao Mo  <zmo@google.com>
      
              Reviewed by Eric Seidel.
      
              Implement and test new framebuffer object attachment behavior.
              https://bugs.webkit.org/show_bug.cgi?id=35611
      
              Test: fast/canvas/webgl/framebuffer-object-attachment.html
      
              * html/canvas/WebGLFramebuffer.cpp: Keep track of attached stencil/depth renderbuffers in WebGLFramebuffer.
              (WebCore::WebGLFramebuffer::WebGLFramebuffer):
              (WebCore::WebGLFramebuffer::setIsAttached):
              * html/canvas/WebGLFramebuffer.h: Ditto.
              (WebCore::WebGLFramebuffer::isDepthAttached):
              (WebCore::WebGLFramebuffer::isStencilAttached):
              (WebCore::WebGLFramebuffer::isDepthStencilAttached):
              * html/canvas/WebGLRenderbuffer.cpp: Keep track of internalformat.
              (WebCore::WebGLRenderbuffer::WebGLRenderbuffer):
              * html/canvas/WebGLRenderbuffer.h: Ditto.
              (WebCore::WebGLRenderbuffer::setInternalformat):
              (WebCore::WebGLRenderbuffer::getInternalformat):
              * html/canvas/WebGLRenderingContext.cpp:
              (WebCore::WebGLRenderingContext::framebufferRenderbuffer): Detect stencil/depth buffer conflicts.
              (WebCore::WebGLRenderingContext::getFramebufferAttachmentParameter): Handling DEPTH_STENCIL case.
              (WebCore::WebGLRenderingContext::getRenderbufferParameter): Get correct WebGL internalformat.
              (WebCore::WebGLRenderingContext::renderbufferStorage): Detect illegal enums.
              * html/canvas/WebGLRenderingContext.idl: Add DEPTH_STENCIL enums.
              * platform/graphics/GraphicsContext3D.h: Add DEPTH_STENCIL enums.
              (WebCore::GraphicsContext3D::):
              * platform/graphics/mac/GraphicsContext3DMac.cpp: Map to correct DEPTH_STENCIL format.
              (WebCore::GraphicsContext3D::framebufferRenderbuffer):
              (WebCore::GraphicsContext3D::renderbufferStorage):
              (WebCore::GraphicsContext3D::getFramebufferAttachmentParameteriv):
      2010-04-02  Zhenyao Mo  <zmo@google.com>
      
              Reviewed by Eric Seidel.
      
              Implement and test new framebuffer object attachment behavior.
              https://bugs.webkit.org/show_bug.cgi?id=35611
      
              Test: fast/canvas/webgl/framebuffer-object-attachment.html
      
              * src/WebGraphicsContext3DDefaultImpl.cpp: Map to correct DEPTH_STENCIL format.
              (WebKit::WebGraphicsContext3DDefaultImpl::framebufferRenderbuffer):
              (WebKit::WebGraphicsContext3DDefaultImpl::getFramebufferAttachmentParameteriv):
              (WebKit::WebGraphicsContext3DDefaultImpl::renderbufferStorage):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57018 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      326c1776
    • tkent@chromium.org's avatar
      2010-04-02 Kent Tamura <tkent@chromium.org> · e98f3226
      tkent@chromium.org authored
              Reviewed by Darin Adler.
      
              Form control state shouldn't be restored for hidden inputs.
              https://bugs.webkit.org/show_bug.cgi?id=26241
      
              * fast/forms/button-state-restore.html: Updated for the behavior change.
              * fast/forms/state-restore-to-non-edited-controls-expected.txt: Added.
              * fast/forms/state-restore-to-non-edited-controls.html: Added.
      2010-04-02  Kent Tamura  <tkent@chromium.org>
      
              Reviewed by Darin Adler.
      
              Form control state shouldn't be restored for hidden inputs.
              https://bugs.webkit.org/show_bug.cgi?id=26241
      
              To fix this issue, we don't save values if it is not changed from
              the default value.
      
              Updating the value IDL attribute of some controls such as
              type=hidden also updates the value content attribute, and it's
              impossible to distinguish the initial value and the current
              value. The values of such controls are not saved. It won't be a
              problem because we want to save and restore user-edited values.
      
              Test: fast/forms/state-restore-to-non-edited-controls.html
      
              * html/HTMLInputElement.cpp:
              (WebCore::HTMLInputElement::saveFormControlState):
                Do not save the value if it is same as the default value.
              * html/HTMLTextAreaElement.cpp:
              (WebCore::HTMLTextAreaElement::saveFormControlState): ditto.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57013 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e98f3226
    • eric@webkit.org's avatar
      2010-04-02 Kent Tamura <tkent@chromium.org> · f264f75f
      eric@webkit.org authored
              Reviewed by Darin Adler.
      
              Forms with autocomplete=off should not consume saved state
              https://bugs.webkit.org/show_bug.cgi?id=36762
      
              * fast/forms/state-restore-to-non-autocomplete-form-expected.txt: Added.
              * fast/forms/state-restore-to-non-autocomplete-form.html: Added.
      2010-04-02  Kent Tamura  <tkent@chromium.org>
      
              Reviewed by Darin Adler.
      
              Forms with autocomplete=off should not consume saved state
              https://bugs.webkit.org/show_bug.cgi?id=36762
      
              Introduce Element::shouldSaveAndRestoreFormControlState() to check
              if we should save and restore control state.
      
              Test: fast/forms/state-restore-to-non-autocomplete-form.html
      
              * dom/Document.cpp:
              (WebCore::Document::formElementsState): Check shouldSaveAndRestoreFormControlState().
              * dom/Element.h:
              (WebCore::Element::shouldSaveAndRestoreFormControlState): Added. It just returns true.
              * html/HTMLFormControlElement.cpp:
              (WebCore::HTMLFormControlElementWithState::autoComplete):
                Added. It return autocomplete state of the form.
              (WebCore::HTMLFormControlElementWithState::shouldSaveAndRestoreFormControlState):
                Added. It returns the result of autoComplete().
              (WebCore::HTMLFormControlElementWithState::finishParsingChildren):
                Do not restore state if shouldSaveAndRestoreFormControlState() is false.
              * html/HTMLFormControlElement.h: Declare autoComplete() and overriding methods.
              * html/HTMLInputElement.cpp:
              (WebCore::HTMLInputElement::autoComplete):
                Reduce code by using autoComplete() of the parent class.
              (WebCore::HTMLInputElement::saveFormControlState):
                Remove the autoComplete() check. Document::formElementsState() does equivalent check.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57012 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f264f75f
    • simon.fraser@apple.com's avatar
      2010-04-02 Simon Fraser <simon.fraser@apple.com> · c5305659
      simon.fraser@apple.com authored
              Reviewed by Darin Adler.
      
              Avoid doing work in FrameView::scrollPositionChanged() if there are no fixed position elements
              https://bugs.webkit.org/show_bug.cgi?id=36994
      
              r55890 added knowledge to FrameView about whether it contains any fixed-position elements. We can
              use this to avoid updating widget positions, and compositing layer positions when possible.
      
              * page/FrameView.cpp:
              (WebCore::FrameView::scrollPositionChanged):
              * page/FrameView.h:
              (WebCore::FrameView::hasFixedObjects):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57009 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c5305659
    • japhet@chromium.org's avatar
      2010-04-02 Nate Chapin <japhet@chromium.org> · 537ed4db
      japhet@chromium.org authored
              Rubber-stamped by Dimitri Glazkov.
      
              http://trac.webkit.org/changeset/57004 caused
              fast/dom/console-log-stack-overflow.html to fail for Chromium.
              Add check for empty wrappers before using them to create a hidden reference.
      
              * bindings/scripts/CodeGeneratorV8.pm:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57008 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      537ed4db
    • japhet@chromium.org's avatar
      2010-04-01 Nate Chapin <japhet@chromium.org> · 8b875afa
      japhet@chromium.org authored
              Reviewed by Dimitri Glazkov.
      
              [V8] Generalize (and generate!) the creation of hidden references
              between JS wrappers.
              
              https://bugs.webkit.org/show_bug.cgi?id=36777
      
              * Android.v8bindings.mk:
              * WebCore.gypi:
              * bindings/scripts/CodeGeneratorV8.pm: Generate calls to setHiddenReference() in
              attribute getters.
              * bindings/v8/V8DOMWrapper.cpp:
              (WebCore::V8DOMWrapper::setHiddenReference): Split common logic out of hidden setHiddenWindowReference
              (WebCore::V8DOMWrapper::setHiddenWindowReference): Now contains logic specific to putting a 
              hidden reference on a global object.
              (WebCore::globalObjectPrototypeIsDOMWindow): Be more thorough in the COMPILE_ASSERTs.
              (WebCore::V8DOMWrapper::convertEventTargetToV8Object): Cleanup: Remove a duplicate if statement.
              * bindings/v8/V8DOMWrapper.h:
              * bindings/v8/WrapperTypeInfo.h:
              * bindings/v8/custom/V8BarInfoCustom.cpp: Removed.
              * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
              (WebCore::toV8):
              * bindings/v8/custom/V8DOMSelectionCustom.cpp: Removed.
              * bindings/v8/custom/V8HistoryCustom.cpp:
              * bindings/v8/custom/V8LocationCustom.cpp:
              * bindings/v8/custom/V8MessageChannelConstructor.cpp:
              (WebCore::V8MessageChannel::constructorCallback):
              * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
              (WebCore::toV8):
              * bindings/v8/custom/V8NavigatorCustom.cpp: Removed.
              * bindings/v8/custom/V8ScreenCustom.cpp: Removed.
              * bindings/v8/custom/V8StyleSheetCustom.cpp:
              (WebCore::toV8):
              * loader/appcache/DOMApplicationCache.h:
              (WebCore::DOMApplicationCache::frame): Add frame() accessor.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57004 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8b875afa