WebKit-https.git
7 years agoAdd general CMakeLists.txt for DRT
paroga@webkit.org [Fri, 27 Sep 2013 13:01:32 +0000 (13:01 +0000)]
Add general CMakeLists.txt for DRT
https://bugs.webkit.org/show_bug.cgi?id=119268

Reviewed by Gyuyoung Kim.

The new file allows better sharing between ports.

* CMakeLists.txt:
* DumpRenderTree/CMakeLists.txt: Added.
* DumpRenderTree/PlatformEfl.cmake: Added.
* DumpRenderTree/efl/CMakeLists.txt: Removed.

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

7 years agoUnexpected word wrapping for wrapped content then raw content.
zalan@apple.com [Fri, 27 Sep 2013 12:47:52 +0000 (12:47 +0000)]
Unexpected word wrapping for wrapped content then raw content.
https://bugs.webkit.org/show_bug.cgi?id=121130

Reviewed by Darin Adler.

When deciding whether a line is considered empty, we need to check if the current
object is fully responsible for the currently uncommitted width. It helps differentiating
<span></span><span>abcd</span> from <span>a</span><span>bcd</span>, where in the first
case when we hit the second <span> the line is still considered empty, as opposed to the
second example.
This patch introduces a map to keep track of the uncommitted widths.

Source/WebCore:

Test: fast/css/unexpected-word-wrapping-with-non-empty-spans.html

* rendering/LineWidth.cpp:
(WebCore::LineWidth::uncommittedWidthForObject):
(WebCore::LineWidth::addUncommittedWidth):
* rendering/LineWidth.h:
* rendering/RenderBlockLineLayout.cpp:
(WebCore::LineBreaker::nextSegmentBreak):

LayoutTests:

* fast/css/unexpected-word-wrapping-with-non-empty-spans-expected.html: Added.
* fast/css/unexpected-word-wrapping-with-non-empty-spans.html: Added.

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

7 years ago[Qt] Fix force_static_libs_as_shared in WebKit2
allan.jensen@digia.com [Fri, 27 Sep 2013 12:16:23 +0000 (12:16 +0000)]
[Qt] Fix force_static_libs_as_shared in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=121961

Reviewed by Csaba Osztrogonác.

Source/WebKit/qt:

* WebCoreSupport/QWebFrameAdapter.h:

Source/WebKit2:

Do not add strict ordering for webkit2qml. It is not needed and causes
Target.pri to be built out of order.

* WebKit2.pro:

Tools:

Reenable force_static_libs_as_shared when building WebKit2.

* qmake/mkspecs/features/default_post.prf:

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

7 years ago[Qt] Mock implementations of positioning and orientation not used
allan.jensen@digia.com [Fri, 27 Sep 2013 11:57:52 +0000 (11:57 +0000)]
[Qt] Mock implementations of positioning and orientation not used
https://bugs.webkit.org/show_bug.cgi?id=121956

Reviewed by Csaba Osztrogonác.

Move production_build checks to sanitizeFeatures where its value is actually known.

* qmake/mkspecs/features/features.prf:
* qmake/mkspecs/features/features.pri:

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

7 years ago[ATK] Protect entry points in the ATK wrapper against outdated render trees
mario@webkit.org [Fri, 27 Sep 2013 09:44:20 +0000 (09:44 +0000)]
[ATK] Protect entry points in the ATK wrapper against outdated render trees
https://bugs.webkit.org/show_bug.cgi?id=121558

Reviewed by Chris Fleizach.

Source/WebCore:

Make sure that we protect every entry point in the ATK wrapper
against outdated render trees, before using the WebCore's
accessibility API, since that might lead to problems (and crashes)
if the render and accessibility trees are not stable.

Thus, call AccessibilityObject::updateBackingStore() in those
entry points and check whether the ATK wrapper is detached or not
after that, to decide whether to continue or not.

Besides providing a new test to check that it WebKit does not
crash in a given scenario (which actually triggered the
investigation here), solving this situation also fixes other tests
that were previously failing (aria-used-on-image-maps.html) or
that were printing wrong results, not detected until now due to
wrong platform specific expectations (file-upload-button-stringvalue
and deleting-iframe-destroys-axcache).

Test: accessibility/heading-crash-after-hidden.html

* accessibility/atk/WebKitAccessibleUtil.h: Added two new macros
to inject the needed code at the beginning of each entry point to
allow gracefully exit those functions when the render tree is
unstable. Inspired by g_return_if_fail and g_return_val_if_fail, we
called them returnIfWebKitAccessibleIsInvalid and returnValIfWebKitAccessibleIsInvalid.

* accessibility/atk/WebKitAccessibleHyperlink.cpp:
(webkitAccessibleHyperlinkActionDoAction): Protect entry point.
(webkitAccessibleHyperlinkActionGetNActions): Ditto.
(webkitAccessibleHyperlinkActionGetDescription): Ditto.
(webkitAccessibleHyperlinkActionGetKeybinding): Ditto.
(webkitAccessibleHyperlinkActionGetName): Ditto.
(webkitAccessibleHyperlinkGetURI): Ditto.
(webkitAccessibleHyperlinkGetObject): Ditto.
(webkitAccessibleHyperlinkGetStartIndex): Ditto.
(webkitAccessibleHyperlinkGetEndIndex): Ditto.
(webkitAccessibleHyperlinkIsValid): Ditto.
(webkitAccessibleHyperlinkGetNAnchors): Ditto.
(webkitAccessibleHyperlinkIsSelectedLink): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceAction.cpp:
(webkitAccessibleActionDoAction): Ditto.
(webkitAccessibleActionGetNActions): Ditto.
(webkitAccessibleActionGetDescription): Ditto.
(webkitAccessibleActionGetKeybinding): Ditto.
(webkitAccessibleActionGetName): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceComponent.cpp:
(webkitAccessibleComponentRefAccessibleAtPoint): Ditto.
(webkitAccessibleComponentGetExtents): Ditto.
(webkitAccessibleComponentGrabFocus): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceDocument.cpp:
(webkitAccessibleDocumentGetAttributeValue): Ditto.
(webkitAccessibleDocumentGetAttributes): Ditto.
(webkitAccessibleDocumentGetLocale): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceEditableText.cpp:
(webkitAccessibleEditableTextSetRunAttributes): Ditto.
(webkitAccessibleEditableTextSetTextContents): Ditto.
(webkitAccessibleEditableTextInsertText): Ditto.
(webkitAccessibleEditableTextCopyText): Ditto.
(webkitAccessibleEditableTextCutText): Ditto.
(webkitAccessibleEditableTextDeleteText): Ditto.
(webkitAccessibleEditableTextPasteText): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceHypertext.cpp:
(webkitAccessibleHypertextGetLink): Ditto.
(webkitAccessibleHypertextGetNLinks): Ditto.
(webkitAccessibleHypertextGetLinkIndex): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceImage.cpp:
(webkitAccessibleImageGetImagePosition): Ditto.
(webkitAccessibleImageGetImageDescription): Ditto.
(webkitAccessibleImageGetImageSize): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceSelection.cpp:
(webkitAccessibleSelectionAddSelection): Ditto.
(webkitAccessibleSelectionClearSelection): Ditto.
(webkitAccessibleSelectionRefSelection): Ditto.
(webkitAccessibleSelectionGetSelectionCount): Ditto.
(webkitAccessibleSelectionIsChildSelected): Ditto.
(webkitAccessibleSelectionRemoveSelection): Ditto.
(webkitAccessibleSelectionSelectAllSelection): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
(webkitAccessibleTableRefAt): Ditto.
(webkitAccessibleTableGetIndexAt): Ditto.
(webkitAccessibleTableGetColumnAtIndex): Ditto.
(webkitAccessibleTableGetRowAtIndex): Ditto.
(webkitAccessibleTableGetNColumns): Ditto.
(webkitAccessibleTableGetNRows): Ditto.
(webkitAccessibleTableGetColumnExtentAt): Ditto.
(webkitAccessibleTableGetRowExtentAt): Ditto.
(webkitAccessibleTableGetColumnHeader): Ditto.
(webkitAccessibleTableGetRowHeader): Ditto.
(webkitAccessibleTableGetCaption): Ditto.
(webkitAccessibleTableGetColumnDescription): Ditto.
(webkitAccessibleTableGetRowDescription): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceText.cpp:
(webkitAccessibleTextGetText): Ditto.
(webkitAccessibleTextGetTextAfterOffset): Ditto.
(webkitAccessibleTextGetTextAtOffset): Ditto.
(webkitAccessibleTextGetTextBeforeOffset): Ditto.
(webkitAccessibleTextGetCharacterAtOffset): Ditto.
(webkitAccessibleTextGetCaretOffset): Ditto.
(webkitAccessibleTextGetRunAttributes): Ditto.
(webkitAccessibleTextGetDefaultAttributes): Ditto.
(webkitAccessibleTextGetCharacterExtents): Ditto.
(webkitAccessibleTextGetRangeExtents): Ditto.
(webkitAccessibleTextGetCharacterCount): Ditto.
(webkitAccessibleTextGetOffsetAtPoint): Ditto.
(webkitAccessibleTextGetNSelections): Ditto.
(webkitAccessibleTextGetSelection): Ditto.
(webkitAccessibleTextAddSelection): Ditto.
(webkitAccessibleTextSetSelection): Ditto.
(webkitAccessibleTextRemoveSelection): Ditto.
(webkitAccessibleTextSetCaretOffset): Ditto.
* accessibility/atk/WebKitAccessibleInterfaceValue.cpp:
(webkitAccessibleValueGetCurrentValue): Ditto.
(webkitAccessibleValueGetMaximumValue): Ditto.
(webkitAccessibleValueGetMinimumValue): Ditto.
(webkitAccessibleValueSetCurrentValue): Ditto.
(webkitAccessibleValueGetMinimumIncrement): Ditto.
* accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
(core): Removed, as it's not actually needed.
(webkitAccessibleGetName):  Protect entry point.
(webkitAccessibleGetDescription): Ditto.
(webkitAccessibleGetParent): Ditto.
(webkitAccessibleGetNChildren): Ditto.
(webkitAccessibleRefChild): Ditto.
(webkitAccessibleGetIndexInParent): Ditto.
(webkitAccessibleGetAttributes): Ditto.
(webkitAccessibleGetRole): Ditto.
(webkitAccessibleRefStateSet): Ditto.
(webkitAccessibleRefRelationSet): Ditto.
(webkitAccessibleGetObjectLocale): Ditto.
(webkitAccessibleDetach): Ditto.
(webkitAccessibleIsDetached): New helper function, to be used from
the newly added macros. We need to check whether the wrapper is
detached and not just the wrapper AccessibilityObject since once
the detachment happens we can't trust anything but the AtkObject
from the wrapper (the AccessibilityObject might be invalid).
* accessibility/atk/WebKitAccessibleWrapperAtk.h:

Assert that the render tree is neither being updated nor in need
of being updated before trying to compute the text under a given
element, since that might lead to crashes due to the constructor
of TextIterator calling updateLayoutIgnorePendingStylesheets().

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::textUnderElement): Assert that
the render tree is neither being updated nor needing updating.

LayoutTests:

Added a new test to check that we do not crash in certain
scenarios when hiding objects and retriving accessibility
information about it.

* accessibility/heading-crash-after-hidden-expected.txt: Added.
* accessibility/heading-crash-after-hidden.html: Added.

Rebaselined expectations that were wrong before, since they were
not returning the actual value that they should be returning when
called AccessibilityUIElement::stringValue().

* platform/efl-wk1/accessibility/file-upload-button-stringvalue-expected.txt:
Updated, since the actual text being returned should be the actual
value of the file chooser (e.g. "(None)") and not the text in the
upload botton (e.g. "Choose files").
* platform/efl-wk2/accessibility/file-upload-button-stringvalue-expected.txt: Ditto.
* platform/gtk-wk2/accessibility/file-upload-button-stringvalue-expected.txt: Ditto..
* platform/gtk/accessibility/file-upload-button-stringvalue-expected.txt: Ditto.

* platform/gtk/accessibility/deleting-iframe-destroys-axcache-expected.txt:
Updated, since the iframe should be exposed at all after deleting it.

Removed accesibility test now passing after fixing this issue.

* platform/gtk/TestExpectations: Removed accessibility/aria-used-on-image-maps.html.

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

7 years ago[ATK] Normalize checks in entry points for DRT and WKTR
mario@webkit.org [Fri, 27 Sep 2013 09:07:17 +0000 (09:07 +0000)]
[ATK] Normalize checks in entry points for DRT and WKTR
https://bugs.webkit.org/show_bug.cgi?id=121959

Reviewed by Chris Fleizach.

Always check if we have a proper instance of AtkObject,
implementing the interfaces that we might need for each case, at
the entry point of every method of AccessibilityUIElement for ATK,
and do those checks in an uniform way across DRT and WKTR, to
avoid confusion and issues when modifying these files in the future.

* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(AccessibilityUIElement::getChildren): Use normalized checks.
(AccessibilityUIElement::getChildrenWithRange): Ditto.
(AccessibilityUIElement::rowCount): Ditto.
(AccessibilityUIElement::columnCount): Ditto.
(AccessibilityUIElement::childrenCount): Ditto.
(AccessibilityUIElement::elementAtPoint): Ditto.
(AccessibilityUIElement::getChildAtIndex): Ditto.
(AccessibilityUIElement::allAttributes): Ditto.
(AccessibilityUIElement::titleUIElement): Ditto.
(AccessibilityUIElement::parentElement): Ditto.
(AccessibilityUIElement::attributesOfChildren): Ditto.
(AccessibilityUIElement::role): Ditto.
(AccessibilityUIElement::title): Ditto.
(AccessibilityUIElement::description): Ditto.
(AccessibilityUIElement::stringValue): Ditto.
(AccessibilityUIElement::language): Ditto.
(AccessibilityUIElement::x): Ditto.
(AccessibilityUIElement::y): Ditto.
(AccessibilityUIElement::width): Ditto.
(AccessibilityUIElement::height): Ditto.
(AccessibilityUIElement::orientation): Ditto.
(AccessibilityUIElement::intValue): Ditto.
(AccessibilityUIElement::minValue): Ditto.
(AccessibilityUIElement::maxValue): Ditto.
(indexRangeInTable): Ditto.
(AccessibilityUIElement::cellForColumnAndRow): Ditto.
(AccessibilityUIElement::stringAttributeValue): Ditto.
(alterCurrentValue): Ditto.
(AccessibilityUIElement::press): Ditto.
(AccessibilityUIElement::documentEncoding): Ditto.
(AccessibilityUIElement::documentURI): Ditto.
(AccessibilityUIElement::hasPopup): Ditto.

* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::indexRangeInTable): Use normalized checks.
(WTR::alterCurrentValue): Ditto.
(WTR::AccessibilityUIElement::getChildren): Ditto.
(WTR::AccessibilityUIElement::getChildrenWithRange): Ditto.
(WTR::AccessibilityUIElement::childrenCount): Ditto.
(WTR::AccessibilityUIElement::elementAtPoint): Ditto.
(WTR::AccessibilityUIElement::indexOfChild): Ditto.
(WTR::AccessibilityUIElement::childAtIndex): Ditto.
(WTR::AccessibilityUIElement::titleUIElement): Ditto.
(WTR::AccessibilityUIElement::parentElement): Ditto.
(WTR::AccessibilityUIElement::attributesOfChildren): Ditto.
(WTR::AccessibilityUIElement::allAttributes): Ditto.
(WTR::AccessibilityUIElement::stringAttributeValue): Ditto.
(WTR::AccessibilityUIElement::role): Ditto.
(WTR::AccessibilityUIElement::title): Ditto.
(WTR::AccessibilityUIElement::description): Ditto.
(WTR::AccessibilityUIElement::orientation): Ditto.
(WTR::AccessibilityUIElement::stringValue): Ditto.
(WTR::AccessibilityUIElement::language): Ditto.
(WTR::AccessibilityUIElement::x): Ditto.
(WTR::AccessibilityUIElement::y): Ditto.
(WTR::AccessibilityUIElement::width): Ditto.
(WTR::AccessibilityUIElement::height): Ditto.
(WTR::AccessibilityUIElement::intValue): Ditto.
(WTR::AccessibilityUIElement::minValue): Ditto.
(WTR::AccessibilityUIElement::maxValue): Ditto.
(WTR::AccessibilityUIElement::rowCount): Ditto.
(WTR::AccessibilityUIElement::columnCount): Ditto.
(WTR::AccessibilityUIElement::cellForColumnAndRow): Ditto.
(WTR::AccessibilityUIElement::press): Ditto.
(WTR::AccessibilityUIElement::documentEncoding): Ditto.
(WTR::AccessibilityUIElement::documentURI): Ditto.
(WTR::AccessibilityUIElement::hasPopup): Ditto.

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

7 years ago[ATK] accessibility/aria-sort.html is failing after r156409
mario@webkit.org [Fri, 27 Sep 2013 08:58:08 +0000 (08:58 +0000)]
[ATK] accessibility/aria-sort.html is failing after r156409
https://bugs.webkit.org/show_bug.cgi?id=121947

Reviewed by Chris Fleizach.

Source/WebCore:

The WAI-ARIA spec says to translate the value as is from the
attribute, so do just that instead of mapping values from the
AccessibilitySortDirection enumeration into strings.
http://www.w3.org/TR/wai-aria-implementation/#mapping_state-property

* accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
(webkitAccessibleGetAttributes): Do the right mapping for aria-sort.

Tools:

