The content of the DOM panel for iframes is not updated until the "onload" event
https://bugs.webkit.org/show_bug.cgi?id=122653

Reviewed by Darin Adler.

Source/WebCore:

Test: http/tests/inspector-protocol/loading-iframe-document-node.html

Renamed InspectorDOMAgent::loadEventFired to InspectorDOMAgent::didCommitLoad and moved the call site
from InspectorInstrumentation::loadEventFiredImpl to InspectorInstrumentation::didCommitLoadImpl.
This is to make sure that it will invalidate the content of the iframe as soon as the frame navigates
to a different page. This way the new node can be retrieved as soon as the page has some content, and
not just when the page is fully loaded.

* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::didCommitLoad): Renamed from loadEventFired, as it is now called from
didCommitLoadImpl instead.
(WebCore::InspectorDOMAgent::frameDocumentUpdated): Updated comment to point to the new function name.
* inspector/InspectorDOMAgent.h:
* inspector/InspectorInstrumentation.cpp:
(WebCore::InspectorInstrumentation::loadEventFiredImpl): Removed call do InspectorDOMAgent.loadEventFired.
(WebCore::InspectorInstrumentation::didCommitLoadImpl): Added call to InspectorDOMAgent.didCommitLoad.

LayoutTests:

Added test to check that immediately after the scripting context is created, the
inspector already has access to the nodeId of the document of the iframe.

* http/tests/inspector-protocol/loading-iframe-document-node-expected.txt: Added.
* http/tests/inspector-protocol/loading-iframe-document-node.html: Added.
* http/tests/inspector-protocol/resources/slow-test-page.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157425 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build fix after r157366
http://bugs.webkit.org/show_bug.cgi?id=122783

When TOUCH_AJUSTMENT is enabled build fails due to some
refactors in TextRender functions.

Patch by Nick Diego Yamane <nick.yamane@openbossa.org> on 2013-10-14
Reviewed by Anders Carlsson.

* page/TouchAdjustment.cpp:
(WebCore::TouchAdjustment::appendContextSubtargetsForNode):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157426 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[sh4] Fixes after r157404 and r157411.
https://bugs.webkit.org/show_bug.cgi?id=122782

Patch by Julien Brianceau <jbriance@cisco.com> on 2013-10-14
Reviewed by Michael Saboff.

* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperation): Add missing SH4_32BIT_DUMMY_ARG.
* jit/CCallHelpers.h:
(JSC::CCallHelpers::setupArgumentsWithExecState):
* jit/JITInlines.h:
(JSC::JIT::callOperation): Add missing SH4_32BIT_DUMMY_ARG.
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::emit_op_put_by_id): Remove unwanted BEGIN_UNINTERRUPTED_SEQUENCE.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157427 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove GestureEvent leftovers from WebCore
<https://webkit.org/b/122780>

Patch by Nick Diego Yamane <nick.yamane@openbossa.org> on 2013-10-14
Reviewed by Anders Carlsson.

- Removed some remaining references to PlatformGestureEvent, supposed to
  be removed by r157316
- TOUCH_ADJUSTMENT should be reworked after GestureEvent feature
  removal

* page/EventHandler.cpp:
(WebCore::EventHandler::bestZoomableAreaForTouchPoint):
* page/EventHandler.h:
* platform/PlatformEvent.h:
* platform/ScrollAnimatorNone.cpp:
* platform/ScrollableArea.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157428 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add FTL support for LogicalNot(string)
https://bugs.webkit.org/show_bug.cgi?id=122765

Patch by Nadav Rotem <nrotem@apple.com> on 2013-10-14
Reviewed by Filip Pizlo.

This patch is tested by:
regress/script-tests/emscripten-cube2hash.js.ftl-eager

* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileLogicalNot):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157429 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add an empty window.crypto.webkitSubtle
https://bugs.webkit.org/show_bug.cgi?id=122778

Reviewed by Mark Hahnenberg.

Source/WebCore:

Tests: security/crypto-subtle-gc-2.html
       security/crypto-subtle-gc-3.html
       security/crypto-subtle-gc.html

* DerivedSources.make: Process SubtleCrypto.idl.

* crypto: Added.
* WebCore.xcodeproj/project.pbxproj:
* CMakeLists.txt:
* DerivedSources.make:
* GNUmakefile.am:
* GNUmakefile.list.am:
* WebCore.vcxproj/WebCore.vcxproj.filters:

* bindings/js/JSSubtleCryptoCustom.cpp: Added. Empty for now, but we'll certainly
need custom bindings code here.

