Remove support for Chromium from build/update scripts
https://bugs.webkit.org/show_bug.cgi?id=115218

Patch by Seokju Kwon <seokju.kwon@gmail.com> on 2013-04-25
Reviewed by Darin Adler.

* Scripts/build-webkit:
(writeCongrats):
* Scripts/update-webkit:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149166 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Copy and paste can strip !important CSS rules due to a bug in mergeStyleFromRules
https://bugs.webkit.org/show_bug.cgi?id=115217

Reviewed by Darin Adler.

Source/WebCore:

The bug was caused by mergeStyleFromRules overriding "important" style rules with "unimportant" inline styles.
Fixed the bug by using addParsedProperty, which respects !important, in MutableStylePropertySet's
mergeAndOverrideOnConflict, which was only used in editing code. Now that we've fixed this function, we can use
it in ViewportStyleResolver::addViewportRule as well.

Test: editing/pasteboard/copy-paste-with-important-rules.html

* css/StylePropertySet.cpp:
(WebCore::MutableStylePropertySet::mergeAndOverrideOnConflict): Fixed to respect !important.
* css/ViewportStyleResolver.cpp:
(WebCore::ViewportStyleResolver::addViewportRule): Use mergeAndOverrideOnConflict now that the code is identical.

LayoutTests:

Added a regression test.

* editing/pasteboard/copy-paste-with-important-rules-expected.txt: Added.
* editing/pasteboard/copy-paste-with-important-rules.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149167 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Regions] Hit testing is broken for absolutely positioned regions that have overflow: hidden
https://bugs.webkit.org/show_bug.cgi?id=113874

Reviewed by David Hyatt.

Source/WebCore:

Test: fast/regions/hit-test-abspos-overflow-region.html

When a region is an out-of-flow positioned object with an overflow clip, we need
to make sure that hit testing works also for cases other than foreground (content)
hit testing. This patch moves the previous hit testing code, that delegated foreground
hit testing to the region's flow thread hit testing, into the hitTestContent method,
now that RenderRegion is RenderBlock based.

* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::hitTestContents):
* rendering/RenderRegion.h:
(RenderRegion):

LayoutTests:

Add test for hit-testing of border of an out-of-flow region with overflow: hidden.

* fast/regions/hit-test-abspos-overflow-region-expected.txt: Added.
* fast/regions/hit-test-abspos-overflow-region.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149168 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Plugin process broken due to a missing symbol
https://bugs.webkit.org/show_bug.cgi?id=114901

Reviewed by Gustavo Noronha Silva.

Work around the missing symbols in the WebKitPluginProcess by specifying the required libraries
multiple times in the program's LDADD list. Libtool fights fiercely to avoid duplicate static library
references among the linker arguments (even if using the --preserve-dup-deps flag) so the required libraries
are specified in various ways.

The unresolved symbols in object files are no longer ignored as this can lead to further trouble (for instance
this patch also adds a few missing source files to the list of WebKitPluginProcess sources). The Freetype and
gamepad dependencies' libraries are also added to the binary's LDADD list.

* GNUmakefile.am:
* GNUmakefile.list.am: Add a few missing files to the build.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149169 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add support for Web IDL partial interfaces to the bindings generator
https://bugs.webkit.org/show_bug.cgi?id=115228

Reviewed by Kentaro Hara.

Add support for Web IDL partial interfaces to the bindings generator:
http://dev.w3.org/2006/webapi/WebIDL/#dfn-partial-interface

Also drop support for the the WebKit-specific [Supplemental] extended
attribute and use partial interfaces instead in existing IDL files.

No new tests, no behavior change.