Implement AccessibilityUIElement::isSupported for the ATK
platforms, just by checking whether we have an associated object
attribute exposed for the wrapper object matching the required
attribute in the layout test (e.g "AXSortDirection" -> "sort").

* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(AccessibilityUIElement::isAttributeSupported): Implemented.
* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::AccessibilityUIElement::isAttributeSupported): Implemented.

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

7 years ago[GCC] Fix build with gcc < 4.8.1, which does not have is_trivially_destructible
ryuan.choi@samsung.com [Fri, 27 Sep 2013 07:48:50 +0000 (07:48 +0000)]
[GCC] Fix build with gcc < 4.8.1, which does not have is_trivially_destructible
https://bugs.webkit.org/show_bug.cgi?id=121999

Patch by Gustavo Noronha Silva <gns@gnome.org> on 2013-09-27
Reviewed by Benjamin Poulain.

* wtf/StdLibExtras.h:

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

7 years agoSync toWebKitCSSShaderValue() behavior with other toCSSFooValue()
gyuyoung.kim@samsung.com [Fri, 27 Sep 2013 03:26:53 +0000 (03:26 +0000)]
Sync toWebKitCSSShaderValue() behavior with other toCSSFooValue()
https://bugs.webkit.org/show_bug.cgi?id=121886

Reviewed by Darin Adler.

toWebKitCSSShaderValue() behavior is different from other to CSSFooValue().
It shouldn't return null. The type checking should be done before doing type cast.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
* css/WebKitCSSShaderValue.h:
(WebCore::toWebKitCSSShaderValue):

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

7 years agoMove m_style to RenderElement
antti@apple.com [Fri, 27 Sep 2013 02:02:27 +0000 (02:02 +0000)]
Move m_style to RenderElement
https://bugs.webkit.org/show_bug.cgi?id=121936

Source/WebCore:

Reviewed by Andreas Kling.

Text renderers always have the same style as their parent. They can get their style via the parent pointer
rather than having a member of their own.

This shrinks RenderText by a pointer.

* dom/PseudoElement.cpp:
(WebCore::PseudoElement::didRecalcStyle):

    Text renderers have no independent style. No need to set it.

* editing/ApplyBlockElementCommand.cpp:
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::addChildToAnonymousColumnBlocks):

    Avoid getting style from text child before it is added to tree.

(WebCore::RenderBlock::updateFirstLetterStyle):
(WebCore::RenderBlock::createFirstLetterRenderer):
* rendering/RenderButton.cpp:
(WebCore::RenderButton::styleDidChange):
(WebCore::RenderButton::setText):
* rendering/RenderCombineText.cpp:
(WebCore::RenderCombineText::styleDidChange):

    Don't set text style anymore.

* rendering/RenderElement.cpp:
(WebCore::RenderElement::RenderElement):
(WebCore::RenderElement::setStyle):

    Notify child text renderers of style change.

(WebCore::RenderElement::setAnimatableStyle):
(WebCore::RenderElement::setPseudoStyle):

    Push down to RenderElement, remove text branches.

(WebCore::RenderElement::addChild):

    Notify text renderers of style change when added to tree.

(WebCore::RenderElement::propagateStyleToAnonymousChildren):
* rendering/RenderElement.h:
(WebCore::RenderElement::style):
(WebCore::RenderElement::setStyleInternal):

    Move m_style from RenderObject.

(WebCore::RenderObject::style):

    Inline this in RenderElement.h instead of making it virtual.

* rendering/RenderInline.cpp:
(WebCore::updateStyleOfAnonymousBlockContinuations):
(WebCore::RenderInline::styleDidChange):

    Tighten typing to call RenderElement::setStyle.

(WebCore::RenderInline::clippedOverflowRectForRepaint):

    Change assert. This can get legitimately called during layout for the first letter renderers.
    This was previously avoided by luck.

* rendering/RenderMenuList.cpp:
(WebCore::RenderMenuList::styleDidChange):
(WebCore::RenderMenuList::setText):

    Don't set text style anymore.

* rendering/RenderObject.cpp:
(WebCore::RenderObject::RenderObject):
(WebCore::RenderObject::containingBlock):
(WebCore::RenderObject::drawLineForBoxSide):
(WebCore::RenderObject::hasEntirelyFixedBackground):
(WebCore::RenderObject::container):
(WebCore::RenderObject::cachedFirstLineStyle):

    Switch to style(), avoid unnecessary repetition.
    Move code out.

* rendering/RenderObject.h:

    Move functions to RenderElement.

(WebCore::RenderObject::isBeforeContent):
(WebCore::RenderObject::isAfterContent):

    Avoid accessing style for text renderers as these are called before the renderer
    is added to tree.

(WebCore::RenderObject::setNeedsPositionedMovementLayout):
* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
(WebCore::RenderRegion::setObjectStyleInRegion):
* rendering/RenderSearchField.cpp:
(WebCore::RenderSearchField::updateCancelButtonVisibility):
* rendering/RenderText.cpp:
* rendering/RenderText.h:

    Remove setStyle.

(WebCore::RenderText::style):

    Get style from parent.

* rendering/mathml/RenderMathMLOperator.cpp:
(WebCore::RenderMathMLOperator::updateFromElement):
(WebCore::RenderMathMLOperator::createGlyph):
* rendering/style/ContentData.cpp:
(WebCore::TextContentData::createRenderer):
(WebCore::CounterContentData::createRenderer):
(WebCore::QuoteContentData::createRenderer):

    Pseudo style for RenderText subclasses comes from parent without any explicit setting.

* style/StyleResolveTree.cpp:
(WebCore::Style::createTextRendererIfNeeded):
(WebCore::Style::resolveLocal):
(WebCore::Style::updateTextStyle):
(WebCore::Style::resolveShadowTree):
(WebCore::Style::resolveTree):

    No need to set or update text renderer style separately.

LayoutTests:

Reviewed by Andreas Kling.

Progressions from text style updating correctly in all cases.

* compositing/contents-opaque/hidden-with-visible-text-expected.txt:
* compositing/contents-opaque/visibility-hidden-expected.txt:

    Can't figure out why these progress but they do. The new rendering (showing nothing)
    is correct and matches Firefox.

* platform/mac/svg/custom/SVGPoint-matrixTransform-expected.txt:
* platform/mac/svg/custom/getTransformToElement-expected.txt:
* platform/mac/svg/custom/text-ctm-expected.txt:
* platform/mac/svg/custom/text-hit-test-expected.txt:
* platform/mac/svg/text/append-text-node-to-tspan-expected.txt:

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

7 years ago"Build fix".
andersca@apple.com [Fri, 27 Sep 2013 01:58:52 +0000 (01:58 +0000)]
"Build fix".

We can't use std::move. Explicitly destroy the old value and then construct the new in place.

* wtf/HashTable.h:

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

7 years agoFixed a version number string in SunSpider 1.0.2
ggaren@apple.com [Fri, 27 Sep 2013 01:56:03 +0000 (01:56 +0000)]
Fixed a version number string in SunSpider 1.0.2
https://bugs.webkit.org/show_bug.cgi?id=122004

Reviewed by Gavin Barraclough.

PerformanceTests/SunSpider:

* resources/driver-TEMPLATE.html:
* resources/results-TEMPLATE.html: 1.0.2!

Websites/webkit.org:

* perf/sunspider-1.0.2/sunspider-1.0.2/results.html: 1.0.2!

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

7 years agoUse the move assignment operator when reinserting values in the hash map
andersca@apple.com [Fri, 27 Sep 2013 01:51:32 +0000 (01:51 +0000)]
Use the move assignment operator when reinserting values in the hash map
https://bugs.webkit.org/show_bug.cgi?id=122003

Reviewed by Alexey Proskuryakov.

Using the move assignment operator ensures that the existing values will be destroyed correctly.

* wtf/HashTable.h:

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

7 years agoTentative SunSpider 1.0.2
ggaren@apple.com [Fri, 27 Sep 2013 01:46:25 +0000 (01:46 +0000)]
Tentative SunSpider 1.0.2
https://bugs.webkit.org/show_bug.cgi?id=122002

Reviewed by Gavin Barraclough.

PerformanceTests/SunSpider:

Be even more aggressive about asking for zero delay between tests by
setting a timeout at the beginning of a test instead of the end. This is
another step toward reducing noise -- particularly noise caused by
power management -- just like the step down from 10ms to 0ms.

Browsers typically put a 4ms floor on timers. The sooner we set
our timer, the sooner it will fire.

* make-hosted:
* resources/driver-TEMPLATE.html: Changed the driver to set the timeout
earlier.
* tests/sunspider-1.0.2: Added. These tests are unchanged from 1.0.1.

Websites/webkit.org:

See comments in PerformanceTests/SunSpider.

* perf/sunspider-1.0.2: Added.

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

7 years ago[MediaStream] make MediaStream testable
eric.carlson@apple.com [Fri, 27 Sep 2013 01:08:17 +0000 (01:08 +0000)]
[MediaStream] make MediaStream testable
https://bugs.webkit.org/show_bug.cgi?id=121967

Reviewed by Dean Jackson.

Source/WebCore:

No new tests, existing tests updated.

* CMakeLists.txt: Add MockMediaStreamCenter.
* GNUmakefile.list.am: Ditto.

* Modules/mediastream/MediaStreamTrack.idl: Add SkipVTableValidation.
* Modules/mediastream/NavigatorUserMediaError.idl: Add JSGenerateToJSObject.
* WebCore.exp.in: Export MockMediaStreamCenter::registerMockMediaStreamCenter.

* WebCore.xcodeproj/project.pbxproj: Add MockMediaStreamCenter.
* dom/DOMError.h: Make the destructor virtual because it has a derived class.
* dom/DOMError.idl:

* platform/mock/MockMediaStreamCenter.cpp: Added.
* platform/mock/MockMediaStreamCenter.h: Added.

* testing/Internals.cpp: Register the mock stream center.

Source/WebKit:

* WebKit.xcodeproj/project.pbxproj: Add WebUserMediaClient.

Source/WebKit/mac:

* WebCoreSupport/WebUserMediaClient.h: Added.
* WebCoreSupport/WebUserMediaClient.mm: Added.

* WebView/WebUIDelegatePrivate.h: Declare decidePolicyForUserMediaRequestFromOrigin:listener:

* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]): Register WebUserMediaClient.
(-[WebView _setUserMediaClient:]): New.
(-[WebView _userMediaClient]): New.
* WebView/WebViewData.h:
* WebView/WebViewPrivate.h:

Tools:

* DumpRenderTree/mac/UIDelegate.mm:
(-[UIDelegate webView:decidePolicyForUserMediaRequestFromOrigin:listener:]): Add a very permissive
    user media request policy delegate.

LayoutTests:

* fast/mediastream/MediaStream-add-remove-tracks-expected.txt:
* fast/mediastream/MediaStream-add-remove-tracks.html: Make the test results more understandable
    to simplify debugging failures.
* fast/mediastream/MediaStream-onended-expected.txt:
* fast/mediastream/MediaStream-onended.html: Ditto. Fix a test error: stopping stream A should
    not stop stream B even when it was created from stream A.
* fast/mediastream/MediaStreamConstructor-expected.txt:
* fast/mediastream/MediaStreamConstructor.html: Make the test results more understandable. Fix a
    logic errors: webkitMediaStream is an object, not a function. JSC does not support
    object.constructor.name, use object.constructor.toString() instead.
* fast/mediastream/MediaStreamTrackEvent-constructor-expected.txt:
* fast/mediastream/MediaStreamTrackEvent-constructor.html: Update now that getUserMedia() works.
* fast/mediastream/argument-types-expected.txt: Updated with "Failing" results because the correct
    behavior is unknown. The spec says "the syntax for getUserMedia() is still under discussion".

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

7 years agoGetterSetter construction should take a VM instead of ExecState.
akling@apple.com [Fri, 27 Sep 2013 00:39:00 +0000 (00:39 +0000)]
GetterSetter construction should take a VM instead of ExecState.
<https://webkit.org/b/121993>

Reviewed by Sam Weinig.

Pass VM& instead of ExecState* to GetterSetter. Updated surrounding
code at touched sites to cache VM in a local for fewer loads.

JSC release binary size -= 4120 bytes.

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

7 years agoWeb Inspector: dissociate old content views that are spliced from back/forward list
commit-queue@webkit.org [Fri, 27 Sep 2013 00:27:50 +0000 (00:27 +0000)]
Web Inspector: dissociate old content views that are spliced from back/forward list
https://bugs.webkit.org/show_bug.cgi?id=121987

Patch by Brian J. Burg <burg@cs.washington.edu> on 2013-09-26
Reviewed by Timothy Hatcher.

There was a bug where old back/forward list entries were not being dissociated when
the newly-shown content view was already in the list. Instead, dissociation should be
skipped if the old list entry is not already in the list.

* UserInterface/ContentViewContainer.js:
(WebInspector.ContentViewContainer.prototype.showContentView):

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

7 years agoLayout Test http/tests/inspector/network/network-iframe-load-and-delete.html is flaky
ap@apple.com [Fri, 27 Sep 2013 00:27:47 +0000 (00:27 +0000)]
Layout Test http/tests/inspector/network/network-iframe-load-and-delete.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=121998

* platform/mac/TestExpectations: Marking as such.

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

7 years agoMake GCC happy
oliver@apple.com [Fri, 27 Sep 2013 00:23:30 +0000 (00:23 +0000)]
Make GCC happy

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

7 years ago[Windows] Unreviewed Build fix.
bfulgham@apple.com [Thu, 26 Sep 2013 23:51:18 +0000 (23:51 +0000)]
[Windows] Unreviewed Build fix.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Add missing
symbol export to support tests.

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

7 years ago[Windows] Work around missing C++11 features of MSVC by providing an implementation for
bfulgham@apple.com [Thu, 26 Sep 2013 23:37:39 +0000 (23:37 +0000)]
[Windows] Work around missing C++11 features of MSVC by providing an implementation for
std::is_trivially_destructible based on the existing std::has_trivial_destructor.

Rubber-stamped by Anders Carlsson.

* wtf/StdLibExtras.h: Add implementation for is_trivially_destructable for MSVC 2010 and prior.

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

7 years agoMove CSS MatchRequest from StyleResolver to a private definition in ElementRuleCollector
benjamin@webkit.org [Thu, 26 Sep 2013 23:36:09 +0000 (23:36 +0000)]
Move CSS MatchRequest from StyleResolver to a private definition in ElementRuleCollector
https://bugs.webkit.org/show_bug.cgi?id=121986

Reviewed by Andreas Kling.

MatchRequest is an internal type of ElementRuleCollector now, move the definition
to ElementRuleCollector.

* css/DocumentRuleSets.h:
* css/ElementRuleCollector.h:
(WebCore::ElementRuleCollector::MatchRequest::MatchRequest):
* css/StyleResolver.h:

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

7 years ago2013-09-25 Oliver Hunt <oliver@apple.com>
oliver@apple.com [Thu, 26 Sep 2013 23:32:16 +0000 (23:32 +0000)]
2013-09-25  Oliver Hunt  <oliver@apple.com>

        Implement prefixed-destructuring assignment
        https://bugs.webkit.org/show_bug.cgi?id=121930

        Reviewed by Mark Hahnenberg.

        Relanding with fix after rollout

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

7 years ago[Windows] Unreviewed build fix after r156487.
bfulgham@apple.com [Thu, 26 Sep 2013 23:16:07 +0000 (23:16 +0000)]
[Windows] Unreviewed build fix after r156487.

Add explicit casting needed by MSVC to compile this code. Much
of this could probably be removed when we move to VS2012 or newer.

* bindings/js/JSEventListener.cpp:
(WebCore::JSEventListener::JSEventListener):
* bindings/js/JSEventListener.h:
(WebCore::JSEventListener::jsFunction):
* bridge/jsc/BridgeJSC.cpp:
(JSC::Bindings::Instance::createRuntimeObject):

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

7 years agoUnreviewed, rolling out r156510.
commit-queue@webkit.org [Thu, 26 Sep 2013 23:00:26 +0000 (23:00 +0000)]
Unreviewed, rolling out r156510.
http://trac.webkit.org/changeset/156510
https://bugs.webkit.org/show_bug.cgi?id=121989

