Make Vector::takeLast work with move-only types (and optimize for types where move is faster)
https://bugs.webkit.org/show_bug.cgi?id=131735

Reviewed by Alexey Proskuryakov.

Source/WTF:
* wtf/Vector.h:
(WTF::Vector::takeLast): Added a missing std::move. All the other take functions have it.

Tools:
* TestWebKitAPI/Tests/WTF/Vector.cpp: Added a test for Vector::takeLast with move only types.
Fixed invocations of EXPECT macros so the expected value is on the left, and the test result
is on the right. This can be confusing since our JavaScript test framework does it the opposite
way, but gtest works better this way.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167348 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[MSE] Seeks into buffered ranges will never complete.
https://bugs.webkit.org/show_bug.cgi?id=131717

Reviewed by Eric Carlson.

Source/WebCore:
Test: media/media-source/media-source-seek-complete.html

Run the SourceBuffer Monitoring step after initiating a seek.

* Modules/mediasource/SourceBuffer.cpp:
(WebCore::SourceBuffer::sourceBufferPrivateSeekToTime):

LayoutTests:
* media/media-source/media-source-seek-complete-expected.txt: Added.
* media/media-source/media-source-seek-complete.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167349 268f45cc-cd09-0410-ab3c-d52691b4dbfc
check-webkit-style doesn't check code style in .mm or .m files
https://bugs.webkit.org/show_bug.cgi?id=131708

Reviewed by Darin Adler.

* Scripts/webkitpy/style/checker.py:
* Scripts/webkitpy/style/checker_unittest.py:
(CheckerDispatcherDispatchTest.test_cpp_paths):
(CheckerDispatcherDispatchTest.test_text_paths):
Check .mm and .m files as C++.

* Scripts/webkitpy/style/checkers/cpp.py:
(check_spacing):
Add an override for our ordinary "missing spaces around =" for @synthesize,
which should look like "@synthesize propertyName=_varName;"

Add an override for "missing space before {" for blocks' "^{".

Don't follow the "extra space before [" rule for Objective-C, because
it breaks this rule in a multitude of ways because of method calls.

(check_braces):
Don't complain about { not being on the end of the previous line if
the previous line starts with "- (" or "+ (", which would indicate a
Objective-C method definition.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
ASSERTION FAILED: x2 >= x1 in WebCore::RenderObject::drawLineForBoxSide
https://bugs.webkit.org/show_bug.cgi?id=127835

Source/WebCore:
In some cases when a negative margin and a positive padding are applied
together to the right and/or left side of the box, the logical width of
the borders can be set to a negative value, making the assertion fire.
The fix checks if the width or height of the box is negative, and if so,
it will not display the borders and shadows of the box.

Patch by Martin Hodovan <mhodovan@inf.u-szeged.hu> on 2014-04-16
Reviewed by Darin Adler.

Test: fast/css/padding-margin-negative-border.html

* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintBorder):

LayoutTests:
Added test demonstrates four cases:
Test #1: Negative upper margin + positive upper padding
Test #2: Negative right margin + positive right padding (used to fail)
Test #3: Negative bottom margin + positive bottom padding
Test #4: Negative left margin + positive left padding (used to fail)

Patch by Martin Hodovan <mhodovan@inf.u-szeged.hu> on 2014-04-16
Reviewed by Darin Adler.

* fast/css/padding-margin-negative-border-expected.html: Added.
* fast/css/padding-margin-negative-border.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167351 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WinCairo][cURL] Build fix for WinCairo build with USE(CURL).
https://bugs.webkit.org/show_bug.cgi?id=131614

Patch by Daewoong Jang <daewoong.jang@navercorp.com> on 2014-04-16
Reviewed by Brent Fulgham.

Build fix, no new tests needed.

* platform/network/curl/CurlCacheEntry.cpp:
(WebCore::CurlCacheEntry::loadResponseHeaders):
* platform/network/curl/CurlCacheManager.cpp:
(WebCore::CurlCacheManager::loadIndex):
* platform/network/soup/ResourceError.h:
* platform/network/soup/SocketStreamHandle.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Make sure to skip the RenderMultiColumnFlowThread when resolving percentage heights inside columns against
containing blocks. The flow thread's auto height should not interfere if a fixed height is specified on
an ancestor.

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

Reviewed by Simon Fraser.


Source/WebCore: 
Added fast/multicol/percent-height.html.

* rendering/RenderBox.cpp:
(WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation):
Add an isInFlowRenderFlowThread check so that we skip those blocks and don't consider them at all
when resolving percentage heights.

LayoutTests: 
* fast/multicol/percent-height-expected.html: Added.
* fast/multicol/percent-height.html: Added.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167353 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, ARMv7 build fix after r167336.