* Modules/battery/NavigatorBattery.idl:
* Modules/filesystem/DOMWindowFileSystem.idl:
* Modules/filesystem/DataTransferItemFileSystem.idl:
* Modules/filesystem/HTMLInputElementFileSystem.idl:
* Modules/filesystem/WorkerContextFileSystem.idl:
* Modules/gamepad/NavigatorGamepad.idl:
* Modules/geolocation/NavigatorGeolocation.idl:
* Modules/indexeddb/DOMWindowIndexedDatabase.idl:
* Modules/indexeddb/WorkerContextIndexedDatabase.idl:
* Modules/mediastream/DOMWindowMediaStream.idl:
* Modules/mediastream/NavigatorMediaStream.idl:
* Modules/navigatorcontentutils/NavigatorContentUtils.idl:
* Modules/networkinfo/NavigatorNetworkInfoConnection.idl:
* Modules/notifications/DOMWindowNotifications.idl:
* Modules/notifications/WorkerContextNotifications.idl:
* Modules/quota/DOMWindowQuota.idl:
* Modules/quota/NavigatorStorageQuota.idl:
* Modules/quota/WorkerNavigatorStorageQuota.idl:
* Modules/speech/DOMWindowSpeech.idl:
* Modules/speech/DOMWindowSpeechSynthesis.idl:
* Modules/vibration/NavigatorVibration.idl:
* Modules/webaudio/DOMWindowWebAudio.idl:
* Modules/webdatabase/DOMWindowWebDatabase.idl:
* Modules/webdatabase/WorkerContextWebDatabase.idl:
* Modules/websockets/DOMWindowWebSocket.idl:
* Modules/websockets/WorkerContextWebSocket.idl:
* bindings/scripts/IDLAttributes.txt:
* bindings/scripts/IDLParser.pm:
(parsePartialDefinition):
* bindings/scripts/generate-bindings.pl:
* bindings/scripts/preprocess-idls.pl:
(getPartialInterfaceNameFromIDLFile):
* bindings/scripts/test/TestSupplemental.idl:
* page/DOMWindowPagePopup.idl:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149170 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] REGRESSION(r149001): It made two fast/dom/DeviceMotion tests fail.
https://bugs.webkit.org/show_bug.cgi?id=115235

Reviewed by Kentaro Hara.

Update window-property.html test cases for DeviceMotion and DeviceOrientation.
The global constructors are no longer enumerable after r149001.

* fast/dom/DeviceMotion/script-tests/window-property.js:
* fast/dom/DeviceMotion/window-property-expected.txt:
* fast/dom/DeviceOrientation/script-tests/window-property.js:
* fast/dom/DeviceOrientation/window-property-expected.txt:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149171 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix SH4 build broken since r149159.
https://bugs.webkit.org/show_bug.cgi?id=115229

Add BranchTruncateType enum in SH4 port and handle it in branchTruncateDoubleToInt32.

Patch by Julien Brianceau <jbrianceau@nds.com> on 2013-04-26
Reviewed by Allan Sandfeld Jensen.

* assembler/MacroAssemblerSH4.h:
(JSC::MacroAssemblerSH4::branchTruncateDoubleToInt32):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149172 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Mouseenter and mouseleave events not supported
https://bugs.webkit.org/show_bug.cgi?id=18930

Reviewed by David Hyatt.

Source/WebCore:

Implements mouseenter and mouseleave events from W3C DOM Level 3 Events.
These event are already supported by all other major browsers.

To avoid performance regressions the new events are only dispatched when
there are event listeners for them.

Tests: fast/events/mouseenter-mouseleave-capture.html
       fast/events/mouseenter-mouseleave.html

* bindings/scripts/CodeGenerator.pm:
* dom/Document.cpp:
(WebCore::Document::prepareMouseEvent):
(WebCore::Document::updateHoverActiveState):
* dom/Document.h:
(Document):
* dom/Document.idl:
* dom/Element.h:
(Element):
* dom/Element.idl:
* dom/EventListenerMap.cpp:
(WebCore::EventListenerMap::containsCapturing):
* dom/EventListenerMap.h:
(EventListenerMap):
* dom/EventNames.h:
* dom/EventTarget.h:
(EventTarget):
(WebCore::EventTarget::hasCapturingEventListeners):
* dom/MouseEvent.cpp:
(WebCore::MouseEvent::create):
(WebCore::MouseEvent::toElement):
(WebCore::MouseEvent::fromElement):
* html/HTMLAttributeNames.in:
* html/HTMLElement.cpp:
(WebCore::HTMLElement::eventNameForAttributeName):
* page/DOMWindow.h:
(DOMWindow):
* page/DOMWindow.idl:
* svg/SVGElement.cpp:
(WebCore::SVGElement::parseAttribute):
* svg/SVGElementInstance.h:
(SVGElementInstance):
* svg/SVGElementInstance.idl:

LayoutTests:

To new tests that mouseenter and mouseleave works in both bubbling and capture phase.

* fast/events/mouseenter-mouseleave-capture-expected.txt: Added.
* fast/events/mouseenter-mouseleave-capture.html: Added.
* fast/events/mouseenter-mouseleave-expected.txt: Added.
* fast/events/mouseenter-mouseleave.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149173 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Add unit test cases for ewk_settings APIs
https://bugs.webkit.org/show_bug.cgi?id=114897

Patch by Jose Lejin PJ <jose.lejin@gmail.com> on 2013-04-26
Reviewed by Gyuyoung Kim.

Added unit tests for ewk_settings APIs.

* tests/test_ewk_setting.cpp:
(TEST_F):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149174 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Audio: Remove reduplicative addInput() in AnalyserNode.
<http://webkit.org/b/115244>

From Blink r149155 by <james.wei@intel.com>:

The parent class BasicInspectorNode already called addInput() and addOutput().
So it is reduplicative to call them in AnalyserNode.

* Modules/webaudio/AnalyserNode.cpp:
(WebCore::AnalyserNode::AnalyserNode):
* Modules/webaudio/AudioBasicInspectorNode.cpp:
(WebCore::AudioBasicInspectorNode::AudioBasicInspectorNode):
* Modules/webaudio/AudioBasicInspectorNode.h:
(AudioBasicInspectorNode):
* Modules/webaudio/MediaStreamAudioDestinationNode.cpp:
(WebCore::MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149175 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove the HeapGraphSerializer unit test
https://bugs.webkit.org/show_bug.cgi?id=115231

Reviewed by Andreas Kling.

Remove the HeapGraphSerializer unit test. The code it was testing was removed in r148921,
specifically the Source/WebCore/inspector/HeapGraphSerializer.(cpp|h) files.

* TestWebKitAPI/Tests/WebCore/HeapGraphSerializerTest.cpp: Removed.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149176 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Optimize function and interface object length computation in bindings generator
https://bugs.webkit.org/show_bug.cgi?id=115247

Reviewed by Kentaro Hara.

Introduce new GetFunctionLength() function that efficiently compute the length
of a function (i.e. its number of mandatory parameters).

We now call GetFunctionLength() instead of GenerateFunctionParametersCheck()
whenever we care only interested in the function length and not the actual
expression for checking the parameters. This is much more efficient as
GenerateFunctionParametersCheck() does a lot more processing than we need in
this case.

No new tests, no behavior change.

* bindings/scripts/CodeGeneratorJS.pm:
(GetFunctionLength):
(GenerateImplementation):
(GenerateConstructorHelperMethods):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149177 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove wxWebKit from WTF.
<http://webkit.org/b/115249>

Reviewed by Antti Koivisto.

* wscript: Removed.
* wtf/ArrayBufferView.h:
(ArrayBufferView):
* wtf/CurrentTime.cpp:
* wtf/DisallowCType.h:
* wtf/ExportMacros.h:
* wtf/FeatureDefines.h:
* wtf/Platform.h:
* wtf/text/WTFString.h:
(String):
* wtf/wx/MainThreadWx.cpp: Removed.
* wtf/wx/StringWx.cpp: Removed.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149178 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Unreviewed gardnering. Unskip passing test.

* platform/gtk/TestExpectations: Unskip http/tests/inspector/compiler-source-mapping-debug.html

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149179 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Clean up load interface in WebPage
https://bugs.webkit.org/show_bug.cgi?id=113267

Reviewed by Rob Buis.

Source/WebKit/blackberry:

Remove unused loadExtended(), combine load() and download() api in WebPage.
RIM Bug# 315535, internally reviewed by Joe Mason.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPage::load):
* Api/WebPage.h:

Tools:

Update DumpRenderTree with change of load() interface in WebPage.
RIM Bug# 315535, internally reviewed by Joe Mason.

* DumpRenderTree/blackberry/DumpRenderTree.cpp:
(BlackBerry::WebKit::DumpRenderTree::runTest):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149180 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Enable Web Audio layout tests on WK2, provide platform-specific expected output
https://bugs.webkit.org/show_bug.cgi?id=114513

Reviewed by Philippe Normand.

Unskip the Web Audio layout tests for GTK WK2 and generate platform-specific baselines for the tests.
The audio baselines are not audibly different from the generic baselines, but it can be expected that
different backends won't produce the same binary output.

The remaining failures are marked as such in the TestExpectations, each failure having the appropriate
bug handle covering the issue. The tests are still skipped for GTK WK1 as DumpRenderTree is still missing
infrastructure support for running these tests.

* platform/gtk-wk1/TestExpectations:
* platform/gtk/TestExpectations:
* platform/gtk/webaudio/audiobuffersource-loop-points-expected.wav: Added.
* platform/gtk/webaudio/audiobuffersource-playbackrate-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/aac/vbr-128kbps-44khz-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/mp3/128kbps-44khz-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/vorbis/vbr-128kbps-44khz-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/vorbis/vbr-70kbps-44khz-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/vorbis/vbr-96kbps-44khz-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/wav/24bit-22khz-resample-expected.wav: Added.
* platform/gtk/webaudio/codec-tests/wav/24bit-44khz-expected.wav: Added.
* platform/gtk/webaudio/oscillator-custom-expected.wav: Added.
* platform/gtk/webaudio/oscillator-sawtooth-expected.wav: Added.
* platform/gtk/webaudio/oscillator-sine-expected.wav: Added.
* platform/gtk/webaudio/oscillator-square-expected.wav: Added.
* platform/gtk/webaudio/oscillator-triangle-expected.wav: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149181 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Should check if it's cached resource before download
https://bugs.webkit.org/show_bug.cgi?id=115101

Reviewed by Rob Buis.

Since main resource maybe cached, if user want to save the resource, we first check
if it's cached. If yes, don't need to initiate a fresh load again, but get the
cached resource data out to save.

RIM bug# 324003, internally reviewed by Charles Wei.

* WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
(WebCore::FrameLoaderClientBlackBerry::convertMainResourceLoadToDownload):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149182 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION(r149165): It made many tests crash on 32 bit
https://bugs.webkit.org/show_bug.cgi?id=115227

Reviewed by Csaba Osztrogonác.

m_reservation is uninitialized when ENABLE(SUPER_REGION) is false.

* heap/SuperRegion.cpp:
(JSC::SuperRegion::~SuperRegion):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149183 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add move semantics to RefPtr
https://bugs.webkit.org/show_bug.cgi?id=115033

Reviewed by Anders Carlsson.

Add move constructors and move assignment operators to RefPtr when
COMPILER_SUPPORTS(CXX_RVALUE_REFERENCES).
This obviates unnecessary reffing/ureffing when RefPtr is created
or assigned from rvalue references.

* wtf/RefPtr.h:
(RefPtr):
(WTF::RefPtr::RefPtr):
(WTF::RefPtr::operator=):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149184 268f45cc-cd09-0410-ab3c-d52691b4dbfc
use-after-free removing a frame from its parent in a beforeload event of an OBJECT element
https://bugs.webkit.org/show_bug.cgi?id=113964

Source/WebCore:

Object elements have the tendecny to modify or even fully remove
the containing Document inside beforeload callback. While Document is removed,
RenderArena gets destroyed. Retained RenderWidgets fails to function with NULL arena.

Protect RendereArena from getting wiped out, when Document is removed
during FrameView::updateWidget().

Patch by Zalan Bujtas <zalan@apple.com> on 2013-04-26
Reviewed by Antti Koivisto.

Test: fast/frames/crash-remove-iframe-during-object-beforeload.html

* dom/Document.cpp:
(WebCore::Document::attach):
* dom/Document.h:
(Document):
* page/FrameView.cpp:
(WebCore::FrameView::updateWidgets):
* rendering/RenderArena.h:
(RenderArena):
(WebCore::RenderArena::create):

LayoutTests:

Patch by Zalan Bujtas <zalan@apple.com> on 2013-04-26
Reviewed by Antti Koivisto.

* fast/frames/crash-remove-iframe-during-object-beforeload-expected.txt: Added.
* fast/frames/crash-remove-iframe-during-object-beforeload.html: Added.
* fast/frames/resources/remove-this-during-object-beforeload.html: Added.

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