Landed in-progress code along with build fix. (Requested by
bfulgham on #webkit).

* bindings/js/JSEventListener.cpp:
(WebCore::JSEventListener::JSEventListener):
* bindings/js/JSEventListener.h:
(WebCore::JSEventListener::jsFunction):
* bridge/jsc/BridgeJSC.cpp:
(JSC::Bindings::Instance::createRuntimeObject):
* platform/graphics/filters/FEGaussianBlur.cpp:
(WebCore::FEGaussianBlur::platformApplyGeneric):
(WebCore::FEGaussianBlur::platformApply):
* platform/graphics/win/DIBPixelData.cpp:
(WebCore::DIBPixelData::writeToFile):
* platform/graphics/win/DIBPixelData.h:

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

7 years agoVirtualRegister should be a class
msaboff@apple.com [Thu, 26 Sep 2013 22:53:54 +0000 (22:53 +0000)]
VirtualRegister should be a class
https://bugs.webkit.org/show_bug.cgi?id=121732

Reviewed by Geoffrey Garen.

This is a refactoring change.  Changed VirtualRegister from an enum to a class.
Moved Operands::operandIsArgument(), operandToArgument(), argumentToOperand()
and the similar functions for locals to VirtualRegister class.

This is in preparation for changing the offset for the first local register from
0 to -1.  This is needed since most native calling conventions have the architected
frame pointer (e.g. %rbp for X86) point at the slot that stores the previous frame
pointer.  Local values start below that address.

* bytecode/CodeBlock.cpp:
* bytecode/CodeBlock.h:
* bytecode/Instruction.h:
* bytecode/LazyOperandValueProfile.h:
* bytecode/MethodOfGettingAValueProfile.cpp:
* bytecode/Operands.h:
* bytecode/UnlinkedCodeBlock.cpp:
* bytecode/UnlinkedCodeBlock.h:
* bytecode/ValueRecovery.h:
* bytecode/VirtualRegister.h:
* bytecompiler/BytecodeGenerator.cpp:
* bytecompiler/BytecodeGenerator.h:
* bytecompiler/RegisterID.h:
* debugger/DebuggerCallFrame.cpp:
* dfg/DFGAbstractHeap.h:
* dfg/DFGAbstractInterpreterInlines.h:
* dfg/DFGArgumentPosition.h:
* dfg/DFGArgumentsSimplificationPhase.cpp:
* dfg/DFGByteCodeParser.cpp:
* dfg/DFGCFGSimplificationPhase.cpp:
* dfg/DFGCPSRethreadingPhase.cpp:
* dfg/DFGCapabilities.cpp:
* dfg/DFGConstantFoldingPhase.cpp:
* dfg/DFGFlushLivenessAnalysisPhase.cpp:
* dfg/DFGGraph.cpp:
* dfg/DFGGraph.h:
* dfg/DFGJITCode.cpp:
* dfg/DFGNode.h:
* dfg/DFGOSREntry.cpp:
* dfg/DFGOSREntrypointCreationPhase.cpp:
* dfg/DFGOSRExit.h:
* dfg/DFGOSRExitCompiler32_64.cpp:
* dfg/DFGOSRExitCompiler64.cpp:
* dfg/DFGRegisterBank.h:
* dfg/DFGScoreBoard.h:
* dfg/DFGSpeculativeJIT.cpp:
* dfg/DFGSpeculativeJIT.h:
* dfg/DFGSpeculativeJIT32_64.cpp:
* dfg/DFGSpeculativeJIT64.cpp:
* dfg/DFGValidate.cpp:
* dfg/DFGValueRecoveryOverride.h:
* dfg/DFGVariableAccessData.h:
* dfg/DFGVariableEvent.h:
* dfg/DFGVariableEventStream.cpp:
* dfg/DFGVirtualRegisterAllocationPhase.cpp:
* ftl/FTLExitArgumentForOperand.h:
* ftl/FTLLink.cpp:
* ftl/FTLLowerDFGToLLVM.cpp:
* ftl/FTLOSREntry.cpp:
* ftl/FTLOSRExit.cpp:
* ftl/FTLOSRExit.h:
* ftl/FTLOSRExitCompiler.cpp:
* interpreter/CallFrame.h:
* interpreter/Interpreter.cpp:
* jit/AssemblyHelpers.h:
* jit/JIT.h:
* jit/JITCall.cpp:
* jit/JITCall32_64.cpp:
* jit/JITInlines.h:
* jit/JITOpcodes.cpp:
* jit/JITOpcodes32_64.cpp:
* jit/JITPropertyAccess32_64.cpp:
* jit/JITStubs.cpp:
* llint/LLIntSlowPaths.cpp:
* profiler/ProfilerBytecodeSequence.cpp:
* runtime/CommonSlowPaths.cpp:
* runtime/JSActivation.cpp:

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

7 years ago[Windows] Unreviewed build fix after r156487.
bfulgham@apple.com [Thu, 26 Sep 2013 22:49:33 +0000 (22:49 +0000)]
[Windows] Unreviewed build fix after r156487.

Add explicit casting needed by MSVC to compile this code. Much
of this could probably be removed when we move to VS2012 or newer.

* bindings/js/JSEventListener.cpp:
(WebCore::JSEventListener::JSEventListener):
* bindings/js/JSEventListener.h:
(WebCore::JSEventListener::jsFunction):
* bridge/jsc/BridgeJSC.cpp:
(JSC::Bindings::Instance::createRuntimeObject):
* platform/graphics/filters/FEGaussianBlur.cpp:
(WebCore::FEGaussianBlur::platformApplyGeneric):
(WebCore::FEGaussianBlur::platformApply):
* platform/graphics/win/DIBPixelData.cpp:
(WebCore::DIBPixelData::DIBPixelData):
(WebCore::DIBPixelData::writeToFile):
* platform/graphics/win/DIBPixelData.h:

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

7 years agoFlaky Test: transitions/cancel-transition.html
ap@apple.com [Thu, 26 Sep 2013 22:47:16 +0000 (22:47 +0000)]
Flaky Test: transitions/cancel-transition.html
https://bugs.webkit.org/show_bug.cgi?id=114193

* platform/mac/TestExpectations: Marking as flaky. Dean says that such tests are
currently broken by design.

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

7 years agoRemove Windows code
andersca@apple.com [Thu, 26 Sep 2013 22:45:46 +0000 (22:45 +0000)]
Remove Windows code
https://bugs.webkit.org/show_bug.cgi?id=121988

Reviewed by Antti Koivisto.

* Platform/CoreIPC/Connection.h:
* Platform/CoreIPC/win/ConnectionWin.cpp: Removed.
* Platform/SharedMemory.h:
* Platform/WorkQueue.h:
* Platform/win/SharedMemoryWin.cpp: Removed.
* Platform/win/WorkQueueWin.cpp: Removed.
* Shared/ChildProcess.cpp:
* Shared/ChildProcessProxy.cpp:
(WebKit::ChildProcessProxy::didFinishLaunching):
* UIProcess/Plugins/PluginInfoStore.cpp:
(WebKit::PluginInfoStore::loadPluginsIfNecessary):
* WebProcess/WebProcess.cpp:

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

7 years agoRemove needsDestruction from vector and hash traits
andersca@apple.com [Thu, 26 Sep 2013 22:37:20 +0000 (22:37 +0000)]
Remove needsDestruction from vector and hash traits
https://bugs.webkit.org/show_bug.cgi?id=121983

Reviewed by Sam Weinig.

For Vector, use std::is_trivially_destructible to determine whether to call the destructor.
For HashTable, always call the destructor; if it is trivial then no code will be generated for it and the loops will be folded away.

Removing this does break the ability to store objects with non-trivial destructors in vectors and hash maps
and have their destructors not be called when removed, but we've never used this feature in WebKit so the extra
code complexity is not worth it.

* wtf/HashTable.h:
(WTF::::deallocateTable):
* wtf/HashTraits.h:
* wtf/Vector.h:
(WTF::VectorTypeOperations::destruct):
* wtf/VectorTraits.h:

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

7 years agoExpose a setting to disable hardware accelerated animations
dino@apple.com [Thu, 26 Sep 2013 22:29:07 +0000 (22:29 +0000)]
Expose a setting to disable hardware accelerated animations
https://bugs.webkit.org/show_bug.cgi?id=121978
<rdar://problem/15091284>

Reviewed by Eric Carlson.

Source/WebCore:

Expose acceleratedCompositedAnimationsEnabled
to disable CoreAnimation animations.

Test: LayoutTests/animations/transform-non-accelerated.html

* WebCore.exp.in: Export new method.
* page/Settings.in: Add new setting.
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::startAnimation): Don't go
to GraphicsLayer if the setting is false.

LayoutTests:

* animations/resources/animation-test-helpers.js: Add a callback
for when the tests finish. Minor cleanup.
(endTest):
(.else):
(runAnimationTest):
* animations/transform-non-accelerated.html: New test.
* animations/transform-non-accelerated-expected.txt: Result.

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

7 years agoSource/JavaScriptCore: Work around another MSVC bug.
andersca@apple.com [Thu, 26 Sep 2013 22:25:40 +0000 (22:25 +0000)]
Source/JavaScriptCore: Work around another MSVC bug.

* runtime/PrototypeMap.cpp:
(JSC::PrototypeMap::emptyObjectStructureForPrototype):

Source/WTF: Build fixes.

Fix a paste-o.

* wtf/StdLibExtras.h:
(std::make_unique):

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

7 years agoAttempt to fix the FTL build.
andersca@apple.com [Thu, 26 Sep 2013 22:20:46 +0000 (22:20 +0000)]
Attempt to fix the FTL build.

* ftl/FTLAbstractHeap.cpp:
(JSC::FTL::IndexedAbstractHeap::atSlow):

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

7 years ago[Qt] Fix build after r156487.
commit-queue@webkit.org [Thu, 26 Sep 2013 22:19:07 +0000 (22:19 +0000)]
[Qt] Fix build after r156487.
https://bugs.webkit.org/show_bug.cgi?id=121984

Patch by Julien Brianceau <jbriance@cisco.com> on 2013-09-26
Reviewed by Anders Carlsson.

* bridge/qt/qt_runtime.cpp:
(JSC::Bindings::QtRuntimeMethod::jsObjectRef):

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

7 years agoDon't mutate style in RenderCombineText
antti@apple.com [Thu, 26 Sep 2013 22:01:38 +0000 (22:01 +0000)]
Don't mutate style in RenderCombineText
https://bugs.webkit.org/show_bug.cgi?id=121979

Reviewed by Andreas Kling.

Text renderers should always have the same style as the parent.

* rendering/InlineTextBox.cpp:
(WebCore::fontToUse):
(WebCore::InlineTextBox::localSelectionRect):
(WebCore::InlineTextBox::paint):
(WebCore::InlineTextBox::offsetForPosition):
(WebCore::InlineTextBox::positionForOffset):

    Select the modified font for text-combine.

* rendering/RenderCombineText.cpp:
(WebCore::RenderCombineText::styleDidChange):
(WebCore::RenderCombineText::combineText):
* rendering/RenderCombineText.h:

    Move the text-combine specific font style to a member of its own.

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

7 years agoUpdate expected binding test results after r156498.
timothy@apple.com [Thu, 26 Sep 2013 21:45:22 +0000 (21:45 +0000)]
Update expected binding test results after r156498.

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

7 years agoPass VM instead of ExecState to many finishCreation() functions.
akling@apple.com [Thu, 26 Sep 2013 21:43:49 +0000 (21:43 +0000)]
Pass VM instead of ExecState to many finishCreation() functions.
<https://webkit.org/b/121975>

Reviewed by Sam Weinig.

Reduce unnecessary loads by passing the VM to object creation
functions that don't need the ExecState.

There are tons of opportunities in this area, I'm just scratching
the surface.

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

7 years agoUnreviewed, rolling out r156464 and r156480.
commit-queue@webkit.org [Thu, 26 Sep 2013 21:27:00 +0000 (21:27 +0000)]
Unreviewed, rolling out r156464 and r156480.
http://trac.webkit.org/changeset/156464
http://trac.webkit.org/changeset/156480
https://bugs.webkit.org/show_bug.cgi?id=121981

Leaking too much and killi
ng buildbot. (Requested by xenon on
#webkit).

Source/JavaScriptCore:

* bytecode/UnlinkedCodeBlock.cpp:
(JSC::UnlinkedFunctionExecutable::paramString):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::emitExpressionInfo):
* bytecompiler/NodesCodegen.cpp:
(JSC::ForInNode::emitBytecode):
(JSC::FuncExprNode::emitBytecode):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::createFormalParameterList):
(JSC::ASTBuilder::createForInLoop):
(JSC::ASTBuilder::addVar):
* parser/NodeConstructors.h:
(JSC::CommaNode::CommaNode):
(JSC::ParameterNode::ParameterNode):
(JSC::ForInNode::ForInNode):
* parser/Nodes.cpp:
(JSC::FunctionParameters::create):
(JSC::FunctionParameters::FunctionParameters):
(JSC::FunctionParameters::~FunctionParameters):
* parser/Nodes.h:
(JSC::CommaNode::append):
(JSC::ParameterNode::ident):
(JSC::FunctionParameters::at):
(JSC::FunctionParameters::identifiers):
* parser/Parser.cpp:
(JSC::::Parser):
(JSC::::parseVarDeclaration):
(JSC::::parseVarDeclarationList):
(JSC::::parseForStatement):
(JSC::::parseFormalParameters):
(JSC::::parseAssignmentExpression):
* parser/Parser.h:
(JSC::Scope::declareParameter):
* parser/SyntaxChecker.h:
(JSC::SyntaxChecker::createFormalParameterList):
(JSC::SyntaxChecker::createForInLoop):
(JSC::SyntaxChecker::operatorStackPop):
* runtime/JSONObject.cpp:
* runtime/JSONObject.h:

LayoutTests:

* js/destructuring-assignment-expected.txt: Removed.
* js/destructuring-assignment.html: Removed.
* js/mozilla/strict/13.1-expected.txt:
* js/mozilla/strict/regress-532254-expected.txt:
* js/mozilla/strict/script-tests/13.1.js:
* js/regress/destructuring-arguments-expected.txt: Removed.
* js/regress/destructuring-arguments-length-expected.txt: Removed.
* js/regress/destructuring-arguments-length.html: Removed.
* js/regress/destructuring-arguments.html: Removed.
* js/regress/destructuring-swap-expected.txt: Removed.
* js/regress/destructuring-swap.html: Removed.
* js/regress/script-tests/destructuring-arguments-length.js: Removed.
* js/regress/script-tests/destructuring-arguments.js: Removed.
* js/regress/script-tests/destructuring-swap.js: Removed.
* js/script-tests/destructuring-assignment.js: Removed.
* sputnik/Conformance/13_Function_Definition/S13_A5.html:

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

7 years agoRemove the hash table mover
andersca@apple.com [Thu, 26 Sep 2013 21:25:29 +0000 (21:25 +0000)]
Remove the hash table mover
https://bugs.webkit.org/show_bug.cgi?id=121980

Reviewed by Andreas Kling.

Use std::move instead.

* wtf/HashTable.h:

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

7 years agoLayout Test plugins/access-after-page-destroyed.html is flaky
ap@apple.com [Thu, 26 Sep 2013 21:07:27 +0000 (21:07 +0000)]
Layout Test plugins/access-after-page-destroyed.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=121976

Reviewed by Anders Carlsson.

Clean up the test.

* plugins/access-after-page-destroyed-2-expected.txt: Added.
* plugins/access-after-page-destroyed-2.html: Copied from LayoutTests/plugins/access-after-page-destroyed.html.
This was testing two distinct issues, the second one unfittingly piled onto the first.
Split the test in two.

* plugins/access-after-page-destroyed-expected.txt:
* plugins/access-after-page-destroyed.html:
Modernized the test with js-test scripts, added a gc() call for predictability,
changed the test to fail quickly in the flaky case.

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

7 years agoTry to fix the Windows build.
andersca@apple.com [Thu, 26 Sep 2013 20:59:51 +0000 (20:59 +0000)]
Try to fix the Windows build.

* jit/JITThunks.cpp:
(JSC::JITThunks::hostFunctionStub):
* jit/JITThunks.h:

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

7 years agobuild-webkit --inspector-frontend should copy WebInspectorUI files
commit-queue@webkit.org [Thu, 26 Sep 2013 20:54:06 +0000 (20:54 +0000)]
build-webkit --inspector-frontend should copy WebInspectorUI files
https://bugs.webkit.org/show_bug.cgi?id=117851

Patch by Brian J. Burg <burg@cs.washington.edu> on 2013-09-26
Reviewed by Joseph Pecoraro.

Change the --inspector-frontend build option to additionally build/copy
WebInspectorUI by setting it as the only project that needs to be built.

* Scripts/build-webkit:

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

7 years agoChange a couple of HashMap value types from OwnPtr to std::unique_ptr
andersca@apple.com [Thu, 26 Sep 2013 20:44:02 +0000 (20:44 +0000)]
Change a couple of HashMap value types from OwnPtr to std::unique_ptr
https://bugs.webkit.org/show_bug.cgi?id=121973

Reviewed by Andreas Kling.

Source/JavaScriptCore:

* API/JSClassRef.cpp:
(OpaqueJSClassContextData::OpaqueJSClassContextData):
(OpaqueJSClass::contextData):
* API/JSClassRef.h:
* bytecode/SamplingTool.h:
* ftl/FTLAbstractHeap.h:
* parser/Parser.cpp:
(JSC::::parseFunctionInfo):
* parser/SourceProviderCache.cpp:
(JSC::SourceProviderCache::add):
* parser/SourceProviderCache.h:
* parser/SourceProviderCacheItem.h:
(JSC::SourceProviderCacheItem::create):
* profiler/ProfilerCompilation.cpp:
(JSC::Profiler::Compilation::executionCounterFor):
(JSC::Profiler::Compilation::toJS):
* profiler/ProfilerCompilation.h:
* runtime/JSGlobalObject.h:

Source/WTF:

* wtf/RefPtrHashMap.h:
Add a missing std::forward.

* wtf/StdLibExtras.h:
(std::make_unique):
Add more overloads.

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

7 years agoMove DFG inline caching logic into jit/.
mark.lam@apple.com [Thu, 26 Sep 2013 20:27:14 +0000 (20:27 +0000)]
Move DFG inline caching logic into jit/.
https://bugs.webkit.org/show_bug.cgi?id=121749.

Reviewed by Geoffrey Garen.