* crypto/SubtleCrypto.cpp: Added.
(WebCore::SubtleCrypto::SubtleCrypto):
(WebCore::SubtleCrypto::document):
* crypto/SubtleCrypto.h: Added.
* crypto/SubtleCrypto.idl: Added.
* page/Crypto.cpp:
(WebCore::Crypto::subtle):
* page/Crypto.h:
* page/Crypto.idl:

LayoutTests:

* TestExpectations: The feature isn't enabled anywhere yet, so skipping the new tests.

* security/crypto-subtle-gc-2-expected.txt: Added.
* security/crypto-subtle-gc-2.html: Added.
* security/crypto-subtle-gc-3-expected.txt: Added.
* security/crypto-subtle-gc-3.html: Added.
* security/crypto-subtle-gc-expected.txt: Added.
* security/crypto-subtle-gc.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157430 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Assertion failure in Range::processContentsBetweenOffsets
https://bugs.webkit.org/show_bug.cgi?id=122777

Reviewed by Darin Adler.

Source/WebCore: 

Merge https://chromium.googlesource.com/chromium/blink/+/c15de182774c7859c20d97126eb844ae97b792a4

This patch changes ASSERT statements for checking |endOffset| inbound in Range::processContentsBetweenOffsets()
to limit |endOffset|. This is necessary when DOMNodeRemovedFromDocument event handler splits text nodes,
Range::insertNode() on text node, in the range calling Range::deleteContents().

Test: fast/dom/Range/range-delete-contents-mutation-event-crash.html

* dom/Range.cpp:
(WebCore::Range::processContentsBetweenOffsets):

LayoutTests: 

* fast/dom/Range/range-delete-contents-mutation-event-crash-expected.txt: Added.
* fast/dom/Range/range-delete-contents-mutation-event-crash.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157431 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Windows] Unreviewed build fix.

* WebCore.vcxproj/WebCoreCommon.props:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157432 268f45cc-cd09-0410-ab3c-d52691b4dbfc
DFG PutById IC should use the ConcurrentJITLocker since it's now dealing with IC's that get read by the compiler thread
https://bugs.webkit.org/show_bug.cgi?id=122786

Reviewed by Mark Hahnenberg.

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::resetStub): Resetting a stub should acquire the lock since this is observable from the thread; but we should only acquire the lock if we're resetting outside of GC.
* jit/Repatch.cpp:
(JSC::repatchPutByID): Doing the PutById patching should hold the lock.
(JSC::buildPutByIdList): Ditto.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157433 268f45cc-cd09-0410-ab3c-d52691b4dbfc
AX: fieldset should have GroupRole and legend should be description.
https://bugs.webkit.org/show_bug.cgi?id=122534

Patch by Samuel White <samuel_white@apple.com> on 2013-10-14
Reviewed by Chris Fleizach.

Source/WebCore:

Changes fieldset to derive AXDescription from legend if one is available. Added
convenience method to AccessibilityObject to fetch element if available.

Test: accessibility/fieldset-element.html

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::canHaveChildren):
(WebCore::AccessibilityNodeObject::alternativeText):
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::element):
(WebCore::AccessibilityObject::isARIAHidden):
(WebCore::AccessibilityObject::isDOMHidden):
(WebCore::AccessibilityObject::defaultObjectInclusion):
* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::isHidden):
* accessibility/AccessibilitySlider.cpp:
(WebCore::AccessibilitySlider::getAttribute):
(WebCore::AccessibilitySlider::valueForRange):
(WebCore::AccessibilitySlider::maxValueForRange):
(WebCore::AccessibilitySlider::minValueForRange):
(WebCore::AccessibilitySlider::setValue):
(WebCore::AccessibilitySlider::inputElement):
* accessibility/AccessibilitySlider.h:
* accessibility/mac/AccessibilityObjectMac.mm:
(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
* html/HTMLFieldSetElement.cpp:
(WebCore::HTMLFieldSetElement::legend):
* html/HTMLFieldSetElement.h:

LayoutTests:

legend no longer treated as titleUIElement so removing tests that check this functionality.
Added test to check that legend is used as AXDescription of fieldset if present.

* accessibility/fieldset-element.html: Added.
* accessibility/hidden-legend-expected.txt: Removed.
* accessibility/hidden-legend.html: Removed.
* accessibility/legend.html: Removed.
* platform/efl/accessibility/legend-expected.txt: Removed.
* platform/gtk/accessibility/legend-expected.txt: Removed.
* platform/mac/accessibility/fieldset-element-expected.txt: Added.
* platform/mac/accessibility/legend-expected.txt: Removed.
* platform/mac/accessibility/role-subrole-roledescription-expected.txt:
* platform/mac/accessibility/role-subrole-roledescription.html:

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