* assembler/MacroAssemblerARMv7.h:
(JSC::MacroAssemblerARMv7::branchAdd32):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167354 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WTF should have an optional mbmalloc target so we can benchmark FastMalloc
https://bugs.webkit.org/show_bug.cgi?id=131662

Reviewed by Darin Adler.

* WTF.xcodeproj/project.pbxproj: Added the target.
* wtf/mbmalloc.cpp: Added. Implements the libmbmalloc.dylib API required
by MallocBench.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167355 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Convert the boolean param of Image::startAnimation() to an enum
https://bugs.webkit.org/show_bug.cgi?id=131742

Reviewed by Tim Horton.

Use an enum to make the code more readable.

* platform/graphics/BitmapImage.cpp:
(WebCore::BitmapImage::startAnimation):
* platform/graphics/BitmapImage.h:
* platform/graphics/Image.cpp:
(WebCore::Image::drawTiled):
* platform/graphics/Image.h:
(WebCore::Image::startAnimation):
* svg/graphics/SVGImage.cpp:
(WebCore::SVGImage::startAnimation):
* svg/graphics/SVGImage.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167356 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix some style checker complaints in PDFPlugin
https://bugs.webkit.org/show_bug.cgi?id=131706

Reviewed by Darin Adler.

* WebProcess/Plugins/PDF/PDFPlugin.mm:
(-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:]):
(-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:forParameter:]):
(-[WKPDFPluginAccessibilityObject accessibilityAttributeNames]):
(WebKit::PDFPlugin::attemptToUnlockPDF):
(WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):
(WebKit::PDFPlugin::isEditingCommandEnabled):
(WebKit::PDFPlugin::nextMatchForString):
(WebKit::PDFPlugin::handleWheelEvent):
(WebKit::PDFPlugin::liveData):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167357 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Accidentally included some style-checker-testing changes in the last commit.

* WebProcess/Plugins/PDF/PDFPlugin.mm:
(WebKit::PDFPlugin::attemptToUnlockPDF):
(WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167358 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Unreviewed GTK gardening.

Update list of skipped unit tests:

  Skip test: WebKit2Gtk/TestWebKitWebView:/webkit2/WebKitWebView/page-visibility

  Unskip tests: WebKit2/TestWebKit2:WebKit2.ResizeReversePaginatedWebView
  and WebKit2/TestWebKit2:WebKit2.ScrollPinningBehaviors

Patch by Carlos Alberto Lopez Perez <clopez@igalia.com> on 2014-04-16

* Scripts/run-gtk-tests:
(TestRunner):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167359 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Fix unused parameter warnings
https://bugs.webkit.org/show_bug.cgi?id=131721

Reviewed by Darin Adler.

Source/WebCore:
* bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
(WebCore::toJS): Remove unused 'exec' parameter.

Source/WebKit2:
* Scripts/webkit2/messages.py:
(generate_message_handler): Add UNUSED_PARAM() for a couple parameters which aren't always used.
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<LinearTimingFunction>::decode): Remove unused parameters.
* WebProcess/InjectedBundle/APIInjectedBundleFormClient.h:
(API::InjectedBundle::FormClient::textDidChangeInTextField): Same.
(API::InjectedBundle::FormClient::willSubmitForm): Same.
(API::InjectedBundle::FormClient::willSendSubmitEvent): Same.
* WebProcess/Network/NetworkProcessConnection.cpp:
(WebKit::NetworkProcessConnection::didReceiveSyncMessage): Same.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167360 268f45cc-cd09-0410-ab3c-d52691b4dbfc
AX: Accessing a table cell with an invalid column header crashes
https://bugs.webkit.org/show_bug.cgi?id=131719

Reviewed by Darin Adler.

If no tableCell is available as a column/row header, then do not continue processing.

Test: accessibility/table-missing-column-header-crash.html

* accessibility/AccessibilityTableCell.cpp:
(WebCore::AccessibilityTableCell::columnHeaders):
(WebCore::AccessibilityTableCell::rowHeaders):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167361 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[mac][wk2] REGRESSION (Tiled Drawing): fast/layers/no-clipping-overflow-hidden-added-after-transform.html fails with tiled drawing
https://bugs.webkit.org/show_bug.cgi?id=122238

Unreviewed. The test passes now.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167362 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Make Windows fail with a link error so I know what the new symbol is.

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

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167363 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WebKit] Cleanup the build from uninitialized variable in JavaScriptCore
https://bugs.webkit.org/show_bug.cgi?id=131728

Reviewed by Darin Adler.

* runtime/JSObject.cpp:
(JSC::JSObject::genericConvertDoubleToContiguous): Add a RELEASE_ASSERT on the
path we expect to never take. Also shut up confused compilers about uninitialized things.


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