Relanding http://trac.webkit.org/changeset/156235 after rebasing to latest
revision and fixing build breakages on Windows.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* bytecode/CallLinkInfo.cpp:
(JSC::CallLinkInfo::unlink):
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::resetStubInternal):
* bytecode/StructureStubInfo.h:
* dfg/DFGCallArrayAllocatorSlowPathGenerator.h:
(JSC::DFG::CallArrayAllocatorSlowPathGenerator::CallArrayAllocatorSlowPathGenerator):
(JSC::DFG::CallArrayAllocatorWithVariableSizeSlowPathGenerator::CallArrayAllocatorWithVariableSizeSlowPathGenerator):
* dfg/DFGJITCompiler.h:
* dfg/DFGOSRExitCompiler.h:
* dfg/DFGOperations.cpp:
(JSC::DFG::operationPutByValInternal):
* dfg/DFGOperations.h:
(JSC::DFG::operationNewTypedArrayWithSizeForType):
(JSC::DFG::operationNewTypedArrayWithOneArgumentForType):
* dfg/DFGRegisterSet.h: Removed.
* dfg/DFGRepatch.cpp: Removed.
* dfg/DFGRepatch.h: Removed.
* dfg/DFGScratchRegisterAllocator.h: Removed.
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::nonSpeculativeCompare):
(JSC::DFG::SpeculativeJIT::compilePeepHoleBranch):
(JSC::DFG::SpeculativeJIT::compare):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperation):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::cachedPutById):
(JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranch):
(JSC::DFG::CompareAndBoxBooleanSlowPathGenerator::CompareAndBoxBooleanSlowPathGenerator):
(JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompare):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::cachedPutById):
(JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranch):
(JSC::DFG::CompareAndBoxBooleanSlowPathGenerator::CompareAndBoxBooleanSlowPathGenerator):
(JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompare):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGThunks.cpp:
* dfg/DFGThunks.h:
* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileCallOrConstruct):
* ftl/FTLOSRExitCompiler.h:
* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::writeBarrier):
* jit/JIT.cpp:
(JSC::JIT::linkFor):
(JSC::JIT::linkSlowCall):
* jit/JITCall.cpp:
(JSC::JIT::compileCallEvalSlowCase):
(JSC::JIT::compileOpCallSlowCase):
(JSC::JIT::privateCompileClosureCall):
* jit/JITCall32_64.cpp:
(JSC::JIT::compileCallEvalSlowCase):
(JSC::JIT::compileOpCallSlowCase):
(JSC::JIT::privateCompileClosureCall):
* jit/JITOperationWrappers.h: Copied from Source/JavaScriptCore/jit/JITOperationWrappers.h.
* jit/JITOperations.cpp: Copied from Source/JavaScriptCore/jit/JITOperations.cpp.
(JSC::getHostCallReturnValueWithExecState):
* jit/JITOperations.h: Copied from Source/JavaScriptCore/jit/JITOperations.h.
* jit/RegisterSet.h: Copied from Source/JavaScriptCore/jit/RegisterSet.h.
* jit/Repatch.cpp: Copied from Source/JavaScriptCore/jit/Repatch.cpp.
(JSC::tryBuildGetByIDList):
* jit/Repatch.h: Copied from Source/JavaScriptCore/jit/Repatch.h.
* jit/ScratchRegisterAllocator.h: Copied from Source/JavaScriptCore/jit/ScratchRegisterAllocator.h.
* jit/ThunkGenerators.cpp:
(JSC::oldStyleGenerateSlowCaseFor):
(JSC::oldStyleLinkForGenerator):
(JSC::oldStyleLinkCallGenerator):
(JSC::oldStyleLinkConstructGenerator):
(JSC::oldStyleLinkClosureCallGenerator):
(JSC::oldStyleVirtualForGenerator):
(JSC::oldStyleVirtualCallGenerator):
(JSC::oldStyleVirtualConstructGenerator):
(JSC::emitPointerValidation):
(JSC::throwExceptionFromCallSlowPathGenerator):
(JSC::slowPathFor):
(JSC::linkForThunkGenerator):
(JSC::linkCallThunkGenerator):
(JSC::linkConstructThunkGenerator):
(JSC::linkClosureCallThunkGenerator):
(JSC::virtualForThunkGenerator):
(JSC::virtualCallThunkGenerator):
(JSC::virtualConstructThunkGenerator):
* jit/ThunkGenerators.h:

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

7 years agoRemove PassWeak.h
andersca@apple.com [Thu, 26 Sep 2013 19:48:46 +0000 (19:48 +0000)]
Remove PassWeak.h
https://bugs.webkit.org/show_bug.cgi?id=121971

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

* GNUmakefile.list.am:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:
* JavaScriptCore.xcodeproj/project.pbxproj:
* heap/PassWeak.h: Removed.
* heap/WeakInlines.h:

Source/WebCore:

* ForwardingHeaders/heap/PassWeak.h: Removed.

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

7 years ago[MediaStream API] implement VideoStreamTrack and AudioStreamTrack
eric.carlson@apple.com [Thu, 26 Sep 2013 19:37:48 +0000 (19:37 +0000)]
[MediaStream API] implement VideoStreamTrack and AudioStreamTrack
https://bugs.webkit.org/show_bug.cgi?id=121950

Reviewed by Dean Jackson.

No new tests, blocked by https://bugs.webkit.org/show_bug.cgi?id=121967

* CMakeLists.txt: Add new files.
* DerivedSources.make: Ditto.
* GNUmakefile.list.am: Ditto.

* Modules/mediastream/AudioStreamTrack.cpp: Added.
* Modules/mediastream/AudioStreamTrack.h: Added.
* Modules/mediastream/AudioStreamTrack.idl: Added.

* Modules/mediastream/MediaStream.cpp:
(WebCore::MediaStream::MediaStream): Create an AudioStreamTrack or a VideoStreamTrack.
(WebCore::MediaStream::addRemoteSource): Ditto.

* Modules/mediastream/MediaStreamTrack.cpp:
(WebCore::MediaStreamTrack::create): Removed.
* Modules/mediastream/MediaStreamTrack.h:

* Modules/mediastream/VideoStreamTrack.cpp: Added.
* Modules/mediastream/VideoStreamTrack.h: Added.
* Modules/mediastream/VideoStreamTrack.idl: Added.

* WebCore.xcodeproj/project.pbxproj: Add new files.

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

7 years agoStop using PassWeak
andersca@apple.com [Thu, 26 Sep 2013 19:23:11 +0000 (19:23 +0000)]
Stop using PassWeak
https://bugs.webkit.org/show_bug.cgi?id=121968

Reviewed by Sam Weinig.

Source/JavaScriptCore:

* heap/Weak.h:
Remove all knowledge of PassWeak.

(JSC::Weak::Weak):
These constructors don't need to be explicit.

* heap/WeakInlines.h:
(JSC::weakAdd):
Change Value to be an rvalue reference and use std::forward.

* jit/JITThunks.cpp:
(JSC::JITThunks::hostFunctionStub):
Remove PassWeak.

* runtime/RegExpCache.cpp:
(JSC::RegExpCache::lookupOrCreate):
Use Weak instead of PassWeak.

* runtime/SimpleTypedArrayController.cpp:
Change add and set to take Weak by value and std::move into place.

* runtime/WeakGCMap.h:
(JSC::WeakGCMap::get):
(JSC::WeakGCMap::set):
(JSC::WeakGCMap::add):

Source/WebCore:

Update for JavaScriptCore changes.

* bindings/js/JSDOMBinding.h:
(WebCore::setInlineCachedWrapper):
(WebCore::cacheWrapper):
* bindings/js/JSEventListener.cpp:
(WebCore::JSEventListener::JSEventListener):
* bindings/js/JSEventListener.h:
(WebCore::JSEventListener::setWrapper):
(WebCore::JSEventListener::jsFunction):
* bindings/js/JSMutationCallback.cpp:
(WebCore::JSMutationCallback::JSMutationCallback):
* bindings/js/JSNodeFilterCondition.cpp:
(WebCore::JSNodeFilterCondition::JSNodeFilterCondition):
* bindings/js/ScriptWrappableInlines.h:
(WebCore::ScriptWrappable::setWrapper):
* bindings/js/WebCoreTypedArrayController.cpp:
* bridge/jsc/BridgeJSC.cpp:
(JSC::Bindings::Instance::createRuntimeObject):
* bridge/runtime_root.cpp:
(JSC::Bindings::RootObject::addRuntimeObject):

Source/WebKit2:

Update for JavaScriptCore changes.

* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
(WebKit::NPRuntimeObjectMap::getOrCreateJSObject):

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

7 years agofast/css/font-face-data-uri.html is failing
ap@apple.com [Thu, 26 Sep 2013 19:14:28 +0000 (19:14 +0000)]
fast/css/font-face-data-uri.html is failing
https://bugs.webkit.org/show_bug.cgi?id=82744

Reviewed by Dan Bernstein.

* fast/css/font-face-data-uri.html: There is no need to keep retrying, we can just
wait for onload - as long as the font load starts early enough.

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

7 years agoPass a JSC::VM& to JS bindings object creation functions, rather than a JSC::ExecState*
weinig@apple.com [Thu, 26 Sep 2013 19:09:04 +0000 (19:09 +0000)]
Pass a JSC::VM& to JS bindings object creation functions, rather than a JSC::ExecState*
https://bugs.webkit.org/show_bug.cgi?id=121934

Reviewed by Geoffrey Garen.

../WebCore:

Reduce unnecessary loads by passing the JSC::VM to object creation/access functions
that don't need the ExecState.

* WebCore.exp.in:
* bindings/js/JSDOMBinding.h:
(WebCore::getDOMStructure):
(WebCore::deprecatedGetDOMStructure):
(WebCore::getDOMPrototype):
(WebCore::setInlineCachedWrapper):
(WebCore::createWrapper):
* bindings/js/JSDOMGlobalObject.h:
(WebCore::getDOMConstructor):
* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::JSDOMWindow::image):
* bindings/js/JSDocumentCustom.cpp:
(WebCore::JSDocument::location):
* bindings/js/JSImageConstructor.cpp:
(WebCore::JSImageConstructor::finishCreation):
* bindings/js/JSImageConstructor.h:
(WebCore::JSImageConstructor::create):
* bindings/js/ScriptWrappable.h:
* bindings/js/ScriptWrappableInlines.h:
(WebCore::ScriptWrappable::setWrapper):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHeader):
(GenerateImplementation):
(GenerateConstructorDeclaration):
(GenerateConstructorHelperMethods):
* bridge/c/CRuntimeObject.cpp:
(JSC::Bindings::CRuntimeObject::CRuntimeObject):
(JSC::Bindings::CRuntimeObject::finishCreation):
* bridge/c/CRuntimeObject.h:
(JSC::Bindings::CRuntimeObject::create):
* bridge/c/c_instance.cpp:
(JSC::Bindings::CInstance::newRuntimeObject):
* bridge/jsc/BridgeJSC.cpp:
(JSC::Bindings::Instance::newRuntimeObject):
* bridge/objc/ObjCRuntimeObject.h:
(JSC::Bindings::ObjCRuntimeObject::create):
* bridge/objc/ObjCRuntimeObject.mm:
(JSC::Bindings::ObjCRuntimeObject::ObjCRuntimeObject):
(JSC::Bindings::ObjCRuntimeObject::finishCreation):
* bridge/objc/objc_instance.mm:
(ObjcInstance::newRuntimeObject):
* bridge/objc/objc_runtime.h:
(JSC::Bindings::ObjcFallbackObjectImp::createPrototype):
* bridge/runtime_array.h:
(JSC::RuntimeArray::createPrototype):
* bridge/runtime_method.h:
(JSC::RuntimeMethod::createPrototype):
* bridge/runtime_object.cpp:
(JSC::Bindings::RuntimeObject::RuntimeObject):
(JSC::Bindings::RuntimeObject::finishCreation):
* bridge/runtime_object.h:
(JSC::Bindings::RuntimeObject::create):
(JSC::Bindings::RuntimeObject::createPrototype):

../WebKit/mac:

* Plugins/Hosted/ProxyInstance.mm:
(WebKit::ProxyInstance::newRuntimeObject):
* Plugins/Hosted/ProxyRuntimeObject.h:
(WebKit::ProxyRuntimeObject::create):
* Plugins/Hosted/ProxyRuntimeObject.mm:
(WebKit::ProxyRuntimeObject::ProxyRuntimeObject):
(WebKit::ProxyRuntimeObject::finishCreation):

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

7 years agoWeb Inspector: Activity viewer not properly reset when reloading
graouts@apple.com [Thu, 26 Sep 2013 18:40:36 +0000 (18:40 +0000)]
Web Inspector: Activity viewer not properly reset when reloading
https://bugs.webkit.org/show_bug.cgi?id=121958

Reviewed by Darin Adler.

Reset the resources count and accumulated size when we detect the main frame
has changed, which will work with documents where there are no resources besides
frames in which case WebInspector.Frame.Event.AllResourcesRemoved was not fired
and our counts wouldn't be reset correctly.

* UserInterface/DashboardManager.js:
(WebInspector.DashboardManager):
(WebInspector.DashboardManager.prototype._mainResourceDidChange):

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

7 years agoUnreviewed, rolling out r156474.
commit-queue@webkit.org [Thu, 26 Sep 2013 18:31:29 +0000 (18:31 +0000)]
Unreviewed, rolling out r156474.
http://trac.webkit.org/changeset/156474
https://bugs.webkit.org/show_bug.cgi?id=121966

Broke the builds. (Requested by xenon on #webkit).

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::registerName):
(JSC::CodeBlock::dumpBytecode):
(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::createActivation):
(JSC::CodeBlock::nameForRegister):
* bytecode/CodeBlock.h:
(JSC::unmodifiedArgumentsRegister):
(JSC::CodeBlock::isKnownNotImmediate):
(JSC::CodeBlock::setThisRegister):
(JSC::CodeBlock::thisRegister):
(JSC::CodeBlock::setArgumentsRegister):
(JSC::CodeBlock::argumentsRegister):
(JSC::CodeBlock::uncheckedArgumentsRegister):
(JSC::CodeBlock::setActivationRegister):
(JSC::CodeBlock::activationRegister):
(JSC::CodeBlock::uncheckedActivationRegister):
(JSC::CodeBlock::usesArguments):
(JSC::CodeBlock::isCaptured):
* bytecode/Instruction.h:
* bytecode/LazyOperandValueProfile.h:
(JSC::LazyOperandValueProfileKey::LazyOperandValueProfileKey):
(JSC::LazyOperandValueProfileKey::operator!):
(JSC::LazyOperandValueProfileKey::hash):
(JSC::LazyOperandValueProfileKey::operand):
(JSC::LazyOperandValueProfileKey::isHashTableDeletedValue):
(JSC::LazyOperandValueProfile::LazyOperandValueProfile):
* bytecode/MethodOfGettingAValueProfile.cpp:
(JSC::MethodOfGettingAValueProfile::fromLazyOperand):
(JSC::MethodOfGettingAValueProfile::getSpecFailBucket):
* bytecode/Operands.h:
(JSC::localToOperand):
(JSC::operandIsLocal):
(JSC::operandToLocal):
(JSC::operandIsArgument):
(JSC::operandToArgument):
(JSC::argumentToOperand):
(JSC::Operands::operand):
(JSC::Operands::hasOperand):
(JSC::Operands::setOperand):
(JSC::Operands::operandForIndex):
(JSC::Operands::setOperandFirstTime):
* bytecode/UnlinkedCodeBlock.cpp:
(JSC::UnlinkedCodeBlock::UnlinkedCodeBlock):
* bytecode/UnlinkedCodeBlock.h:
(JSC::UnlinkedCodeBlock::setThisRegister):
(JSC::UnlinkedCodeBlock::setActivationRegister):
(JSC::UnlinkedCodeBlock::setArgumentsRegister):
(JSC::UnlinkedCodeBlock::usesArguments):
(JSC::UnlinkedCodeBlock::argumentsRegister):
(JSC::UnlinkedCodeBlock::usesGlobalObject):
(JSC::UnlinkedCodeBlock::setGlobalObjectRegister):
(JSC::UnlinkedCodeBlock::globalObjectRegister):
(JSC::UnlinkedCodeBlock::thisRegister):
(JSC::UnlinkedCodeBlock::activationRegister):
* bytecode/ValueRecovery.h:
(JSC::ValueRecovery::displacedInJSStack):
(JSC::ValueRecovery::virtualRegister):
(JSC::ValueRecovery::dumpInContext):
* bytecode/VirtualRegister.h:
(WTF::printInternal):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::generate):
(JSC::BytecodeGenerator::addVar):
(JSC::BytecodeGenerator::BytecodeGenerator):
(JSC::BytecodeGenerator::createLazyRegisterIfNecessary):
(JSC::BytecodeGenerator::newRegister):
(JSC::BytecodeGenerator::emitLoadGlobalObject):
(JSC::BytecodeGenerator::emitGetArgumentsLength):
(JSC::BytecodeGenerator::emitGetArgumentByVal):
(JSC::BytecodeGenerator::createArgumentsIfNecessary):
(JSC::BytecodeGenerator::emitReturn):
* bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::registerFor):
* bytecompiler/RegisterID.h:
(JSC::RegisterID::RegisterID):
(JSC::RegisterID::setIndex):
(JSC::RegisterID::index):
* debugger/DebuggerCallFrame.cpp:
(JSC::DebuggerCallFrame::thisObject):
* dfg/DFGAbstractHeap.h:
(JSC::DFG::AbstractHeap::Payload::Payload):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):
(JSC::DFG::::clobberCapturedVars):
* dfg/DFGArgumentPosition.h:
(JSC::DFG::ArgumentPosition::dump):
* dfg/DFGArgumentsSimplificationPhase.cpp:
(JSC::DFG::ArgumentsSimplificationPhase::run):
(JSC::DFG::ArgumentsSimplificationPhase::observeBadArgumentsUse):
(JSC::DFG::ArgumentsSimplificationPhase::isOKToOptimize):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::newVariableAccessData):
(JSC::DFG::ByteCodeParser::getDirect):
(JSC::DFG::ByteCodeParser::get):
(JSC::DFG::ByteCodeParser::setDirect):
(JSC::DFG::ByteCodeParser::set):
(JSC::DFG::ByteCodeParser::getLocal):
(JSC::DFG::ByteCodeParser::setLocal):
(JSC::DFG::ByteCodeParser::getArgument):
(JSC::DFG::ByteCodeParser::setArgument):
(JSC::DFG::ByteCodeParser::findArgumentPositionForLocal):
(JSC::DFG::ByteCodeParser::findArgumentPosition):
(JSC::DFG::ByteCodeParser::flush):
(JSC::DFG::ByteCodeParser::flushDirect):
(JSC::DFG::ByteCodeParser::getToInt32):
(JSC::DFG::ByteCodeParser::getThis):
(JSC::DFG::ByteCodeParser::addCall):
(JSC::DFG::ByteCodeParser::InlineStackEntry::remapOperand):
(JSC::DFG::ByteCodeParser::handleCall):
(JSC::DFG::ByteCodeParser::emitFunctionChecks):
(JSC::DFG::ByteCodeParser::emitArgumentPhantoms):
(JSC::DFG::ByteCodeParser::handleInlining):
(JSC::DFG::ByteCodeParser::handleMinMax):
(JSC::DFG::ByteCodeParser::handleIntrinsic):
(JSC::DFG::ByteCodeParser::handleTypedArrayConstructor):
(JSC::DFG::ByteCodeParser::handleConstantInternalFunction):
(JSC::DFG::ByteCodeParser::handleGetByOffset):
(JSC::DFG::ByteCodeParser::handleGetById):
(JSC::DFG::ByteCodeParser::parseBlock):
(JSC::DFG::ByteCodeParser::InlineStackEntry::InlineStackEntry):
(JSC::DFG::ByteCodeParser::parse):
* dfg/DFGCFGSimplificationPhase.cpp:
* dfg/DFGCPSRethreadingPhase.cpp:
(JSC::DFG::CPSRethreadingPhase::canonicalizeGetLocal):
(JSC::DFG::CPSRethreadingPhase::canonicalizeFlushOrPhantomLocal):
(JSC::DFG::CPSRethreadingPhase::canonicalizeSetArgument):
* dfg/DFGCapabilities.cpp:
(JSC::DFG::capabilityLevel):
* dfg/DFGConstantFoldingPhase.cpp:
(JSC::DFG::ConstantFoldingPhase::isCapturedAtOrAfter):
* dfg/DFGFlushLivenessAnalysisPhase.cpp:
(JSC::DFG::FlushLivenessAnalysisPhase::setForNode):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::argumentsRegisterFor):
(JSC::DFG::Graph::uncheckedArgumentsRegisterFor):
(JSC::DFG::Graph::uncheckedActivationRegisterFor):
(JSC::DFG::Graph::valueProfileFor):
* dfg/DFGJITCode.cpp:
(JSC::DFG::JITCode::reconstruct):
* dfg/DFGNode.h:
(JSC::DFG::Node::Node):
(JSC::DFG::Node::convertToGetLocalUnlinked):
(JSC::DFG::Node::hasVirtualRegister):
(JSC::DFG::Node::virtualRegister):
(JSC::DFG::Node::setVirtualRegister):
* dfg/DFGOSREntry.cpp:
(JSC::DFG::prepareOSREntry):
* dfg/DFGOSREntrypointCreationPhase.cpp:
(JSC::DFG::OSREntrypointCreationPhase::run):
* dfg/DFGOSRExit.h:
* dfg/DFGOSRExitCompiler32_64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGRegisterBank.h:
(JSC::DFG::RegisterBank::tryAllocate):
(JSC::DFG::RegisterBank::allocateSpecific):
(JSC::DFG::RegisterBank::retain):
(JSC::DFG::RegisterBank::isInUse):
(JSC::DFG::RegisterBank::dump):
(JSC::DFG::RegisterBank::releaseAtIndex):
(JSC::DFG::RegisterBank::allocateInternal):
(JSC::DFG::RegisterBank::MapEntry::MapEntry):
* dfg/DFGScoreBoard.h:
(JSC::DFG::ScoreBoard::allocate):
(JSC::DFG::ScoreBoard::use):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::SpeculativeJIT):
(JSC::DFG::SpeculativeJIT::checkConsistency):
(JSC::DFG::SpeculativeJIT::compileMovHint):
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::compileCurrentBlock):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::allocate):
(JSC::DFG::SpeculativeJIT::fprAllocate):
(JSC::DFG::SpeculativeJIT::silentSpillAllRegistersImpl):
(JSC::DFG::SpeculativeJIT::flushRegisters):
(JSC::DFG::SpeculativeJIT::isFlushed):
(JSC::DFG::SpeculativeJIT::argumentSlot):
(JSC::DFG::SpeculativeJIT::argumentTagSlot):
(JSC::DFG::SpeculativeJIT::argumentPayloadSlot):
(JSC::DFG::SpeculativeJIT::valueSourceForOperand):
(JSC::DFG::SpeculativeJIT::setNodeForOperand):
(JSC::DFG::SpeculativeJIT::valueSourceReferenceForOperand):
(JSC::DFG::SpeculativeJIT::recordSetLocal):
(JSC::DFG::SpeculativeJIT::generationInfoFromVirtualRegister):
(JSC::DFG::SpeculativeJIT::computeValueRecoveryFor):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGValidate.cpp:
(JSC::DFG::Validate::validate):
(JSC::DFG::Validate::validateCPS):
(JSC::DFG::Validate::checkOperand):
(JSC::DFG::Validate::reportValidationContext):
* dfg/DFGValueRecoveryOverride.h:
(JSC::DFG::ValueRecoveryOverride::ValueRecoveryOverride):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::operand):
(JSC::DFG::VariableAccessData::shouldUseDoubleFormatAccordingToVote):
(JSC::DFG::VariableAccessData::tallyVotesForShouldUseDoubleFormat):
(JSC::DFG::VariableAccessData::flushFormat):
* dfg/DFGVariableEvent.h:
(JSC::DFG::VariableEvent::spill):
(JSC::DFG::VariableEvent::setLocal):
* dfg/DFGVariableEventStream.cpp:
(JSC::DFG::VariableEventStream::reconstruct):
* dfg/DFGVirtualRegisterAllocationPhase.cpp:
(JSC::DFG::VirtualRegisterAllocationPhase::run):
* ftl/FTLExitArgumentForOperand.h:
(JSC::FTL::ExitArgumentForOperand::ExitArgumentForOperand):
(JSC::FTL::ExitArgumentForOperand::operand):
* ftl/FTLLink.cpp:
(JSC::FTL::link):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::LowerDFGToLLVM):
(JSC::FTL::LowerDFGToLLVM::compileGetArgument):
(JSC::FTL::LowerDFGToLLVM::compileExtractOSREntryLocal):
(JSC::FTL::LowerDFGToLLVM::compileCallOrConstruct):
(JSC::FTL::LowerDFGToLLVM::appendOSRExit):
(JSC::FTL::LowerDFGToLLVM::observeMovHint):
(JSC::FTL::LowerDFGToLLVM::addressFor):
(JSC::FTL::LowerDFGToLLVM::payloadFor):
(JSC::FTL::LowerDFGToLLVM::tagFor):
* ftl/FTLOSREntry.cpp:
(JSC::FTL::prepareOSREntry):
* ftl/FTLOSRExit.cpp:
(JSC::FTL::OSRExit::convertToForward):
* ftl/FTLOSRExit.h:
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
* interpreter/CallFrame.h:
* interpreter/Interpreter.cpp:
(JSC::Interpreter::dumpRegisters):
(JSC::unwindCallFrame):
(JSC::Interpreter::unwind):
* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::addressFor):
(JSC::AssemblyHelpers::tagFor):
(JSC::AssemblyHelpers::payloadFor):
(JSC::AssemblyHelpers::argumentsRegisterFor):
* jit/JIT.h:
* jit/JITCall.cpp:
(JSC::JIT::compileLoadVarargs):
* jit/JITInlines.h:
(JSC::JIT::emitGetVirtualRegister):
* jit/JITOpcodes.cpp:
(JSC::JIT::emit_op_tear_off_arguments):
(JSC::JIT::emit_op_get_pnames):
(JSC::JIT::emit_op_enter):
(JSC::JIT::emit_op_create_arguments):
(JSC::JIT::emitSlow_op_get_argument_by_val):
* jit/JITOpcodes32_64.cpp:
(JSC::JIT::emit_op_enter):
* jit/JITStubs.cpp:
(JSC::DEFINE_STUB_FUNCTION):
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* profiler/ProfilerBytecodeSequence.cpp:
(JSC::Profiler::BytecodeSequence::BytecodeSequence):
* runtime/CommonSlowPaths.cpp:
(JSC::SLOW_PATH_DECL):
* runtime/JSActivation.cpp:
(JSC::JSActivation::argumentsGetter):

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

7 years agoWeb Inspector: Keep DOM tree expanded on page reload
graouts@apple.com [Thu, 26 Sep 2013 18:29:56 +0000 (18:29 +0000)]
Web Inspector: Keep DOM tree expanded on page reload
https://bugs.webkit.org/show_bug.cgi?id=121665

Reviewed by Darin Adler.

Allow the node that was selected before reloading the page to be selected
at the page is reloaded. Credit goes to Joseph Pecoraro for the fix.

* UserInterface/DOMTreeContentView.js:
(WebInspector.DOMTreeContentView.prototype._rootDOMNodeAvailable.selectNode):

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

7 years agoAttempt to fix MSVC build
oliver@apple.com [Thu, 26 Sep 2013 18:13:22 +0000 (18:13 +0000)]
Attempt to fix MSVC build

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

7 years ago[WK2] Crash at at com.apple.WebKit2: WebKit::VoidCallback::invalidate + 46
jer.noble@apple.com [Thu, 26 Sep 2013 18:13:19 +0000 (18:13 +0000)]
[WK2] Crash at at com.apple.WebKit2: WebKit::VoidCallback::invalidate + 46
https://bugs.webkit.org/show_bug.cgi?id=121910

Reviewed by Darin Adler.

Store a copy of the VoidCallback passed to WKPage, and invalidate the callback
during dealloc. The VoidCallback class assumes that it will only ever be
invalidated or invoked once, so change the ASSERTs into an early return.

* UIProcess/GenericCallback.h:
(WebKit::VoidCallback::performCallback): Exit early if previously invalidated.
(WebKit::VoidCallback::invalidate): Ditto.
* UIProcess/mac/WKFullScreenWindowController.h:
* UIProcess/mac/WKFullScreenWindowController.mm:
(-[WKFullScreenWindowController dealloc]): Invalidate the repaint callback if present.
(-[WKFullScreenWindowController finishedExitFullScreenAnimation:]): Ditto & create a new callback.
(-[WKFullScreenWindowController completeFinishExitFullScreenAnimationAfterRepaint]): Clear the callback.

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

7 years agoUnreviewed, rolling out r156451.
commit-queue@webkit.org [Thu, 26 Sep 2013 18:13:00 +0000 (18:13 +0000)]
Unreviewed, rolling out r156451.
http://trac.webkit.org/changeset/156451
https://bugs.webkit.org/show_bug.cgi?id=121965

Broke two fast/multicol tests. (Requested by kling on
#webkit).

Source/WebCore:

* rendering/FlowThreadController.cpp:
(WebCore::FlowThreadController::updateRenderFlowThreadLayersIfNeeded):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::propagateStyleToAnonymousChildren):
* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::layout):
(WebCore::RenderFlowThread::regionForCompositedLayer):
(WebCore::RenderFlowThread::updateRegionForRenderLayer):
(WebCore::RenderFlowThread::updateLayerToRegionMappings):
* rendering/RenderFlowThread.h:
* rendering/RenderGeometryMap.cpp:
* rendering/RenderGeometryMap.h:
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateLayerBounds):
* rendering/RenderLayer.h:
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::shouldClipCompositedBounds):
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
* rendering/RenderLayerBacking.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::computeCompositingRequirements):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
(WebCore::RenderLayerCompositor::canBeComposited):
(WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
* rendering/RenderLayerCompositor.h:
* rendering/RenderMultiColumnSet.cpp:
* rendering/RenderMultiColumnSet.h:
* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::setRequiresLayerForCompositing):
* rendering/RenderRegion.h:
* rendering/RenderRegionSet.h:
* rendering/RenderTreeAsText.cpp:
(WebCore::writeLayers):

LayoutTests:

* fast/regions/layers/accelerated-compositing/crash-transform-inside-region-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/crash-transform-inside-region.html: Removed.
* fast/regions/layers/accelerated-compositing/floated-region-with-transformed-child-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/floated-region-with-transformed-child.html: Removed.
* fast/regions/layers/accelerated-compositing/move-layer-from-one-region-to-another-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/move-layer-from-one-region-to-another.html: Removed.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-for-video-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-for-video.html: Removed.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding.html: Removed.
* fast/regions/layers/accelerated-compositing/region-as-layer-in-another-flowthread-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/region-as-layer-in-another-flowthread.html: Removed.
* fast/regions/layers/accelerated-compositing/transform-transparent-positioned-video-inside-region-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/transform-transparent-positioned-video-inside-region.html: Removed.
* fast/regions/layers/accelerated-compositing/transformed-layer-inside-transformed-layer-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/transformed-layer-inside-transformed-layer.html: Removed.
* fast/regions/layers/accelerated-compositing/z-index-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/z-index-update-expected.html: Removed.
* fast/regions/layers/accelerated-compositing/z-index-update.html: Removed.
* fast/regions/layers/accelerated-compositing/z-index.html: Removed.

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

7 years ago[sh4] JSValue* exception is unused since r70703 in JITStackFrame.
commit-queue@webkit.org [Thu, 26 Sep 2013 18:09:36 +0000 (18:09 +0000)]
[sh4] JSValue* exception is unused since r70703 in JITStackFrame.
https://bugs.webkit.org/show_bug.cgi?id=121962

This is a cosmetic change, but it could avoid people reading sh4 part to
waste time to understand why there is a JSValue* here.

Patch by Julien Brianceau <jbriance@cisco.com> on 2013-09-26
Reviewed by Darin Adler.

* jit/JITStubs.h:

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

7 years agoWeakGCMap should not inherit from HashMap
andersca@apple.com [Thu, 26 Sep 2013 18:00:06 +0000 (18:00 +0000)]
WeakGCMap should not inherit from HashMap
https://bugs.webkit.org/show_bug.cgi?id=121964

Reviewed by Geoffrey Garen.

Add the HashMap as a member variable instead and implement the missing member functions.

* runtime/WeakGCMap.h:

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

7 years agoXvfbDriver should set up Xvfb instances providing screens of 8-bit depth
zandobersek@gmail.com [Thu, 26 Sep 2013 17:57:53 +0000 (17:57 +0000)]
XvfbDriver should set up Xvfb instances providing screens of 8-bit depth
https://bugs.webkit.org/show_bug.cgi?id=121951

Reviewed by Carlos Garcia Campos.

Screens with 24-bit depth are causing problems as it doesn't seem to be possible to fall back to
software rendering successfully on the GTK 64-bit release builder, resulting in crashes in almost
500 layout tests that trigger accelerated compositing to be used.

* Scripts/webkitpy/port/xvfbdriver.py:
(XvfbDriver._start):
* Scripts/webkitpy/port/xvfbdriver_unittest.py: Update unit test baselines.
(XvfbDriverTest.test_start_no_pixel_tests):
(XvfbDriverTest.test_start_pixel_tests):
(XvfbDriverTest.test_start_arbitrary_worker_number):
(XvfbDriverTest.test_next_free_display):
(XvfbDriverTest.test_start_next_worker):

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

7 years agoVirtualRegister should be a class
msaboff@apple.com [Thu, 26 Sep 2013 17:50:46 +0000 (17:50 +0000)]
VirtualRegister should be a class
https://bugs.webkit.org/show_bug.cgi?id=121732

Reviewed by Geoffrey Garen.

This is a refactoring change.  Changed VirtualRegister from an enum to a class.
Moved Operands::operandIsArgument(), operandToArgument(), argumentToOperand()
and the similar functions for locals to VirtualRegister class.

This is in preparation for changing the offset for the first local register from
0 to -1.  This is needed since most native calling conventions have the architected
frame pointer (e.g. %rbp for X86) point at the slot that stores the previous frame
pointer.  Local values start below that address.

* bytecode/CodeBlock.cpp:
* bytecode/CodeBlock.h:
* bytecode/Instruction.h:
* bytecode/LazyOperandValueProfile.h:
* bytecode/MethodOfGettingAValueProfile.cpp:
* bytecode/Operands.h:
* bytecode/UnlinkedCodeBlock.cpp:
* bytecode/UnlinkedCodeBlock.h:
* bytecode/ValueRecovery.h:
* bytecode/VirtualRegister.h:
* bytecompiler/BytecodeGenerator.cpp:
* bytecompiler/BytecodeGenerator.h:
* bytecompiler/RegisterID.h:
* debugger/DebuggerCallFrame.cpp:
* dfg/DFGAbstractHeap.h:
* dfg/DFGAbstractInterpreterInlines.h:
* dfg/DFGArgumentPosition.h:
* dfg/DFGArgumentsSimplificationPhase.cpp:
* dfg/DFGByteCodeParser.cpp:
* dfg/DFGCFGSimplificationPhase.cpp:
* dfg/DFGCPSRethreadingPhase.cpp:
* dfg/DFGCapabilities.cpp:
* dfg/DFGConstantFoldingPhase.cpp:
* dfg/DFGFlushLivenessAnalysisPhase.cpp:
* dfg/DFGGraph.cpp:
* dfg/DFGGraph.h:
* dfg/DFGJITCode.cpp:
* dfg/DFGNode.h:
* dfg/DFGOSREntry.cpp:
* dfg/DFGOSREntrypointCreationPhase.cpp:
* dfg/DFGOSRExit.h:
* dfg/DFGOSRExitCompiler32_64.cpp:
* dfg/DFGOSRExitCompiler64.cpp:
* dfg/DFGRegisterBank.h:
* dfg/DFGScoreBoard.h:
* dfg/DFGSpeculativeJIT.cpp:
* dfg/DFGSpeculativeJIT.h:
* dfg/DFGSpeculativeJIT64.cpp:
* dfg/DFGValidate.cpp:
* dfg/DFGValueRecoveryOverride.h:
* dfg/DFGVariableAccessData.h:
* dfg/DFGVariableEvent.h:
* dfg/DFGVariableEventStream.cpp:
* dfg/DFGVirtualRegisterAllocationPhase.cpp:
* ftl/FTLExitArgumentForOperand.h:
* ftl/FTLLink.cpp:
* ftl/FTLLowerDFGToLLVM.cpp:
* ftl/FTLOSREntry.cpp:
* ftl/FTLOSRExit.cpp:
* ftl/FTLOSRExit.h:
* ftl/FTLOSRExitCompiler.cpp:
* interpreter/CallFrame.h:
* interpreter/Interpreter.cpp:
* jit/AssemblyHelpers.h:
* jit/JIT.h:
* jit/JITCall.cpp:
* jit/JITInlines.h:
* jit/JITOpcodes.cpp:
* jit/JITOpcodes32_64.cpp:
* jit/JITStubs.cpp:
* llint/LLIntSlowPaths.cpp:
* profiler/ProfilerBytecodeSequence.cpp:
* runtime/CommonSlowPaths.cpp:
* runtime/JSActivation.cpp:

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

7 years ago[MediaStream] Cleanup platform interface
eric.carlson@apple.com [Thu, 26 Sep 2013 17:43:07 +0000 (17:43 +0000)]
[MediaStream] Cleanup platform interface
https://bugs.webkit.org/show_bug.cgi?id=121935

Reviewed by Jer Noble.

No new tests, tests will be updated in the next patch.

* CMakeLists.txt: Remove MediaStreamComponent.cpp.
* GNUmakefile.list.am: Remove MediaStreamComponent.h|cpp and MediaStreamSourcesQueryClient.h.
    Add MediaStreamConstraintsValidationClient.h and MediaStreamCreationClient.h.

* Modules/mediastream/MediaStream.cpp:
(WebCore::processTrack): Duplicate MediaStreamSource when necessary to work around bug 121954.
(WebCore::createFromSourceVectors): MediaStreamCenter::instance -> MediaStream::sharedStreamCenter.
(WebCore::MediaStream::MediaStream): *Components -> *Streams.
(WebCore::MediaStream::setEnded): New.
(WebCore::MediaStream::stop):  MediaStreamCenter::instance -> MediaStream::sharedStreamCenter.
(WebCore::MediaStream::addTrack): Append the track parameter rather than duplicating it, as per spec.
(WebCore::MediaStream::removeTrack): *Components -> *Streams.
(WebCore::MediaStream::trackDidEnd): Renamed from trackEnded.
(WebCore::MediaStream::streamDidEnd): Renamed from streamEnded.
(WebCore::MediaStream::addRemoteSource): Renamed from addRemoteTrack. *Components -> *Streams.
(WebCore::MediaStream::removeRemoteSource): Renamed from removeRemoteTrack. *Components -> *Streams.
* Modules/mediastream/MediaStream.h:

* Modules/mediastream/MediaStreamTrack.cpp:
(WebCore::MediaStreamTrack::create): *Component -> *Stream.
(WebCore::MediaStreamTrack::MediaStreamTrack): Don't assume source is valid.
(WebCore::MediaStreamTrack::~MediaStreamTrack): Ditto.
(WebCore::MediaStreamTrack::kind): Ditto. AtomicString -> const AtomicString&.
(WebCore::MediaStreamTrack::setSource): Moved from .h file.
(WebCore::MediaStreamTrack::id): Don't assume source is valid. Create ID when the source doesn't have one.
(WebCore::MediaStreamTrack::label): Don't assume source is valid.
(WebCore::MediaStreamTrack::enabled):
(WebCore::MediaStreamTrack::setEnabled): *Component -> *Stream. MediaStreamCenter::instance -> MediaStreamCenter::shared.
(WebCore::MediaStreamTrack::readyState): "muted" is not a readyState, but "new" is.
(WebCore::MediaStreamTrack::getSources): MediaStreamCenter::instance -> MediaStreamCenter::shared.
(WebCore::MediaStreamTrack::ended): *Component -> *Stream.
(WebCore::MediaStreamTrack::sourceChangedState): Dispatch "started" and "unmuted" events.
(WebCore::MediaStreamTrack::trackDidEnd): Renamed from didEndTrack. m_component -> m_source.
* Modules/mediastream/MediaStreamTrack.h:

* Modules/mediastream/RTCDTMFSender.cpp:
(WebCore::RTCDTMFSender::create): track->component() -> track->source();

* Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::didRemoveRemoteStream): Ditto.

* Modules/mediastream/RTCStatsRequestImpl.cpp:
(WebCore::RTCStatsRequestImpl::RTCStatsRequestImpl): Ditto.
(WebCore::RTCStatsRequestImpl::component): Removed, it was unused.
* Modules/mediastream/RTCStatsRequestImpl.h:

* Modules/mediastream/UserMediaClient.h:
* Modules/mediastream/UserMediaController.h:
(WebCore::UserMediaController::requestPermission): Renamed from requestUserMedia, get rid of source
    vector parameters.
(WebCore::UserMediaController::cancelRequest): Renamed from cancelUserMediaRequest.

* Modules/mediastream/UserMediaRequest.cpp:
(WebCore::parseOptions): MediaConstraintsImpl -> MediaConstraints.
(WebCore::UserMediaRequest::create): Ditto.
(WebCore::UserMediaRequest::UserMediaRequest): Ditto.
(WebCore::UserMediaRequest::securityOrigin): New.
(WebCore::UserMediaRequest::start): Request constraint validation.
(WebCore::UserMediaRequest::constraintsValidated): New. Callback from media engine when constraints
    can be supported.
(WebCore::UserMediaRequest::requestPermission): New. Ask user media client for permission to access media.
(WebCore::UserMediaRequest::userMediaAccessGranted): New. Access has been granted.
(WebCore::UserMediaRequest::createMediaStream): New. Allowed to access media, ask media engine
    to create stream sources.
(WebCore::UserMediaRequest::userMediaAccessDenied): New. User media client has denied access request.
(WebCore::UserMediaRequest::constraintsInvalid): New. Media engine can not support constraints.
(WebCore::UserMediaRequest::didCreateStream): New. Media engine has created stream sources.
(WebCore::UserMediaRequest::callSuccessHandler): New. Create stream from sources and call success handler.
(WebCore::UserMediaRequest::failedToCreateStreamWithConstraintsError): Renamed from constraintFailure.
(WebCore::UserMediaRequest::failedToCreateStreamWithPermissionError): Renamed from permissionFailure.
(WebCore::UserMediaRequest::callErrorHandler):
(WebCore::UserMediaRequest::contextDestroyed): cancelUserMediaRequest -> cancelRequest.
* Modules/mediastream/UserMediaRequest.h:

* Modules/webaudio/AudioContext.cpp:
(WebCore::AudioContext::createMediaStreamSource): localAudio->component()->source() -> localAudio->source().

* Modules/webaudio/MediaStreamAudioDestinationNode.cpp:
(WebCore::MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode): MediaStreamSource::TypeAudio ->
    MediaStreamSource::Audio, MediaStreamSource::ReadyStateLive -> MediaStreamSource::Live.
    MediaStreamCenter::instance -> MediaStreamCenter::shared.

* WebCore.exp.in: Export new symbols.

* WebCore.xcodeproj/project.pbxproj: Add new files and remove deleted files.

* dom/EventNames.h: Define "started" event.

* platform/mediastream/MediaStreamCenter.cpp:
(WebCore::mediaStreamCenterOverride): Make it possible to override the shared stream center. Will
    be used for testing in a later patch.
(WebCore::MediaStreamCenter::shared): Renamed from instance. Return current stream center.
(WebCore::MediaStreamCenter::setSharedStreamCenter): Override current stream center.
(WebCore::MediaStreamCenter::endLocalMediaStream): Never call the descriptor client, always call
    the descriptor and let it deal with the client.
* platform/mediastream/MediaStreamCenter.h:

* platform/mediastream/MediaStreamComponent.cpp: Removed.
* platform/mediastream/MediaStreamComponent.h: Removed.

* platform/mediastream/MediaStreamConstraintsValidationClient.h: Added.
* platform/mediastream/MediaStreamCreationClient.h: Added.

* platform/mediastream/MediaStreamDescriptor.cpp:
(WebCore::MediaStreamDescriptor::addSource): *Component -> *Source.
(WebCore::MediaStreamDescriptor::removeSource): Ditto.
(WebCore::MediaStreamDescriptor::addRemoteSource): Ditto.
(WebCore::MediaStreamDescriptor::removeRemoteSource): Ditto.
(WebCore::MediaStreamDescriptor::MediaStreamDescriptor): Ditto.
(WebCore::MediaStreamDescriptor::setEnded): Ditto. Set source readyStates to Ended.
* platform/mediastream/MediaStreamDescriptor.h:

* platform/mediastream/MediaStreamSource.cpp:
(WebCore::MediaStreamSource::MediaStreamSource): Initialize new member variables.
(WebCore::MediaStreamSource::setReadyState): Early return when the state hasn't changed.
(WebCore::MediaStreamSource::setStream): New.
(WebCore::MediaStreamSource::setMuted): New.
* platform/mediastream/MediaStreamSource.h:

* platform/mediastream/MediaStreamSourcesQueryClient.h: Removed.

* platform/mediastream/RTCPeerConnectionHandler.h:
* platform/mediastream/RTCStatsRequest.h:

* platform/mediastream/blackberry/MediaStreamCenterBlackBerry.cpp: Update for new MediaStreamCenter API.
* platform/mediastream/blackberry/MediaStreamCenterBlackBerry.h:

* platform/mediastream/gstreamer/MediaStreamCenterGStreamer.cpp: Ditto.
* platform/mediastream/gstreamer/MediaStreamCenterGStreamer.h:

* platform/mediastream/mac/MediaStreamCenterMac.cpp: Ditto.
* platform/mediastream/mac/MediaStreamCenterMac.h:

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

7 years agoTiled drawing should not imply threaded scrolling
timothy_horton@apple.com [Thu, 26 Sep 2013 17:34:33 +0000 (17:34 +0000)]
Tiled drawing should not imply threaded scrolling
https://bugs.webkit.org/show_bug.cgi?id=121874
<rdar://problem/15071494>

Reviewed by Sam Weinig.

* Shared/DrawingAreaInfo.h:
We can have DrawingAreaTypeTiledCoreAnimation without threaded scrolling.

* Shared/WebPreferencesStore.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetThreadedScrollingEnabled):
(WKPreferencesGetThreadedScrollingEnabled):
* UIProcess/API/C/WKPreferencesPrivate.h:
Add a preference for threaded scrolling.

* UIProcess/API/mac/WKView.mm:
(-[WKView WebKit::]):
* UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
* UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
* WebProcess/WebPage/DrawingArea.cpp:
(WebKit::DrawingArea::create):
* WebProcess/WebPage/DrawingArea.h:
Make it so we can use TiledCoreAnimationDrawingArea without ENABLE(THREADED_SCROLLING).

* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::shouldUseTiledBackingForFrame):
* WebProcess/WebCoreSupport/WebChromeClient.h:
Override shouldUseTiledBackingForFrame; ask the drawing area if we want a tiled backing for the given frame.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::~WebPage):
* WebProcess/WebPage/WebPage.h:
Move attaching and detaching the scrolling tree into WebPage.
Store whether or not this page is going to use threaded scrolling once, as this
cannot change through the life of a page.

* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
(WebKit::TiledCoreAnimationDrawingArea::~TiledCoreAnimationDrawingArea):
Move attaching and detaching the scrolling tree into WebPage.

(WebKit::TiledCoreAnimationDrawingArea::didInstallPageOverlay):
(WebKit::TiledCoreAnimationDrawingArea::didUninstallPageOverlay):
(WebKit::TiledCoreAnimationDrawingArea::updatePreferences):
(WebKit::TiledCoreAnimationDrawingArea::dispatchAfterEnsuringUpdatedScrollPosition):
Only do scrolling coordinator work if we have a scrolling coordinator.

(WebKit::TiledCoreAnimationDrawingArea::shouldUseTiledBackingForFrame):
TiledCoreAnimationDrawingArea always wants a tiled backing for the main frame.

No new tests; a near-future patch is going to put the majority of layout
tests into the tiled-drawing-without-threaded-scrolling mode.

* page/ChromeClient.h:
(WebCore::ChromeClient::shouldUseTiledBackingForFrame):
Add a ChromeClient callback to determine whether a given frame wants a TiledBacking for its contents.

* page/FrameView.h:
* WebCore.exp.in:
Make isMainFrameView public and export it for use in WebKit2.

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::RenderLayerBacking):
Make use of shouldUseTiledBackingForFrame instead of predicating the
main frame using a tile cache on whether we have a scrolling coordinator.

* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::mainFrameBackingIsTiled): Added.

(WebCore::RenderLayerCompositor::shouldCompositeOverflowControls):
(WebCore::RenderLayerCompositor::requiresOverhangAreasLayer):
(WebCore::RenderLayerCompositor::requiresContentShadowLayer):
All of these checks for existence of a scrollingCoordinator should actually
key off whether we're using tiled drawing at the root; they have nothing
to do with threaded scrolling.

* rendering/RenderLayerCompositor.h:

* WebKitTestRunner/mac/PlatformWebViewMac.mm:
(WTR::PlatformWebView::PlatformWebView):
The existing tiled-drawing layout tests require threaded scrolling to be enabled.

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

7 years agoMark IDBDatabase "FINAL" now that http://webkit.org/b/121747 is fixed.
beidson@apple.com [Thu, 26 Sep 2013 17:33:56 +0000 (17:33 +0000)]
Mark IDBDatabase "FINAL" now that webkit.org/b/121747 is fixed.

Rubberstamped by Andreas Kling

* Modules/indexeddb/IDBDatabase.h: Mark this class FINAL.

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

7 years agoOne more IndexedDB rebaseline.
akling@apple.com [Thu, 26 Sep 2013 17:24:24 +0000 (17:24 +0000)]
One more IndexedDB rebaseline.

* js/dom/global-constructors-attributes-expected.txt:

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

7 years agoWeak should have a move constructor and move assignment operator
andersca@apple.com [Thu, 26 Sep 2013 17:19:42 +0000 (17:19 +0000)]
Weak should have a move constructor and move assignment operator
https://bugs.webkit.org/show_bug.cgi?id=121963

Reviewed by Oliver Hunt.

This is the first step towards getting rid of PassWeak.

* API/JSClassRef.cpp:
(OpaqueJSClass::prototype):
* heap/Weak.h:
* heap/WeakInlines.h:
(JSC::::Weak):
(JSC::::leakImpl):
* runtime/SimpleTypedArrayController.cpp:
(JSC::SimpleTypedArrayController::toJS):

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

7 years agoop_to_this shouldn't use value profiling
mhahnenberg@apple.com [Thu, 26 Sep 2013 17:16:47 +0000 (17:16 +0000)]
op_to_this shouldn't use value profiling
https://bugs.webkit.org/show_bug.cgi?id=121920

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Currently it's the only opcode that uses m_singletonValue, which is unnecessary. Our current plan is
to remove m_singletonValue so that GenGC can have a simpler story for handling CodeBlocks/FunctionExecutables
during nursery collections.

This patch adds an inline cache for the Structure of to_this so it no longer depends on the ValueProfile's
m_singletonValue. Since nobody uses m_singletonValue now, this patch also removes m_singletonValue from
ValueProfile.

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::finalizeUnconditionally):
(JSC::CodeBlock::stronglyVisitStrongReferences):
(JSC::CodeBlock::updateAllPredictionsAndCountLiveness):
(JSC::CodeBlock::updateAllValueProfilePredictions):
(JSC::CodeBlock::updateAllPredictions):
(JSC::CodeBlock::shouldOptimizeNow):
* bytecode/CodeBlock.h:
(JSC::CodeBlock::updateAllValueProfilePredictions):
(JSC::CodeBlock::updateAllPredictions):
* bytecode/LazyOperandValueProfile.cpp:
(JSC::CompressedLazyOperandValueProfileHolder::computeUpdatedPredictions):
* bytecode/LazyOperandValueProfile.h:
* bytecode/ValueProfile.h:
(JSC::ValueProfileBase::ValueProfileBase):
(JSC::ValueProfileBase::briefDescription):
(JSC::ValueProfileBase::dump):
(JSC::ValueProfileBase::computeUpdatedPrediction):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::parseBlock):
* jit/JITOpcodes.cpp:
(JSC::JIT::emit_op_to_this):
(JSC::JIT::emitSlow_op_to_this):
* jit/JITOpcodes32_64.cpp:
(JSC::JIT::emit_op_to_this):
(JSC::JIT::emitSlow_op_to_this):
* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:
* runtime/CommonSlowPaths.cpp:
(JSC::SLOW_PATH_DECL):

LayoutTests:

Updated a couple tests that waited for two DFG compiles, but with this patch we
don't do two compiles any more, so we don't want to wait forever.

* js/script-tests/dfg-convert-this-polymorphic-object-then-exit-on-other.js:
* js/script-tests/dfg-convert-this-polymorphic-object-then-exit-on-string.js:

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

7 years agoRebaseline some tests after IndexedDB was enabled.
akling@apple.com [Thu, 26 Sep 2013 17:06:30 +0000 (17:06 +0000)]
Rebaseline some tests after IndexedDB was enabled.

* js/dom/global-constructors-attributes-dedicated-worker-expected.txt:
* js/dom/global-constructors-attributes-shared-worker-expected.txt:

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

7 years agoInset box-shadows fail to round around corners when border-radius is set in vh/vw...
commit-queue@webkit.org [Thu, 26 Sep 2013 16:57:42 +0000 (16:57 +0000)]
Inset box-shadows fail to round around corners when border-radius is set in vh/vw units.
https://bugs.webkit.org/show_bug.cgi?id=119187

Patch by Gurpreet Kaur <k.gurpreet@samsung.com> on 2013-09-26
Reviewed by Darin Adler.

Source/WebCore:

Border-radius properties were not applied incase its values
were given in vh, vw, vmax, vmin units.

Tests: fast/css/border-radius-inset-box-shadow-viewportlength.html
       fast/css/border-radius-viewport-height.html
       fast/css/border-radius-viewport-vmax.html
       fast/css/border-radius-viewport-vmin.html

* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyBorderRadius::applyValue):
(WebCore::ApplyPropertyComputeLength::applyValue):
* css/StyleResolver.h:
Calculating the border-radius values which has been specified
in viewport units.The vh/vw units are calcultated as percent of
viewport height and viewport width respectively. 1vmax: 1vw or 1vh,
whatever is largest.1vmin: 1vw or 1vh, whatever is smallest.

LayoutTests:

* fast/css/border-radius-inset-box-shadow-viewportlength-expected-mismatch.html: Added.
* fast/css/border-radius-inset-box-shadow-viewportlength.html: Added.
* fast/css/border-radius-viewport-height-expected-mismatch.html: Added.
* fast/css/border-radius-viewport-height.html: Added.
* fast/css/border-radius-viewport-vmax-expected-mismatch.html: Added.
* fast/css/border-radius-viewport-vmax.html: Added.
* fast/css/border-radius-viewport-vmin-expected-mismatch.html: Added.
* fast/css/border-radius-viewport-vmin.html: Added.
Added new tests for verifying that box-shadow and border-radius properties
are applied when its values are viewport units.

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

7 years agoFix ordered comparison warnings in BitmapImage::drawPattern
seokju@webkit.org [Thu, 26 Sep 2013 16:53:57 +0000 (16:53 +0000)]
Fix ordered comparison warnings in BitmapImage::drawPattern
https://bugs.webkit.org/show_bug.cgi?id=121945

Reviewed by Darin Adler.

No new tests, no behavior change.

* platform/graphics/BitmapImage.cpp:
(WebCore::BitmapImage::drawPattern):

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

7 years agoImplement prefixed-destructuring assignment
oliver@apple.com [Thu, 26 Sep 2013 16:52:32 +0000 (16:52 +0000)]
Implement prefixed-destructuring assignment
https://bugs.webkit.org/show_bug.cgi?id=121930

Reviewed by Mark Hahnenberg.

Source/JavaScriptCore:

This is mostly simple - the semantics of deconstruction are already
present in the language, so most of the complexity (if you call it
that) is addition of new AST nodes, and parsing the syntax.

In order to get correct semantics for the parameter lists, FunctionParameters
now needs to store refcounted references to the parameter patterns.
There's also a little work to ensure that variable creation and assignment
occurs in the correct order while the BytecodeGenerator is being constructed.

* bytecode/UnlinkedCodeBlock.cpp:
(JSC::UnlinkedFunctionExecutable::paramString):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::emitExpressionInfo):
* bytecompiler/NodesCodegen.cpp:
(JSC::ForInNode::emitBytecode):
(JSC::DeconstructingAssignmentNode::emitBytecode):
(JSC::DeconstructionPatternNode::~DeconstructionPatternNode):
(JSC::ArrayPatternNode::emitBytecode):
(JSC::ArrayPatternNode::emitDirectBinding):
(JSC::ArrayPatternNode::toString):
(JSC::ArrayPatternNode::collectBoundIdentifiers):
(JSC::ObjectPatternNode::toString):
(JSC::ObjectPatternNode::emitBytecode):
(JSC::ObjectPatternNode::collectBoundIdentifiers):
(JSC::BindingNode::emitBytecode):
(JSC::BindingNode::toString):
(JSC::BindingNode::collectBoundIdentifiers):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::createFormalParameterList):
(JSC::ASTBuilder::createForInLoop):
(JSC::ASTBuilder::addVar):
(JSC::ASTBuilder::createDeconstructingAssignment):
(JSC::ASTBuilder::createArrayPattern):
(JSC::ASTBuilder::appendArrayPatternSkipEntry):
(JSC::ASTBuilder::appendArrayPatternEntry):
(JSC::ASTBuilder::createObjectPattern):
(JSC::ASTBuilder::appendObjectPatternEntry):
(JSC::ASTBuilder::createBindingLocation):
* parser/NodeConstructors.h:
(JSC::CommaNode::CommaNode):
(JSC::ParameterNode::ParameterNode):
(JSC::ForInNode::ForInNode):
(JSC::DeconstructionPatternNode::DeconstructionPatternNode):
(JSC::ArrayPatternNode::ArrayPatternNode):
(JSC::ArrayPatternNode::create):
(JSC::ObjectPatternNode::ObjectPatternNode):
(JSC::ObjectPatternNode::create):
(JSC::BindingNode::create):
(JSC::BindingNode::BindingNode):
(JSC::DeconstructingAssignmentNode::DeconstructingAssignmentNode):
* parser/Nodes.cpp:
(JSC::FunctionParameters::create):
(JSC::FunctionParameters::FunctionParameters):
(JSC::FunctionParameters::~FunctionParameters):
* parser/Nodes.h:
(JSC::ExpressionNode::isDeconstructionNode):
(JSC::ArrayNode::elements):
(JSC::CommaNode::append):
(JSC::ParameterNode::pattern):
(JSC::FunctionParameters::at):
(JSC::FunctionParameters::patterns):
(JSC::DeconstructionPatternNode::isBindingNode):
(JSC::DeconstructionPatternNode::emitDirectBinding):
(JSC::ArrayPatternNode::appendIndex):
(JSC::ObjectPatternNode::appendEntry):
(JSC::ObjectPatternNode::Entry::Entry):
(JSC::BindingNode::boundProperty):
(JSC::BindingNode::isBindingNode):
(JSC::DeconstructingAssignmentNode::bindings):
(JSC::DeconstructingAssignmentNode::isLocation):
(JSC::DeconstructingAssignmentNode::isDeconstructionNode):
* parser/Parser.cpp:
(JSC::::Parser):
(JSC::::parseVarDeclaration):
(JSC::::parseVarDeclarationList):
(JSC::::createBindingPattern):
(JSC::::parseDeconstructionPattern):
(JSC::::parseForStatement):
(JSC::::parseFormalParameters):
(JSC::::parseAssignmentExpression):
* parser/Parser.h:
(JSC::Scope::declareBoundParameter):
(JSC::Parser::declareBoundParameter):
* parser/SyntaxChecker.h:
(JSC::SyntaxChecker::createFormalParameterList):
(JSC::SyntaxChecker::addVar):
(JSC::SyntaxChecker::operatorStackPop):
* runtime/JSONObject.cpp:
(JSC::escapeStringToBuilder):
* runtime/JSONObject.h:

LayoutTests:

Add enw tests, and update old ones.

* js/destructuring-assignment-expected.txt: Added.
* js/destructuring-assignment.html: Added.
* js/mozilla/strict/13.1-expected.txt:
* js/mozilla/strict/regress-532254-expected.txt:
* js/mozilla/strict/script-tests/13.1.js:
* js/regress/destructuring-arguments-expected.txt: Added.
* js/regress/destructuring-arguments-length-expected.txt: Added.
* js/regress/destructuring-arguments-length.html: Added.
* js/regress/destructuring-arguments.html: Added.
* js/regress/destructuring-swap-expected.txt: Added.
* js/regress/destructuring-swap.html: Added.
* js/regress/script-tests/destructuring-arguments-length.js: Added.
(foo):
* js/regress/script-tests/destructuring-arguments.js: Added.
(foo):
* js/regress/script-tests/destructuring-swap.js: Added.
(foo):
* js/script-tests/destructuring-assignment.js: Added.
(testDestructuring):
(testDeconstructArgs):
(testDeconstructArgLength):

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

7 years agoUnreviewed GTK gardening.
berto@igalia.com [Thu, 26 Sep 2013 16:46:26 +0000 (16:46 +0000)]
Unreviewed GTK gardening.

Unskip media/context-menu-actions.html which is passing now.

* platform/gtk-wk2/TestExpectations:

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

7 years ago[GTK] Tons of warnings caused by using FORTIFY_SOURCE in an unoptimized build
kov@webkit.org [Thu, 26 Sep 2013 16:36:22 +0000 (16:36 +0000)]
[GTK] Tons of warnings caused by using FORTIFY_SOURCE in an unoptimized build
https://bugs.webkit.org/show_bug.cgi?id=121836

Patch by Gustavo Noronha Silva <gustavo.noronha@collabora.com> on 2013-09-26
Reviewed by Martin Robinson.

* Source/autotools/SetupCompilerFlags.m4: only consider enabling FORTIFY_SOURCE if optimizations have
been enabled, since they are required for FORTIFY_SOURCE to work, and enabling FORTIFY_SOURCE unconditionally
generates warnings in newer glibc.

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

7 years agoUnreviewed, rolling out r156457.
commit-queue@webkit.org [Thu, 26 Sep 2013 16:18:32 +0000 (16:18 +0000)]
Unreviewed, rolling out r156457.
http://trac.webkit.org/changeset/156457
https://bugs.webkit.org/show_bug.cgi?id=121960

Broke webkitpy tests. (Requested by kling on #webkit).

* Scripts/webkitpy/port/xvfbdriver.py:
(XvfbDriver._start):

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

7 years ago[GTK][WK2] Logging of accessibility events is not disabled between tests
mario@webkit.org [Thu, 26 Sep 2013 15:16:10 +0000 (15:16 +0000)]
[GTK][WK2] Logging of accessibility events is not disabled between tests
https://bugs.webkit.org/show_bug.cgi?id=121957

Unreviewed gardening again. Now moving the expected flakiness to
the WebKit2GTK+ port, where it actually belongs to.

* platform/gtk-wk2/TestExpectations: Added expectations.
* platform/gtk/TestExpectations: Removed expectations.

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

7 years ago[GTK] Logging of accessibility events is not disabled between tests
mario@webkit.org [Thu, 26 Sep 2013 15:02:20 +0000 (15:02 +0000)]
[GTK] Logging of accessibility events is not disabled between tests
https://bugs.webkit.org/show_bug.cgi?id=121957

Unreviewed gardening. Marking accessibility tests as flaky while
an issue with the logging of accessibility events is investigated.

* platform/gtk/TestExpectations: Added flaky expectations.

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

7 years agoRemove empty JSFooCustom.cpp files.
akling@apple.com [Thu, 26 Sep 2013 14:24:59 +0000 (14:24 +0000)]
Remove empty JSFooCustom.cpp files.
<https://webkit.org/b/121955>

Reviewed by Anders Carlsson.

There's no sense in slowing down build times with empty files that
still include a bunch of headers.

* bindings/js/JSAudioBufferCustom.cpp: Removed.
* bindings/js/JSCSSFontFaceRuleCustom.cpp: Removed.
* bindings/js/JSCSSImportRuleCustom.cpp: Removed.
* bindings/js/JSCSSMediaRuleCustom.cpp: Removed.
* bindings/js/JSCSSPageRuleCustom.cpp: Removed.
* bindings/js/JSCSSStyleRuleCustom.cpp: Removed.
* bindings/js/JSDOMImplementationCustom.cpp: Removed.
* bindings/js/JSDOMTokenListCustom.cpp: Removed.
* bindings/js/JSHTMLStyleElementCustom.cpp: Removed.
* bindings/js/JSMediaListCustom.cpp: Removed.
* bindings/js/JSProcessingInstructionCustom.cpp: Removed.
* bindings/js/JSWebKitCSSKeyframeRuleCustom.cpp: Removed.
* bindings/js/JSWebKitCSSKeyframesRuleCustom.cpp: Removed.
* bindings/js/JSXMLHttpRequestUploadCustom.cpp: Removed.

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

7 years agoXvfbDriver should set up Xvfb instances providing screens of 8-bit depth
zandobersek@gmail.com [Thu, 26 Sep 2013 13:30:42 +0000 (13:30 +0000)]
XvfbDriver should set up Xvfb instances providing screens of 8-bit depth
https://bugs.webkit.org/show_bug.cgi?id=121951

Reviewed by Carlos Garcia Campos.

Screens with 24-bit depth are causing problems as it doesn't seem to be possible to fall back to
software rendering successfully on the GTK 64-bit release builder, resulting in crashes in almost
500 layout tests that trigger accelerated compositing to be used.

* Scripts/webkitpy/port/xvfbdriver.py:
(XvfbDriver._start):

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

7 years ago[Qt] Remove PassTraits.h from WTF.pro.
commit-queue@webkit.org [Thu, 26 Sep 2013 11:50:20 +0000 (11:50 +0000)]
[Qt] Remove PassTraits.h from WTF.pro.
https://bugs.webkit.org/show_bug.cgi?id=121946

Patch by Julien Brianceau <jbriance@cisco.com> on 2013-09-26
Reviewed by Andreas Kling.

* WTF.pro: Remove PassTraits.h as this file disappeared in r156298.

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

7 years agoREGRESSION(r144831-r144846):Crashes in accessibility/aria-hidden-with-elements.html...
mario@webkit.org [Thu, 26 Sep 2013 11:18:29 +0000 (11:18 +0000)]
REGRESSION(r144831-r144846):Crashes in accessibility/aria-hidden-with-elements.html, accessibility/table-with-hidden-head-section.html
https://bugs.webkit.org/show_bug.cgi?id=112152

Unreviewed GTK gardening. Removed crash expectations now passing.

* platform/gtk/TestExpectations: Removed crashing expectations
that are now passing after r156141-r156209.

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

7 years agoUnreviewed GTK gardening. Remove failure expectation for test passing after r156209.
mario@webkit.org [Thu, 26 Sep 2013 11:13:40 +0000 (11:13 +0000)]
Unreviewed GTK gardening. Remove failure expectation for test passing after r156209.

* platform/gtk-wk2/TestExpectations: Removed failure expectation.

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

7 years ago[EFL] Remove inappropriate expectations for tests that are now passing on EFL port
commit-queue@webkit.org [Thu, 26 Sep 2013 08:58:41 +0000 (08:58 +0000)]
[EFL] Remove inappropriate expectations for tests that are now passing on EFL port
https://bugs.webkit.org/show_bug.cgi?id=121897

Unreviewed EFL gardening.

Patch by Krzysztof Wolanski <k.wolanski@samsung.com> on 2013-09-26

* platform/efl-wk2/TestExpectations:
* platform/efl/TestExpectations:

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

7 years ago[EFL] Add baselines for editing/selection/paragraph-granularity.html
commit-queue@webkit.org [Thu, 26 Sep 2013 08:41:12 +0000 (08:41 +0000)]
[EFL] Add baselines for editing/selection/paragraph-granularity.html
https://bugs.webkit.org/show_bug.cgi?id=121842

Unreviewed EFL gardening.

Patch by Krzysztof Wolanski <k.wolanski@samsung.com> on 2013-09-26

* platform/efl/TestExpectations: Removing the corresponding entry.
* platform/efl/editing/selection/paragraph-granularity-expected.txt: Added.

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

7 years ago[CSS Regions] The layers from the flow thread should be collected under the regions...
commit-queue@webkit.org [Thu, 26 Sep 2013 08:20:57 +0000 (08:20 +0000)]
[CSS Regions] The layers from the flow thread should be collected under the regions' layers.
https://bugs.webkit.org/show_bug.cgi?id=120457

Patch by Mihai Maerean <mmaerean@adobe.com> on 2013-09-26
Reviewed by David Hyatt.

Source/WebCore:

This patch is based on the work of Alexandru Chiculita at https://bugs.webkit.org/attachment.cgi?id=203872&action=review

The composited layers inside the named flow threads are collected as part of the regions.
When a region displays a layer that needs accelerated compositing we activate the accelerated compositing for
that region too (inside RenderFlowThread::updateAllLayerToRegionMappings).

Tests: fast/regions/layers/accelerated-compositing/crash-transform-inside-region.html
       fast/regions/layers/accelerated-compositing/floated-region-with-transformed-child.html
       fast/regions/layers/accelerated-compositing/move-layer-from-one-region-to-another.html
       fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding.html
       fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-for-video.html
       fast/regions/layers/accelerated-compositing/region-as-layer-in-another-flowthread.html
       fast/regions/layers/accelerated-compositing/transform-transparent-positioned-video-inside-region.html
       fast/regions/layers/accelerated-compositing/transformed-layer-inside-transformed-layer.html
       fast/regions/layers/accelerated-compositing/z-index.html: Added.
       fast/regions/layers/accelerated-compositing/z-index-update.html: Added.

* rendering/FlowThreadController.cpp:
(WebCore::FlowThreadController::updateRenderFlowThreadLayersIfNeeded):
* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::layout): When the layout of the flow thread is over (including the 2 phase layout),
we update all the mappings between the layers inside the flow thread and the regions where those layers will be
painted.
(WebCore::RenderFlowThread::hasCompositingRegionDescendant): Whether any of the regions has a compositing descendant.
(WebCore::RenderFlowThread::getLayerListForRegion):
(WebCore::RenderFlowThread::regionForCompositedLayer):
(WebCore::RenderFlowThread::cachedRegionForCompositedLayer):
(WebCore::RenderFlowThread::updateLayerToRegionMappings): Triggers an update of the layers if a layer has moved
from a region to another since the last update.
(WebCore::RenderFlowThread::updateAllLayerToRegionMappings):
* rendering/RenderFlowThread.h:
* rendering/RenderGeometryMap.cpp:
(WebCore::RenderGeometryMap::pushRenderFlowThread):
* rendering/RenderGeometryMap.h:
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateLayerBounds): The RenderNamedFlowThread is ignored when we calculate the bounds
of the RenderView.
* rendering/RenderLayer.h:
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::shouldClipCompositedBounds): Not if it's inside an out of flow Flow Thread.
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): Now adjusts the ancestorCompositingBounds for the FlowThread.
(WebCore::enclosingFlowThreadAncestor):
(WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread): Make sure that the region propagates
its borders, paddings, outlines or box-shadows to layers inside it.
* rendering/RenderLayerBacking.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::computeCompositingRequirements): Now calls computeRegionCompositingRequirements.
(WebCore::RenderLayerCompositor::computeRegionCompositingRequirements):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTree): Do not iterate the RenderFlowThread directly. We
are going to collect composited layers as part of regions.
(WebCore::RenderLayerCompositor::rebuildRegionCompositingLayerTree):
(WebCore::RenderLayerCompositor::canBeComposited): CSS Regions flow threads do not need to be composited as we
use composited RenderRegions to render the background of the RenderFlowThread.
(WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason): If it's a region.
* rendering/RenderLayerCompositor.h:
* rendering/RenderMultiColumnSet.cpp:
(WebCore::RenderMultiColumnSet::adjustRegionBoundsFromFlowThreadPortionRect):
* rendering/RenderMultiColumnSet.h:
* rendering/RenderElement.cpp:
(WebCore::RenderObject::propagateStyleToAnonymousChildren): Not for RenderFlowThreads, as they are updated
through the RenderView::styleDidChange function.
* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::setRequiresLayerForCompositing):
(WebCore::RenderRegion::adjustRegionBoundsFromFlowThreadPortionRect):
* rendering/RenderRegion.h:
(WebCore::toRenderRegion):
* rendering/RenderRegionSet.h:
(WebCore::RenderRegionSet::requiresLayer): Never.
* rendering/RenderTreeAsText.cpp:
(WebCore::writeLayers):

LayoutTests:

* fast/regions/layers/accelerated-compositing/crash-transform-inside-region.html: Added.
* fast/regions/layers/accelerated-compositing/crash-transform-inside-region-expected.html: Added.
* fast/regions/layers/accelerated-compositing/floated-region-with-transformed-child.html: Added.
* fast/regions/layers/accelerated-compositing/floated-region-with-transformed-child-expected.html: Added.
* fast/regions/layers/accelerated-compositing/move-layer-from-one-region-to-another.html: Added.
* fast/regions/layers/accelerated-compositing/move-layer-from-one-region-to-another-expected.html: Added.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding.html: Added.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-expected.html: Added.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-for-video.html: Added.
* fast/regions/layers/accelerated-compositing/propagate-region-box-shadow-border-padding-for-video-expected.html: Added.
* fast/regions/layers/accelerated-compositing/region-as-layer-in-another-flowthread.html: Added.
* fast/regions/layers/accelerated-compositing/region-as-layer-in-another-flowthread-expected.html: Added.
* fast/regions/layers/accelerated-compositing/transformed-layer-inside-transformed-layer.html: Added.
* fast/regions/layers/accelerated-compositing/transformed-layer-inside-transformed-layer-expected.html: Added.
* fast/regions/layers/accelerated-compositing/transform-transparent-positioned-video-inside-region.html: Added.
* fast/regions/layers/accelerated-compositing/transform-transparent-positioned-video-inside-region-expected.html: Added.
* fast/regions/layers/accelerated-compositing/z-index.html: Added.
* fast/regions/layers/accelerated-compositing/z-index-expected.html: Added.
* fast/regions/layers/accelerated-compositing/z-index-update-expected.html: Added.
* fast/regions/layers/accelerated-compositing/z-index-update.html: Added.

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

7 years ago[CSSRegions] Unable to collect html element in a named flow
mihnea@adobe.com [Thu, 26 Sep 2013 07:58:23 +0000 (07:58 +0000)]
[CSSRegions] Unable to collect html element in a named flow
https://bugs.webkit.org/show_bug.cgi?id=121878

Reviewed by Antti Koivisto.

Source/WebCore:

Tests: fast/regions/collect-html-in-named-flow.html
       fast/regions/iframe-html-collected.html

It should be possible to collect the html element in a named flow.
However, before we check whether adding a child is not restricted
by its original parent, we have to make sure that the original parent
is an element to safely perform the check.

* rendering/RenderNamedFlowThread.cpp:
(WebCore::RenderNamedFlowThread::isChildAllowed):

LayoutTests:

Use an iframe with a html element collected in a named flow
to test that is does not crash or assert.

* fast/regions/collect-html-in-named-flow-expected.txt: Added.
* fast/regions/collect-html-in-named-flow.html: Added.
* fast/regions/iframe-html-collected-expected.txt: Added.
* fast/regions/iframe-html-collected.html: Added.

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

7 years ago8 bytes memory leaks in WebProcessMainQt.cpp when proxy is initialized
commit-queue@webkit.org [Thu, 26 Sep 2013 06:33:18 +0000 (06:33 +0000)]
8 bytes memory leaks in WebProcessMainQt.cpp when proxy is initialized
https://bugs.webkit.org/show_bug.cgi?id=118515

Patch by Minju Kim <pmuarteo@gmail.com> on 2013-09-25
Reviewed by Christophe Dumez.

* WebProcess/qt/WebProcessMainQt.cpp:
(WebKit::initializeProxy): Handled EnvHttpProxyFactory by using OwnPtr
to avoid memory leak when it isn't handled by NetworkProxyFactory

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

7 years agoUnreviewed, blind attempt at a build fix.
beidson@apple.com [Thu, 26 Sep 2013 04:50:12 +0000 (04:50 +0000)]
Unreviewed, blind attempt at a build fix.

* inspector/InspectorIndexedDBAgent.cpp: Don’t include the keyPathFromIDBKeyPath method for
  PLATFORM(MAC) as it is unused.

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

7 years agoEnable the IndexedDB build on Mac, but leave the feature non-functional
beidson@apple.com [Thu, 26 Sep 2013 04:15:56 +0000 (04:15 +0000)]
Enable the IndexedDB build on Mac, but leave the feature non-functional
https://bugs.webkit.org/show_bug.cgi?id=121918

Reviewed by Alexey Proskuryakov.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

* Configurations/FeatureDefines.xcconfig:

(WebCore::IDBFactory::create): If the IDBFactoryBackend is null (which it is for on-levelDB platforms),
  don't create an IDBFactory. This hides the feature from javascript even though upport code is in the build.

* inspector/InspectorIndexedDBAgent.cpp: Empty out DatabaseLoader::execute on Mac until the inspector
  build gurus can figure out a 32bit-vs-64bit issue that there is no obvious solution for.

* WebCore.xcodeproj/project.pbxproj: Remove the Modules/indexedDB/leveldb directory now that Mac has no
  further use for it.

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

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

7 years agoUnreviewed build fix for EFL port.
ryuan.choi@samsung.com [Thu, 26 Sep 2013 03:54:43 +0000 (03:54 +0000)]
Unreviewed build fix for EFL port.

IDBCursorBackendImpl and IDBDatabaseBackendImpl are renamed after r156406.

* Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.h:
* Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
(WebCore::IDBTransactionBackendLevelDB::create):
(WebCore::IDBTransactionBackendLevelDB::IDBTransactionBackendLevelDB):
(WebCore::IDBTransactionBackendLevelDB::registerOpenCursor):
(WebCore::IDBTransactionBackendLevelDB::unregisterOpenCursor):
(WebCore::IDBTransactionBackendLevelDB::closeOpenCursors):
* Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
(WebCore::IDBTransactionBackendLevelDB::database):

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

7 years agofast/css/font-face-data-uri.html is failing
ap@apple.com [Thu, 26 Sep 2013 03:51:32 +0000 (03:51 +0000)]
fast/css/font-face-data-uri.html is failing
https://bugs.webkit.org/show_bug.cgi?id=82744

Reviewed by Darin Adler.

This test used to wait for one font to load, but not for another, which made no sense.

* fast/css/font-face-data-uri.html: Wait for both fonts. Increased the number of tries,
it's not that long. Use an async test idiom that doesn't conflict with js-test-post.js.

* fast/css/font-face-data-uri-expected.txt: Updated the results for proper async
test usage.

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

7 years agoDo not reenter Document from its destructor
benjamin@webkit.org [Thu, 26 Sep 2013 02:30:32 +0000 (02:30 +0000)]
Do not reenter Document from its destructor
https://bugs.webkit.org/show_bug.cgi?id=121933

Reviewed by Darin Adler.

Following r156422, there are cases where we would reenter Document
during its destruction.

The flow was the following:
-Document's destructor is executed.
-DocumentStyleSheetCollection being part of Document, its destructor
 is executed.
-DocumentStyleSheetCollection's destructor detach the owner node of all
 its stylesheets avoid keeping stale references to a dead Document.
-CSSStyleSheet::clearOwnerNode() would fetch the dying document
 and invoke Document::styleResolverChanged().
This would not fail because the document is detached and Document::styleResolverChanged()
would fail early. This is complicated and error prone so this patch attempt to clear
the process a bit.

With the patch, Document detach all the stylesheets early in the destruction.
Clearing the stylesheet is also changed to avoid re-entering the document.

* css/CSSStyleSheet.h:
* dom/Document.cpp:
(WebCore::Document::~Document):
* dom/DocumentStyleSheetCollection.cpp:
(WebCore::DocumentStyleSheetCollection::detachFromDocument):
* dom/DocumentStyleSheetCollection.h:

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

7 years agoFix compilation with new MSVC compiler for Windows CE
paroga@webkit.org [Thu, 26 Sep 2013 02:03:45 +0000 (02:03 +0000)]
Fix compilation with new MSVC compiler for Windows CE
https://bugs.webkit.org/show_bug.cgi?id=121914

Reviewed by Darin Adler.

Remove code to support older Windows CE versions, since those old
versions do not support C+11, which is required in the meantime.

* wtf/Atomics.h:
* wtf/Platform.h:

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

7 years agohtmlediting.cpp: unnecessary local variable cleanup
commit-queue@webkit.org [Thu, 26 Sep 2013 02:01:01 +0000 (02:01 +0000)]
htmlediting.cpp: unnecessary local variable cleanup
https://bugs.webkit.org/show_bug.cgi?id=121903

Patch by Santosh Mahto <santosh.ma@samsung.com> on 2013-09-25
Reviewed by Darin Adler.

Code cleanup.

* editing/htmlediting.cpp:
(WebCore::lowestEditableAncestor):

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

7 years ago[Windows] Unreviewed Build fix.
roger_fong@apple.com [Thu, 26 Sep 2013 01:49:44 +0000 (01:49 +0000)]
[Windows] Unreviewed Build fix.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:

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

7 years agoRemoved check for Apple Application Support directory in WinCairo port.
commit-queue@webkit.org [Thu, 26 Sep 2013 01:05:12 +0000 (01:05 +0000)]
Removed check for Apple Application Support directory in WinCairo port.
https://bugs.webkit.org/show_bug.cgi?id=121869

Patch by Alex Christensen <achristensen@webkit.org> on 2013-09-25
Reviewed by Brent Fulgham.

* DumpRenderTree/DumpRenderTree.vcxproj/DumpRenderTree/DumpRenderTreeLauncher.vcxproj:
* DumpRenderTree/DumpRenderTree.vcxproj/ImageDiff/ImageDiffLauncher.vcxproj:
* WinLauncher/WinLauncher.vcxproj/WinLauncher.vcxproj:
Use DLLLauncherWinCairo.props for WinCairo ports.
* win/DLLLauncher/DLLLauncherMain.cpp:
(wWinMain):
Don't call modifyPath to check for AAS in the WinCairo port.
* win/DLLLauncher/DLLLauncherWinCairo.props: Added to define WIN_CAIRO.

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

7 years agoUnreviewed, rolling out r156432.
commit-queue@webkit.org [Thu, 26 Sep 2013 01:03:17 +0000 (01:03 +0000)]
Unreviewed, rolling out r156432.
http://trac.webkit.org/changeset/156432
https://bugs.webkit.org/show_bug.cgi?id=121932

some integer conversion things that need brady to fix
(Requested by thorton on #webkit).

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

* Configurations/FeatureDefines.xcconfig:
* Modules/indexeddb/IDBFactory.h:
(WebCore::IDBFactory::create):
* WebCore.xcodeproj/project.pbxproj:

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

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

7 years agoMove KeyValuePairTraits inside HashMap
andersca@apple.com [Thu, 26 Sep 2013 00:53:43 +0000 (00:53 +0000)]
Move KeyValuePairTraits inside HashMap
https://bugs.webkit.org/show_bug.cgi?id=121931

Reviewed by Sam Weinig.

Source/JavaScriptCore:

* tools/ProfileTreeNode.h:

Source/WTF:

Also rename the ValueType typedef to KeyValuePairType since it's always a key value pair.

* wtf/HashMap.h:
(WTF::HashMap::KeyValuePairTraits::isEmptyValue):
(WTF::HashMap::find):
(WTF::HashMap::contains):

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

7 years agoEnabled AssembleBuildLogs on WinCairo port.
commit-queue@webkit.org [Thu, 26 Sep 2013 00:48:27 +0000 (00:48 +0000)]
Enabled AssembleBuildLogs on WinCairo port.
https://bugs.webkit.org/show_bug.cgi?id=121923

Patch by Alex Christensen <achristensen@webkit.org> on 2013-09-25
Reviewed by Brent Fulgham.

Source/WebKit:

* WebKit.vcxproj/WebKit.sln:
Build AssembleBuildLogs in WinCairo port.

Tools:

* win/AssembleBuildLogs/AssembleBuildLogs.vcxproj:
Fixed reference to README, added WinCairo configurations.
* win/AssembleBuildLogs/AssembleBuildLogs.vcxproj.filters:
Fixed reference to README.
* win/AssembleBuildLogs/AssembleLogs.cmd:
Added ANGLE projects, skipped QTMovieWin for WinCairo, use PlatformArchitecture for Win64.
* win/AssembleBuildLogs/README: Fixed spelling.

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

7 years agoWin64 compile fix after r155226.
alex.christensen@flexsim.com [Thu, 26 Sep 2013 00:41:44 +0000 (00:41 +0000)]
Win64 compile fix after r155226.
https://bugs.webkit.org/show_bug.cgi?id=120969

Reviewed by Brent Fulgham.

* WebCore.vcxproj/WebCore.vcxproj:
Disable building StructuredExceptionHandlerSuppressor.cpp and makesafeseh.asm on Win64.

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

7 years agoFlaky Test: platform/mac/fonts/han-disunification.html
ap@apple.com [Wed, 25 Sep 2013 23:51:46 +0000 (23:51 +0000)]
Flaky Test: platform/mac/fonts/han-disunification.html
https://bugs.webkit.org/show_bug.cgi?id=114207

Reviewed by Anders Carlsson.

This test was affected by preceding tests changing font settings.

Save original font if it's changed, and restore it in Backup::restoreTo().

* WebCore.exp.in:
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::setStandardFontFamily):
(WebCore::InternalSettings::setSerifFontFamily):
(WebCore::InternalSettings::setSansSerifFontFamily):
(WebCore::InternalSettings::setFixedFontFamily):
(WebCore::InternalSettings::setCursiveFontFamily):
(WebCore::InternalSettings::setFantasyFontFamily):
(WebCore::InternalSettings::setPictographFontFamily):
* testing/InternalSettings.h:

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

7 years agoUn-indent HashMap.h.
andersca@apple.com [Wed, 25 Sep 2013 23:26:48 +0000 (23:26 +0000)]
Un-indent HashMap.h.

Rubber-stamped by Andreas Kling.

* wtf/HashMap.h:

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

7 years ago[Windows] Attempting to scroll from a non-scrollable layer results the main document...
roger_fong@apple.com [Wed, 25 Sep 2013 23:24:48 +0000 (23:24 +0000)]
[Windows] Attempting to scroll from a non-scrollable layer results the main document getting scrolled.
https://bugs.webkit.org/show_bug.cgi?id=121889.
<rdar://problem/15072441>

* WebView.cpp:
(WebView::gesture):
Call scrollByRecursively on the current RenderLayer's enclosingScrollableLayer to make sure that the method
doesn't bail early and end up just scrolling the main document instead of the next scrollable layer in the RenderLayer tree.

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