WebKit-https.git
5 years agoChange some images for a blog post and add 2x images.
timothy@apple.com [Thu, 23 Jul 2015 20:05:12 +0000 (20:05 +0000)]
Change some images for a blog post and add 2x images.

* blog-files/inspector-elements-tab-2x.png: Added.
* blog-files/inspector-elements-tab.png: Updated.
* blog-files/inspector-network-tab-2x.png: Added.
* blog-files/inspector-network-tab.png: Updated.
* blog-files/inspector-tab-bar-2x.png: Added.
* blog-files/inspector-tab-bar.png: Updated.

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

5 years agoSource/WebCore:
bfulgham@apple.com [Thu, 23 Jul 2015 19:30:02 +0000 (19:30 +0000)]
Source/WebCore:
[Win] Implement High DPI support features
https://bugs.webkit.org/show_bug.cgi?id=146335
<rdar://problem/21558269>

Reviewed by Alex Christensen.

* platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
(WebCore::PlatformCALayerWinInternal::drawTile): Don't translate the CGContext to the position
of the CACFLayerRef; the underlying context is already in the right position.
* platform/win/PlatformMouseEventWin.cpp: Update class to adjust mouse
event coordinates based on scaling factor.
(WebCore::deviceScaleFactor):
(WebCore::positionForEvent):
* platform/win/ScrollbarThemeWin.cpp:
(WebCore::scrollbarThicknessInPixels):
(WebCore::ScrollbarThemeWin::scrollbarThickness):
(WebCore::ScrollbarThemeWin::themeChanged):
* platform/win/WheelEventWin.cpp: Update class to adjust wheel event
coordinates based on scaling factor.
(WebCore::deviceScaleFactor):
(WebCore::positionForEvent):
(WebCore::globalPositionForEvent):
(WebCore::PlatformWheelEvent::PlatformWheelEvent):

Source/WebKit/win:
[Win] Implement High DPI support features
https://bugs.webkit.org/show_bug.cgi?id=146335
<rdar://problem/21558269>

Reviewed by Alex Christensen.

* WebCoreSupport/WebFrameLoaderClient.cpp:
(WebFrameLoaderClient::transitionToCommittedForNewPage): Size
page for current device scale factor.
* WebFrame.cpp:
(WebFrame::paintDocumentRectToContext): Account for device scale factor.
(WebFrame::paintScrollViewRectToContextAtPoint): Ditto.
* WebView.cpp:
(WebView::repaint): Adjust paint rect for device scale factor.
(WebView::scrollBackingStore): Adjust coordinates for scale factor.
(WebView::sizeChanged): Ditto.
(WebView::updateBackingStore): Ditto.
(WebView::paint): Ditto.
(WebView::paintIntoBackingStore): Ditto.
(WebView::handleContextMenuEvent): Ditto.
(WebView::gestureNotify): Ditto.
(WebView::gesture): Ditto.
(WebView::initializeToolTipWindow): Adjust max tool tip width
for device scale factor.
(WebView::selectionRect): Adjust coordinates for scale factor.
(WebView::elementAtPoint): Ditto.
(WebView::scrollOffset): Ditto.
(WebView::scrollBy): Ditto.
(WebView::visibleContentRect): Ditto.
(WebView::paintContents): Ditto.
* WebView.h:

Tools:
[Win] Implement proper High DPI support features
https://bugs.webkit.org/show_bug.cgi?id=146335
<rdar://problem/21558269>

Reviewed by Alex Christensen.

Update WinLauncher to take device scaling factor into account.

* WinLauncher/Common.cpp:
(resizeSubViews): Make sure toolbars and URL bar are properly sized and using
a valid font.
(computeFullDesktopFrame): Handle high DPI desktops.
(WndProc): Make comments more precise.
* WinLauncher/WinLauncher.cpp:
(WinLauncher::init): Determine device scale factor at launch.
(WinLauncher::updateDeviceScaleFactor): Added.
* WinLauncher/WinLauncher.h:
* WinLauncher/WinLauncherWebHost.h: Use C++11 initialization.
* WinLauncher/WinMain.cpp: Size interface based on scaling factor.
(wWinMain): Ditto.
* win/DLLLauncher/DLLLauncherMain.cpp:
(wWinMain): Tell Windows we understand high DPI.

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

5 years agoREGRESSION(r182236): Justified Arabic text does not expand
mmaxfield@apple.com [Thu, 23 Jul 2015 19:15:16 +0000 (19:15 +0000)]
REGRESSION(r182236): Justified Arabic text does not expand
https://bugs.webkit.org/show_bug.cgi?id=147217

Reviewed by Simon Fraser.

When I was writing r182236, I got confused between the levels of the string hierarchy in ComplexTextController.
I've added a comment in the header which should make it easier to get it right.

Test: fast/text/international/arabic-justify.html

* platform/graphics/mac/ComplexTextController.cpp:
(WebCore::ComplexTextController::adjustGlyphsAndAdvances):
* platform/graphics/mac/ComplexTextController.h:

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

5 years agoRemove some files that should have been removed with WebKit2 Windows
timothy_horton@apple.com [Thu, 23 Jul 2015 18:34:51 +0000 (18:34 +0000)]
Remove some files that should have been removed with WebKit2 Windows
https://bugs.webkit.org/show_bug.cgi?id=147223

Reviewed by Csaba Osztrogonác.

* Shared/API/c/cf/WKURLRequestCF.cpp: Removed.
* Shared/API/c/cf/WKURLRequestCF.h: Removed.
* Shared/API/c/cf/WKURLResponseCF.cpp: Removed.
* Shared/API/c/cf/WKURLResponseCF.h: Removed.

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

5 years agoChange some images for a blog post.
timothy@apple.com [Thu, 23 Jul 2015 18:21:00 +0000 (18:21 +0000)]
Change some images for a blog post.

* blog-files/inspector-elements-tab.png:
* blog-files/inspector-network-tab.png:

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

5 years agoFix the build
timothy_horton@apple.com [Thu, 23 Jul 2015 18:04:55 +0000 (18:04 +0000)]
Fix the build

* Platform/spi/ios/UIKitSPI.h:

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

5 years agoAdd and change some images for a blog post.
timothy@apple.com [Thu, 23 Jul 2015 18:03:03 +0000 (18:03 +0000)]
Add and change some images for a blog post.

* blog-files/inspector-elements-network-tabs.png: Removed.
* blog-files/inspector-elements-tab.png: Added.
* blog-files/inspector-network-tab.png: Added.
* blog-files/inspector-tab-bar.png:

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

5 years agoCorrect rest of the images to match.
bfulgham@apple.com [Thu, 23 Jul 2015 17:30:13 +0000 (17:30 +0000)]
Correct rest of the images to match.

* blog-files/backdrop-filters/backdrop_correct_1x.jpg:
* blog-files/backdrop-filters/backdrop_correct_2x.jpg:
* blog-files/backdrop-filters/backdrop_invert_1x.jpg:
* blog-files/backdrop-filters/backdrop_invert_2x.jpg:
* blog-files/backdrop-filters/backdrop_mixed_1x.jpg:

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

5 years ago[Win] Unreviewed build fix after r187169.
achristensen@apple.com [Thu, 23 Jul 2015 17:26:58 +0000 (17:26 +0000)]
[Win] Unreviewed build fix after r187169.

* Scripts/build-webkit:
Correctly find WebKit.sln.

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

5 years agoAdjust image sizes to avoid page scaling.
bfulgham@apple.com [Thu, 23 Jul 2015 17:21:50 +0000 (17:21 +0000)]
Adjust image sizes to avoid page scaling.

* blog-files/backdrop-filters/Screen_OSX_Yosemite_Finder-iCloud-WaterBg_1x.jpg:
* blog-files/backdrop-filters/Screen_OSX_Yosemite_Finder-iCloud-WaterBg_2x.jpg:
* blog-files/backdrop-filters/Screen_V_iOS8_ControlCenter_BlueGradient_1x.jpg:
* blog-files/backdrop-filters/Screen_V_iOS8_ControlCenter_BlueGradient_2x.jpg:
* blog-files/backdrop-filters/backdrop_mixed_2x.jpg:

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

5 years agoApplication cache abort() tests are flaky
msaboff@apple.com [Thu, 23 Jul 2015 14:02:24 +0000 (14:02 +0000)]
Application cache abort() tests are flaky
https://bugs.webkit.org/show_bug.cgi?id=87633

These AppCache tests are flakey:
http/tests/appcache/deferred-events-delete-while-raising-timer.html
http/tests/appcache/deferred-events-delete-while-raising.html
http/tests/appcache/deferred-events.html
http/tests/appcache/fail-on-update-2.html

* TestExpectations:

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

5 years agoWeb Inspector: wrong cursor shown when selecting time interval from timeline overview
mattbaker@apple.com [Thu, 23 Jul 2015 14:00:00 +0000 (14:00 +0000)]
Web Inspector: wrong cursor shown when selecting time interval from timeline overview
https://bugs.webkit.org/show_bug.cgi?id=147094

Reviewed by Timothy Hatcher.

* UserInterface/Views/TimelineRuler.css:
(.timeline-ruler.allows-time-range-selection.creating-selection):
New cursor style for entire ruler element.

* UserInterface/Views/TimelineRuler.js:
(WebInspector.TimelineRuler.prototype._handleMouseMove):
(WebInspector.TimelineRuler.prototype._handleMouseUp):
Toggle cursor style when dragging to create a new selection in the overview.

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

5 years ago[Win] Fix typos in PluginViewWin.cpp: kWebPluginViewdowClassName -> kWebPluginViewCla...
commit-queue@webkit.org [Thu, 23 Jul 2015 12:21:33 +0000 (12:21 +0000)]
[Win] Fix typos in PluginViewWin.cpp: kWebPluginViewdowClassName -> kWebPluginViewClassName
https://bugs.webkit.org/show_bug.cgi?id=147214

Patch by Sungmann Cho <sungmann.cho@navercorp.com> on 2015-07-23
Reviewed by Csaba Osztrogonác.

* Plugins/PluginViewWin.cpp:
(WebCore::registerPluginView):
(WebCore::PluginView::platformStart):

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

5 years agoFix the build for __IPHONE_OS_VERSION_MIN_REQUIRED <= 80200 || !HAVE(AVKIT)
timothy_horton@apple.com [Thu, 23 Jul 2015 10:11:28 +0000 (10:11 +0000)]
Fix the build for __IPHONE_OS_VERSION_MIN_REQUIRED <= 80200 || !HAVE(AVKIT)

* platform/ios/WebVideoFullscreenControllerAVKit.mm:
(elementRectInWindow):
This helper is only used in the #else block, so move it there.

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

5 years agoRemove files that were meant to be removed in r173929
timothy_horton@apple.com [Thu, 23 Jul 2015 10:05:22 +0000 (10:05 +0000)]
Remove files that were meant to be removed in r173929

* WebProcess/WebPage/mac/WebInspectorMac.mm: Removed.

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

5 years agoRemove files that were meant to be removed in r168213
timothy_horton@apple.com [Thu, 23 Jul 2015 09:58:01 +0000 (09:58 +0000)]
Remove files that were meant to be removed in r168213

* UIProcess/API/Cocoa/WKErrorRecoveryAttempting.h: Removed.

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

5 years agoRemove files that were meant to be removed in r168229
timothy_horton@apple.com [Thu, 23 Jul 2015 09:50:37 +0000 (09:50 +0000)]
Remove files that were meant to be removed in r168229

* UIProcess/API/Cocoa/WKSession.h: Removed.
* UIProcess/API/Cocoa/WKSession.mm: Removed.
* UIProcess/API/Cocoa/WKSessionInternal.h: Removed.

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

5 years agoRemove files that were meant to be removed in r165014
timothy_horton@apple.com [Thu, 23 Jul 2015 09:18:01 +0000 (09:18 +0000)]
Remove files that were meant to be removed in r165014

* WebProcess/WebPage/mac/WKAccessibilityWebPageObject.h: Removed.
* WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm: Removed.

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

5 years ago[GTK] Add API to allow executing editing commands that require an argument
carlosgc@webkit.org [Thu, 23 Jul 2015 08:23:25 +0000 (08:23 +0000)]
[GTK] Add API to allow executing editing commands that require an argument
https://bugs.webkit.org/show_bug.cgi?id=146781

Reviewed by Gustavo Noronha Silva.

Source/WebKit2:

Commands like InsertImage or CreateLink receive an argument, but
we only have webkit_web_view_execute_editing_command() that
doesn't receive any argument. This patch adds
webkit_web_view_execute_editing_command_with_argument() for those
commands. It also adds WEBKIT_EDITING_COMMAND_INSERT_IMAGE and
WEBKIT_EDITING_COMMAND_CREATE_LINK to the predefined editing commands.

* UIProcess/API/gtk/WebKitEditingCommands.h: Add
WEBKIT_EDITING_COMMAND_INSERT_IMAGE and WEBKIT_EDITING_COMMAND_CREATE_LINK.
* UIProcess/API/gtk/WebKitWebView.cpp:
(webkit_web_view_execute_editing_command_with_argument):
* UIProcess/API/gtk/WebKitWebView.h:
* UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt: Add new symbols.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::executeEditCommand): Pass also the argument
to the message.
* UIProcess/WebPageProxy.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::executeEditCommand): Add the argument parameter
to the message handler.
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in: Add argument parameter
to ExecuteEditCommand message.

Tools:

Add buttons to insert image/link to the MiniBrowser edit toolbar,
and test cases for insert image/link commands too.

* MiniBrowser/gtk/BrowserWindow.c:
(insertImageCommandCallback):
(insertLinkCommandCallback):
(browserWindowSetupEditorToolbar):
(browserWindowConstructed):
* TestWebKitAPI/Tests/WebKit2Gtk/TestWebViewEditor.cpp:
(testWebViewEditorInsertImage):
(testWebViewEditorCreateLink):
(beforeAll):

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

5 years agoTry to fix the build
timothy_horton@apple.com [Thu, 23 Jul 2015 07:58:15 +0000 (07:58 +0000)]
Try to fix the build

* platform/spi/cocoa/QuartzCoreSPI.h:

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

5 years agoUnregistering and re-registering a user message handler does not work
carlosgc@webkit.org [Thu, 23 Jul 2015 07:31:14 +0000 (07:31 +0000)]
Unregistering and re-registering a user message handler does not work
https://bugs.webkit.org/show_bug.cgi?id=138142

Reviewed by Martin Robinson.

This has probably been fixed in r184846, enable the test case
blocked on it.

* TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitUserContentManager.cpp:
(testUserContentManagerScriptMessageReceived):

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

5 years agoAdd ENABLE_WEBASSEMBLY feature flag for WebAssembly
commit-queue@webkit.org [Thu, 23 Jul 2015 05:44:15 +0000 (05:44 +0000)]
Add ENABLE_WEBASSEMBLY feature flag for WebAssembly
https://bugs.webkit.org/show_bug.cgi?id=147212

Patch by Sukolsak Sakshuwong <sukolsak@gmail.com> on 2015-07-22
Reviewed by Filip Pizlo.

.:

* Source/cmake/WebKitFeatures.cmake:

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

No new tests.

* Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

Source/WTF:

* wtf/FeatureDefines.h:

Tools:

* Scripts/webkitperl/FeatureList.pm:

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

5 years agoTry to fix the build
timothy_horton@apple.com [Thu, 23 Jul 2015 05:31:32 +0000 (05:31 +0000)]
Try to fix the build

* platform/spi/cocoa/QuartzCoreSPI.h:

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

5 years agoUse updated CoreAnimation snapshot SPI.
timothy_horton@apple.com [Thu, 23 Jul 2015 05:09:16 +0000 (05:09 +0000)]
Use updated CoreAnimation snapshot SPI.
https://bugs.webkit.org/show_bug.cgi?id=147197
<rdar://problem/21032083>

Reviewed by Tim Horton.
Patch by James Savage.

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):

* platform/spi/cocoa/QuartzCoreSPI.h:

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

5 years agoSimplify DFG::DesiredIdentifiers and make it possible to turn a UniquedStringImpl...
fpizlo@apple.com [Thu, 23 Jul 2015 04:58:34 +0000 (04:58 +0000)]
Simplify DFG::DesiredIdentifiers and make it possible to turn a UniquedStringImpl* into an identifierNumber at any time
https://bugs.webkit.org/show_bug.cgi?id=147218

Reviewed by Sam Weinig.

I want to be able to take a UniquedStringImpl* and turn it into an identifierNumber at
various points in my work on https://bugs.webkit.org/show_bug.cgi?id=146929. Currently,
most Nodes that deal with identifiers use identifierNumbers and you can only create an
identifierNumber in BytecodeGenerator. DFG::ByteCodeParser does sort of have the
ability to create new identifierNumbers when inlining - it takes the inlined code's
identifiers and either gives them new numbers or reuses numbers from the enclosing
code.

This patch takes that basic functionality and puts it in
DFG::DesiredIdentifiers::ensure(). Anyone can call this at any time to turn a
UniquedStringImpl* into an identifierNumber. This data structure is already used by
Plan to properly install any newly created identifier table entries into the CodeBlock.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::ByteCodeParser):
(JSC::DFG::ByteCodeParser::noticeArgumentsUse):
(JSC::DFG::ByteCodeParser::linkBlocks):
(JSC::DFG::ByteCodeParser::InlineStackEntry::InlineStackEntry):
(JSC::DFG::ByteCodeParser::buildOperandMapsIfNecessary): Deleted.
* dfg/DFGDesiredIdentifiers.cpp:
(JSC::DFG::DesiredIdentifiers::DesiredIdentifiers):
(JSC::DFG::DesiredIdentifiers::numberOfIdentifiers):
(JSC::DFG::DesiredIdentifiers::ensure):
(JSC::DFG::DesiredIdentifiers::at):
(JSC::DFG::DesiredIdentifiers::addLazily): Deleted.
* dfg/DFGDesiredIdentifiers.h:

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

5 years agoSimplify things like CompareEq(@x,@x)
fpizlo@apple.com [Thu, 23 Jul 2015 04:51:48 +0000 (04:51 +0000)]
Simplify things like CompareEq(@x,@x)
https://bugs.webkit.org/show_bug.cgi?id=145850

Reviewed by Sam Weinig.

This simplifies x==x to true, except in cases where x might be a double (in which case this
might still be false if x is NaN).

* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* tests/stress/nan-equal-untyped.js: Added.
(foo):
(test):
* tests/stress/nan-equal.js: Added.
(foo):

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

5 years agoFix the build
timothy_horton@apple.com [Thu, 23 Jul 2015 04:47:33 +0000 (04:47 +0000)]
Fix the build

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView setupInteraction]):
(-[WKContentView cleanupInteraction]):

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

5 years agoWeb Inspector: Timeline should immediately start moving play head when starting a...
commit-queue@webkit.org [Thu, 23 Jul 2015 04:45:52 +0000 (04:45 +0000)]
Web Inspector: Timeline should immediately start moving play head when starting a new recording
https://bugs.webkit.org/show_bug.cgi?id=147210

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-22
Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

* inspector/protocol/Timeline.json:
Add timestamps to recordingStarted and recordingStopped events.

Source/WebCore:

Test: inspector/timeline/recording-start-stop-timestamps.html

* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::internalStart):
(WebCore::InspectorTimelineAgent::internalStop):
Include the current timestamp when starting / stopping a recording.

Source/WebInspectorUI:

* UserInterface/Protocol/TimelineObserver.js:
(WebInspector.TimelineObserver.prototype.recordingStarted):
(WebInspector.TimelineObserver.prototype.recordingStopped):
Pass on the new timestamps.

* UserInterface/Controllers/TimelineManager.js:
(WebInspector.TimelineManager.prototype.capturingStarted):
(WebInspector.TimelineManager.prototype.capturingStopped):
Pass on the new timestamps in the events.

* UserInterface/Views/TimelineRecordingContentView.js:
(WebInspector.TimelineRecordingContentView.prototype._capturingStarted):
Pass on the new timestamp from the event as it can be used to update the currentTime.

(WebInspector.TimelineRecordingContentView.prototype._startUpdatingCurrentTime):
If provided a startTime we can use that as the new currentTime. Otherwise fallback
to determining a good currentTime from the next incoming record for legacy backends.

(WebInspector.TimelineRecordingContentView.prototype._recordingTimesUpdated):
Update the comment, as there is now a solution but this is required for legacy backends.

LayoutTests:

* inspector/timeline/recording-start-stop-timestamps-expected.txt: Added.
* inspector/timeline/recording-start-stop-timestamps.html: Added.
Add a test for Timeline.recordingStarted and Timeline.recordingStopped events.

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

5 years agoCoordinates-based snap offsets don't update correctly when container is scrolled
wenson_hsieh@apple.com [Thu, 23 Jul 2015 04:24:12 +0000 (04:24 +0000)]
Coordinates-based snap offsets don't update correctly when container is scrolled
https://bugs.webkit.org/show_bug.cgi?id=147215

Reviewed by Brent Fulgham.

Source/WebCore:

Fixes the way we append the snap offsets of child elements with coordinates. We
now consider the scroll offset of the parent scroll snapping container, so snap
offset recomputations don't fail on scroll snapping containers.

Test: css3/scroll-snap/scroll-snap-coordinate-overflow-resize.html

* page/scrolling/AxisScrollSnapOffsets.cpp:
(WebCore::appendChildSnapOffsets): Fixed to consider the scroll offset of the
    parent container.

LayoutTests:

Tests that snap offsets update properly on scrolled containers.

* css3/scroll-snap/scroll-snap-coordinate-overflow-resize-expected.txt: Added.
* css3/scroll-snap/scroll-snap-coordinate-overflow-resize.html: Added.

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

5 years agoWeb Inspector: Timeline's Current Time does not jump forward to new start time when...
commit-queue@webkit.org [Thu, 23 Jul 2015 04:18:38 +0000 (04:18 +0000)]
Web Inspector: Timeline's Current Time does not jump forward to new start time when starting a new recording, causes timeline to appear delayed and broken
https://bugs.webkit.org/show_bug.cgi?id=147204

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-22
Reviewed by Timothy Hatcher.

* UserInterface/Views/TimelineRecordingContentView.js:
(WebInspector.TimelineRecordingContentView.prototype._recordingTimesUpdated):
We were skipping a timeline, but it might have a new event record with
a new start time. This ensures we get an updated current time which makes
sense, and we jump forward to that time in the main timeline.

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

5 years agoNeeded to add methods to get PreviewCaptureLayers from Video
commit-queue@webkit.org [Thu, 23 Jul 2015 04:15:15 +0000 (04:15 +0000)]
Needed to add methods to get PreviewCaptureLayers from Video
https://bugs.webkit.org/show_bug.cgi?id=147011
<rdar://problem/21861999>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-22
Reviewed by Jer Noble.

* platform/mediastream/mac/AVVideoCaptureSource.h: Added in preview
layer to class
(WebCore::AVVideoCaptureSource::previewLayer):
* platform/mediastream/mac/AVVideoCaptureSource.mm: Instantiate
previewLayer on load
(WebCore::AVVideoCaptureSource::setupCaptureSession):

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

5 years agoWeb Inspector: TimelineRuler shouldn't dispatch selection changed event unless it...
mattbaker@apple.com [Thu, 23 Jul 2015 03:54:33 +0000 (03:54 +0000)]
Web Inspector: TimelineRuler shouldn't dispatch selection changed event unless it actually changes
https://bugs.webkit.org/show_bug.cgi?id=147219

Reviewed by Timothy Hatcher.

Moved to a "suppress next" model for suppressing dispatch of TimelineRuler's selection changed event. The
ruler's _timeRangeSelectionChanged flag is now reset only when an event is finally dispatched.

* UserInterface/Views/TimelineRuler.js:
(WebInspector.TimelineRuler):
(WebInspector.TimelineRuler.prototype._updateSelection):
(WebInspector.TimelineRuler.prototype._dispatchTimeRangeSelectionChangedEvent):
Check for this._timeRangeSelectionChanged moved into dispatch function.
(WebInspector.TimelineRuler.prototype._handleMouseDown):
(WebInspector.TimelineRuler.prototype._handleMouseMove):
(WebInspector.TimelineRuler.prototype._handleMouseUp):
We now suppress the next dispatch only, rather than a toggle.

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

5 years ago[EFL] The "Missing Plug-in" buttons are not showing up on some flash contents
commit-queue@webkit.org [Thu, 23 Jul 2015 03:36:31 +0000 (03:36 +0000)]
[EFL] The "Missing Plug-in" buttons are not showing up on some flash contents
https://bugs.webkit.org/show_bug.cgi?id=147191

Patch by Sungmann Cho <sungmann.cho@navercorp.com> on 2015-07-22
Reviewed by Gyuyoung Kim.

Currently, WebKitEFL doesn't show the "Missing Plug-in" buttons if the plugin-related tags
don't have a "type" attribute. In such a case, WebCore tries to guess the MIME type from
the extensions by using MIMETypeRegistry::getMIMETypeForExtension(). For WebKitEFL,
MIMETypeRegistry::getMIMETypeForExtension() goes through |extensionMap|, which is a simple
array of <extension, mime type>, looking for the mime type for the given extension.
But |extensionMap| in MIMETypeRegistryEfl.cpp doesn't have the information for ".swf",
so WebCore fails to guess the MIME type and regard the content type as ObjectContentFrame,
not ObjectContentNetscapePlugin.

* platform/efl/MIMETypeRegistryEfl.cpp:

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

5 years agoIntroducing construct ability into JS executables
utatane.tea@gmail.com [Thu, 23 Jul 2015 02:36:20 +0000 (02:36 +0000)]
Introducing construct ability into JS executables
https://bugs.webkit.org/show_bug.cgi?id=147183

Reviewed by Geoffrey Garen.

Decouple the construct ability from the builtin functions.
Currently, all builtin functions are not constructors after r182995.
In that patch, when the given function is builtin JS function, we recognize it as the non-constructor function.

But, we need to relax it to implement some constructors in builtins JS.
By decoupling the construct ability from whether the function is builtin or not, we can provide

1. constructors written in builtin JS
2. non-constructors in normal JS functions

(1) is needed for Promise constructor.
And (2) is needed for method functions and arrow functions.

This patch introduces ConstructAbility into the unlinked function executables.
It holds whether the given JS function has the construct ability or not.
By leveraging this, this patch disables the construct ability of the method definitions, setters, getters and arrow functions.

And at the same time, this patch introduces the annotation for constructor in builtin JS.
We can define the function as follows,

    constructor Promise(executor)
    {
        ...
    }

* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:
* JavaScriptCore.xcodeproj/project.pbxproj:
* builtins/BuiltinExecutables.cpp:
(JSC::BuiltinExecutables::createDefaultConstructor):
(JSC::BuiltinExecutables::createExecutableInternal):
* builtins/BuiltinExecutables.h:
* builtins/Iterator.prototype.js:
(symbolIterator):
(SymbolIterator): Deleted.
* bytecode/UnlinkedCodeBlock.cpp:
(JSC::UnlinkedFunctionExecutable::UnlinkedFunctionExecutable):
* bytecode/UnlinkedCodeBlock.h:
* bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::makeFunction):
* generate-js-builtins:
(getCopyright):
(Function):
(Function.__init__):
(Function.mangleName):
(getFunctions):
(mangleName): Deleted.
* jit/JITOperations.cpp:
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::setUpCall):
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseClass):
* runtime/CodeCache.cpp:
(JSC::CodeCache::getFunctionExecutableFromGlobalCode):
* runtime/CommonIdentifiers.h:
* runtime/ConstructAbility.h: Copied from Source/JavaScriptCore/builtins/Iterator.prototype.js.
* runtime/Executable.h:
* runtime/JSFunction.cpp:
(JSC::JSFunction::getConstructData):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* tests/stress/non-constructors.js: Added.
(shouldThrow):
(.prototype.method):
(.prototype.get getter):
(.prototype.set setter):
(.method):
(.get shouldThrow):
(.set shouldThrow):
(set var.test.get getter):
(set var.test.set setter):
(set var.test.normal):
(.set var):
(.set new):

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

5 years agoRank sources for fitness for UIDs in bestSourcesForTypeAndConstraints
commit-queue@webkit.org [Thu, 23 Jul 2015 01:54:54 +0000 (01:54 +0000)]
Rank sources for fitness for UIDs in bestSourcesForTypeAndConstraints
https://bugs.webkit.org/show_bug.cgi?id=147206
<rdar://problem/21950653>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-22
Reviewed by Jer Noble.

* platform/mediastream/RealtimeMediaSource.cpp:
(WebCore::RealtimeMediaSource::RealtimeMediaSource):
* platform/mediastream/RealtimeMediaSource.h:
(WebCore::RealtimeMediaSource::fitnessScore):
(WebCore::RealtimeMediaSource::setFitnessScore):
* platform/mediastream/mac/AVCaptureDeviceManager.mm:
(WebCore::AVCaptureDeviceManager::bestSourcesForTypeAndConstraints):

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

5 years agoVideo controls, though hidden, are still interactive when in PiP
dino@apple.com [Thu, 23 Jul 2015 01:47:00 +0000 (01:47 +0000)]
Video controls, though hidden, are still interactive when in PiP
https://bugs.webkit.org/show_bug.cgi?id=147216
<rdar://problem/21012688>

Reviewed by Simon Fraser.

Explicitly add the PiP class to the controls container so that
we can hang a pointer-events: none off it.

* Modules/mediacontrols/mediaControlsiOS.css:
(video::-webkit-media-controls-panel.picture-in-picture): Add a pointer-events: none.
* Modules/mediacontrols/mediaControlsiOS.js:
(ControllerIOS.prototype.handlePresentationModeChange): Add/remove a PiP class
to the controls panel when necessary.

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

5 years agoUnreviewed, rolling out r187196.
commit-queue@webkit.org [Thu, 23 Jul 2015 01:21:12 +0000 (01:21 +0000)]
Unreviewed, rolling out r187196.
https://bugs.webkit.org/show_bug.cgi?id=147213

broke all the iOS builds (Requested by thorton on #webkit).

Reverted changeset:

"Use updated CoreAnimation snapshot SPI."
https://bugs.webkit.org/show_bug.cgi?id=147197
http://trac.webkit.org/changeset/187196

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

5 years agoFix the build
timothy_horton@apple.com [Thu, 23 Jul 2015 01:19:41 +0000 (01:19 +0000)]
Fix the build

* UIProcess/ios/WKContentViewInteraction.h:

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

5 years ago[iOS] Adjust the preview architecture
timothy_horton@apple.com [Thu, 23 Jul 2015 01:08:30 +0000 (01:08 +0000)]
[iOS] Adjust the preview architecture
https://bugs.webkit.org/show_bug.cgi?id=147203
<rdar://problem/21945775>

Reviewed by Simon Fraser.

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _dataForPreviewItemController:atPosition:type:]):
Link previews should win over image previews if both are possible.

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

5 years agoUse updated CoreAnimation snapshot SPI.
commit-queue@webkit.org [Thu, 23 Jul 2015 00:53:36 +0000 (00:53 +0000)]
Use updated CoreAnimation snapshot SPI.
https://bugs.webkit.org/show_bug.cgi?id=147197

Patch by James Savage <james.savage@apple.com> on 2015-07-22
Reviewed by Tim Horton.

Source/WebCore:

* platform/spi/cocoa/QuartzCoreSPI.h:

Source/WebKit2:

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):

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

5 years agoWeb Inspector: REGRESSION (Safari 7): Pseudo element rules are not labelled with...
drousso@apple.com [Thu, 23 Jul 2015 00:44:09 +0000 (00:44 +0000)]
Web Inspector: REGRESSION (Safari 7): Pseudo element rules are not labelled with media queries in Styles panel
https://bugs.webkit.org/show_bug.cgi?id=147207

Reviewed by Timothy Hatcher.

* UserInterface/Views/RulesStyleDetailsPanel.js:
(WebInspector.RulesStyleDetailsPanel.prototype.refresh.insertMediaOrInheritanceLabel):
(WebInspector.RulesStyleDetailsPanel.prototype.refresh.insertAllMatchingPseudoStyles):
Now inserts pseudo-styles based on whether their selector specificity is greater than
the previous style's selector specificity.
(WebInspector.RulesStyleDetailsPanel.prototype.refresh):

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

5 years ago[El Capitan] Test Gardening
mmaxfield@apple.com [Thu, 23 Jul 2015 00:04:02 +0000 (00:04 +0000)]
[El Capitan] Test Gardening

Unreviewed.

* platform/mac/fast/text/ligature-subdivision-expected.txt:

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

5 years ago[iOS] Adjust the preview architecture
timothy_horton@apple.com [Wed, 22 Jul 2015 23:23:02 +0000 (23:23 +0000)]
[iOS] Adjust the preview architecture
https://bugs.webkit.org/show_bug.cgi?id=147203
<rdar://problem/21945775>

Reviewed by Beth Dakin.

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _setAllowsLinkPreview:]): Deleted.
* UIProcess/ios/WKContentView.mm:
(-[WKContentView willMoveToWindow:]): Deleted.
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView setupInteraction]):
(-[WKContentView cleanupInteraction]):
(-[WKContentView _registerPreview]):
(-[WKContentView _unregisterPreview]):
(-[WKContentView _interactionShouldBeginFromPreviewItemController:forPosition:]):
(-[WKContentView _dataForPreviewItemController:atPosition:type:]):
(-[WKContentView _presentationRectForPreviewItemController:]):
(-[WKContentView _presentedViewControllerForPreviewItemController:]):
(-[WKContentView _previewItemController:commitPreview:]):
(-[WKContentView _previewItemController:willPresentPreview:forPosition:inSourceView:]):
(-[WKContentView _previewItemController:didDismissPreview:committing:]):
(-[WKContentView _presentationSnapshotForPreviewItemController:]):
(-[WKContentView _presentationRectsForPreviewItemController:]):
(-[WKContentView gestureRecognizerShouldBegin:]): Deleted.
(-[WKContentView _registerPreviewInWindow:]): Deleted.
(-[WKContentView _unregisterPreviewInWindow:]): Deleted.
(-[WKContentView previewViewControllerForPosition:inSourceView:]): Deleted.
(-[WKContentView commitPreviewViewController:]): Deleted.
(-[WKContentView willPresentPreviewViewController:forPosition:inSourceView:]): Deleted.
(-[WKContentView didDismissPreviewViewController:committing:]): Deleted.
Register and unregister in setup/cleanupInteraction instead of when moving between windows.
Implement 'shouldBegin' instead of interacting directly with the recognizer.
Make use of system enums instead of our own.
Let UIPreviewItemController handle shrink-wrapping and the indicator view.

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

5 years ago[EFL] Support indexeddb for WK2
gyuyoung.kim@webkit.org [Wed, 22 Jul 2015 22:51:35 +0000 (22:51 +0000)]
[EFL] Support indexeddb for WK2
https://bugs.webkit.org/show_bug.cgi?id=145867

Reviewed by Csaba Osztrogonác.

Add stub implementation for indexeddb. Move KeyedDecoder and KeyedEncoder from gtk to glib
in order to share it between GTK and EFL ports.

* DatabaseProcess/EntryPoint/unix/DatabaseProcessMain.cpp:
* DatabaseProcess/efl/DatabaseProcessMainEfl.cpp: Copied from Source/WebKit2/DatabaseProcess/EntryPoint/unix/DatabaseProcessMain.cpp.
(WebKit::DatabaseProcessMainUnix):
* PlatformEfl.cmake:
* PlatformGTK.cmake:
* Shared/glib/KeyedDecoder.cpp: Renamed from Source/WebKit2/Shared/gtk/KeyedDecoder.cpp.
(WebKit::KeyedDecoder::KeyedDecoder):
(WebKit::KeyedDecoder::~KeyedDecoder):
(WebKit::KeyedDecoder::dictionaryFromGVariant):
(WebKit::KeyedDecoder::decodeBytes):
(WebKit::KeyedDecoder::decodeSimpleValue):
(WebKit::KeyedDecoder::decodeBool):
(WebKit::KeyedDecoder::decodeUInt32):
(WebKit::KeyedDecoder::decodeInt32):
(WebKit::KeyedDecoder::decodeInt64):
(WebKit::KeyedDecoder::decodeFloat):
(WebKit::KeyedDecoder::decodeDouble):
(WebKit::KeyedDecoder::decodeString):
(WebKit::KeyedDecoder::beginObject):
(WebKit::KeyedDecoder::endObject):
(WebKit::KeyedDecoder::beginArray):
(WebKit::KeyedDecoder::beginArrayElement):
(WebKit::KeyedDecoder::endArrayElement):
(WebKit::KeyedDecoder::endArray):
* Shared/glib/KeyedDecoder.h: Renamed from Source/WebKit2/Shared/gtk/KeyedDecoder.h.
* Shared/glib/KeyedEncoder.cpp: Renamed from Source/WebKit2/Shared/gtk/KeyedEncoder.cpp.
(WebKit::KeyedEncoder::KeyedEncoder):
(WebKit::KeyedEncoder::~KeyedEncoder):
(WebKit::KeyedEncoder::encodeBytes):
(WebKit::KeyedEncoder::encodeBool):
(WebKit::KeyedEncoder::encodeUInt32):
(WebKit::KeyedEncoder::encodeInt32):
(WebKit::KeyedEncoder::encodeInt64):
(WebKit::KeyedEncoder::encodeFloat):
(WebKit::KeyedEncoder::encodeDouble):
(WebKit::KeyedEncoder::encodeString):
(WebKit::KeyedEncoder::beginObject):
(WebKit::KeyedEncoder::endObject):
(WebKit::KeyedEncoder::beginArray):
(WebKit::KeyedEncoder::beginArrayElement):
(WebKit::KeyedEncoder::endArrayElement):
(WebKit::KeyedEncoder::endArray):
(WebKit::KeyedEncoder::finishEncoding):
* Shared/glib/KeyedEncoder.h: Renamed from Source/WebKit2/Shared/gtk/KeyedEncoder.h.
* UIProcess/Databases/efl/DatabaseProcessProxyEfl.cpp: Copied from Source/WebKit2/DatabaseProcess/EntryPoint/unix/DatabaseProcessMain.cpp.
(WebKit::DatabaseProcessProxy::platformGetLaunchOptions):

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

5 years ago[Seccomp] Canonicalize filesystem path when whitelisting it
mcatanzaro@igalia.com [Wed, 22 Jul 2015 22:09:35 +0000 (22:09 +0000)]
[Seccomp] Canonicalize filesystem path when whitelisting it
https://bugs.webkit.org/show_bug.cgi?id=142986

Reviewed by Žan Doberšek.

* Shared/linux/SeccompFilters/SyscallPolicy.cpp:
(WebKit::canonicalizeFileName):
(WebKit::SyscallPolicy::addFilePermission):
(WebKit::SyscallPolicy::addDirectoryPermission):

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

5 years agoOut of bounds in WebGLRenderingContext::simulateVertexAttrib0
dino@apple.com [Wed, 22 Jul 2015 21:55:48 +0000 (21:55 +0000)]
Out of bounds in WebGLRenderingContext::simulateVertexAttrib0
https://bugs.webkit.org/show_bug.cgi?id=147176
<rdar://problem/21567767>

Reviewed by Oliver Hunt.

Source/WebCore:

Test: fast/canvas/webgl/out-of-bounds-simulated-vertexAttrib0-drawArrays.html

Add overflow checking for the drawing calls, specifically the way
they may simulate vertexAttrib0.

* html/canvas/WebGLRenderingContextBase.cpp:
(WebCore::WebGLRenderingContextBase::validateDrawArrays): Call new validation method.
(WebCore::WebGLRenderingContextBase::validateDrawElements): Ditto.
(WebCore::WebGLRenderingContextBase::validateSimulatedVertexAttrib0): New method that
validates the parameters used to create the simulated attribute.
(WebCore::WebGLRenderingContextBase::simulateVertexAttrib0): No need to do overflow
checking here now that the validation method does it for us.
(WebCore::WebGLRenderingContextBase::validateVertexAttributes): Deleted.
* html/canvas/WebGLRenderingContextBase.h: Add new validation method.

LayoutTests:

* fast/canvas/webgl/out-of-bounds-simulated-vertexAttrib0-drawArrays-expected.txt: Added.
* fast/canvas/webgl/out-of-bounds-simulated-vertexAttrib0-drawArrays.html: Added.

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

5 years agoAdd some images needed for an upcoming blog post.
bfulgham@apple.com [Wed, 22 Jul 2015 21:42:51 +0000 (21:42 +0000)]
Add some images needed for an upcoming blog post.

* blog-files/backdrop-filters: Added.
* blog-files/backdrop-filters/Screen_OSX_Yosemite_Finder-iCloud-WaterBg_1x.jpg: Added.
* blog-files/backdrop-filters/Screen_OSX_Yosemite_Finder-iCloud-WaterBg_2x.jpg: Added.
* blog-files/backdrop-filters/Screen_V_iOS8_ControlCenter_BlueGradient_1x.jpg: Added.
* blog-files/backdrop-filters/Screen_V_iOS8_ControlCenter_BlueGradient_2x.jpg: Added.
* blog-files/backdrop-filters/backdrop_correct_1x.jpg: Added.
* blog-files/backdrop-filters/backdrop_correct_2x.jpg: Added.
* blog-files/backdrop-filters/backdrop_invert_1x.jpg: Added.
* blog-files/backdrop-filters/backdrop_invert_2x.jpg: Added.
* blog-files/backdrop-filters/backdrop_mixed_1x.jpg: Added.
* blog-files/backdrop-filters/backdrop_mixed_2x.jpg: Added.

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

5 years agoWeb Inspector: AppCache manifest 404 doesn't produce errors in console, manifest...
commit-queue@webkit.org [Wed, 22 Jul 2015 21:36:04 +0000 (21:36 +0000)]
Web Inspector: AppCache manifest 404 doesn't produce errors in console, manifest resource request always loading indicator
https://bugs.webkit.org/show_bug.cgi?id=147135

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-22
Reviewed by Alexey Proskuryakov.

Source/WebCore:

* loader/appcache/ApplicationCacheGroup.cpp:
(WebCore::ApplicationCacheGroup::didReceiveResponse):
Always pass a document loader instead of passing null for the manifest request.

(WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
Since we will be cancelling the resource handle ourselves in didReceiveResponse
before receiving the didFail resource handle delegates, we should update the
inspector about this resource load failing due to a cancel.

(WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
(WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
Update the MessageSource from "Other" to "AppCache".

LayoutTests:

* http/tests/appcache/404-manifest-expected.txt:
* http/tests/appcache/abort-cache-ondownloading-manifest-404-expected.txt:
* http/tests/appcache/deferred-events-delete-while-raising-expected.txt:
* http/tests/appcache/deferred-events-delete-while-raising-timer-expected.txt:
* http/tests/appcache/deferred-events-expected.txt:
* http/tests/appcache/fail-on-update-2-expected.txt:
* http/tests/appcache/fail-on-update-expected.txt:
* http/tests/appcache/remove-cache-expected.txt:
Update with new Console errors about manifest 404s.

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

5 years ago[JSC] Enable exception fuzzing for GCC too
ossy@webkit.org [Wed, 22 Jul 2015 21:31:40 +0000 (21:31 +0000)]
[JSC] Enable exception fuzzing for GCC too
https://bugs.webkit.org/show_bug.cgi?id=146831

Reviewed by Darin Adler.

* jit/JITOperations.cpp:

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

5 years agoFix fullscreen and PiP video animation and sizing regressions.
commit-queue@webkit.org [Wed, 22 Jul 2015 21:31:39 +0000 (21:31 +0000)]
Fix fullscreen and PiP video animation and sizing regressions.
https://bugs.webkit.org/show_bug.cgi?id=147189
<rdar://problem/21930899>

Patch by Jeremy Jones <jeremyj@apple.com> on 2015-07-22
Reviewed by Jer Noble.

Fixes WK1 specific regressions introduced by r187044. Flicker when entering fullscreen,
wrong animation and missing initial animation rects.

* platform/ios/WebVideoFullscreenControllerAVKit.mm:
(elementRectInWindow): Added.
(WebVideoFullscreenControllerContext::didSetupFullscreen): Clear background decreases flash.
(WebVideoFullscreenControllerContext::fullscreenMayReturnToInline): Use consistent inline rect.
(WebVideoFullscreenControllerContext::setVideoLayerFrame):
Clear the transform on the web thread instead of on the UI thread.
(WebVideoFullscreenControllerContext::setUpFullscreen): Use consistent inline rect.
(WebVideoFullscreenControllerContext::exitFullscreen): Use consistent inline rect.
* platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
(-[WebAVPlayerLayer resolveBounds]): Clear transform after setting frame.

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

5 years agoAdd --ios-simulator to run-api-tests --help.
jhoneycutt@apple.com [Wed, 22 Jul 2015 21:29:16 +0000 (21:29 +0000)]
Add --ios-simulator to run-api-tests --help.

Rubber-stamped by Dan Bates.

* Scripts/run-api-tests:

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

5 years agoAdopt AVKit's AVSimplePlayerLayerView change for PiP.
commit-queue@webkit.org [Wed, 22 Jul 2015 21:27:27 +0000 (21:27 +0000)]
Adopt AVKit's AVSimplePlayerLayerView change for PiP.
https://bugs.webkit.org/show_bug.cgi?id=147186
<rdar://problem/21928170>

Patch by Jeremy Jones <jeremyj@apple.com> on 2015-07-22
Reviewed by Jer Noble.

Adopt AVKit changes by inheriting from UIView instead of from AVPictureInPicturePlayerLayerView.

* platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
(WebAVPlayerLayerView_layerClass): Style.
(WebAVPlayerLayerView_playerController): Style.
(WebAVPlayerLayerView_videoView): Style.
(getWebAVPictureInPicturePlayerLayerViewClass): Inherit from UIView.

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

5 years agoAdd logging for TiledCoreAnimationDrawingArea resizing
simon.fraser@apple.com [Wed, 22 Jul 2015 20:59:49 +0000 (20:59 +0000)]
Add logging for TiledCoreAnimationDrawingArea resizing
https://bugs.webkit.org/show_bug.cgi?id=147180

Reviewed by Tim Horton.

Add a "Resize" log channel for WebKit2, and use it to log data in scaleViewToFitDocumentIfNeeded().

* Platform/Logging.h:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::scaleViewToFitDocumentIfNeeded):

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

5 years agoIntroduce release assert for using threads before threading is initialized
fpizlo@apple.com [Wed, 22 Jul 2015 20:49:20 +0000 (20:49 +0000)]
Introduce release assert for using threads before threading is initialized
https://bugs.webkit.org/show_bug.cgi?id=147200

Reviewed by Michael Saboff.

This will help bugs where you use createThread() before calling initializeThreading().

* wtf/ThreadIdentifierDataPthreads.cpp:
(WTF::ThreadIdentifierData::initialize):

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

5 years agoFixed pool allocation should always be aligned
fpizlo@apple.com [Wed, 22 Jul 2015 20:31:07 +0000 (20:31 +0000)]
Fixed pool allocation should always be aligned
https://bugs.webkit.org/show_bug.cgi?id=147201

Reviewed by Simon Fraser.

Passing an unaligned size to the allocator can cause asserts or even worse things. The
Options reservation value isn't going to be aligned.

* jit/ExecutableAllocatorFixedVMPool.cpp:
(JSC::FixedVMPoolExecutableAllocator::FixedVMPoolExecutableAllocator):

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

5 years agoEncode/Decode underlying errors when serializing NSErrors
weinig@apple.com [Wed, 22 Jul 2015 19:56:16 +0000 (19:56 +0000)]
Encode/Decode underlying errors when serializing NSErrors
<rdar://problem/21818117>
https://bugs.webkit.org/show_bug.cgi?id=147199

Reviewed by Anders Carlsson.

* Shared/mac/WebCoreArgumentCodersMac.mm:
(IPC::ArgumentCoder<CertificateInfo>::decode):
(IPC::encodeNSError):
(IPC::ArgumentCoder<ResourceError>::encodePlatformData):
(IPC::decodeNSError):
(IPC::ArgumentCoder<ResourceError>::decodePlatformData):
Break out encoding/decoding of the NSErrors into a helpers so they can be called
for the underlying error.

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

5 years agoAnimated images should animate in previews
bdakin@apple.com [Wed, 22 Jul 2015 19:15:06 +0000 (19:15 +0000)]
Animated images should animate in previews
https://bugs.webkit.org/show_bug.cgi?id=147173
-and corresponding-
rdar://problem/21637698

Reviewed by Dan Bernstein.

Source/WebCore:

New virtual function to indicate whether or not the image is animated.
* platform/graphics/BitmapImage.h:
* platform/graphics/Image.h:
(WebCore::Image::isAnimated):

Source/WebKit2:

InteractionInformationAtPosition needs to know if it’s an animated image.
* Shared/InteractionInformationAtPosition.cpp:
(WebKit::InteractionInformationAtPosition::encode):
(WebKit::InteractionInformationAtPosition::decode):
* Shared/InteractionInformationAtPosition.h:

New delegate method to create a link preview view controller for animated
images.
* UIProcess/API/Cocoa/WKUIDelegatePrivate.h:

Treat animated images more like link previews.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView previewViewControllerForPosition:inSourceView:]):

Set info.isAnimatedImage
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::getPositionInformation):

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

5 years agoRemove hardcoded "internal" from Buildbot.prototype._normalizeQueueInfo.
commit-queue@webkit.org [Wed, 22 Jul 2015 19:00:39 +0000 (19:00 +0000)]
Remove hardcoded "internal" from Buildbot.prototype._normalizeQueueInfo.
https://bugs.webkit.org/show_bug.cgi?id=147043

Patch by Jason Marcell <jmarcell@apple.com> on 2015-07-22
Reviewed by Daniel Bates and Alexey Proskuryakov.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Buildbot.js:
(Buildbot.prototype._normalizeQueueInfo):
The _normalizeQueueInfo method now calls the defaultBranches getter instead of using hardcoded values
in cases where the queue.branch property is not set and the queue is not a combined queue.
* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotCombinedQueueView.js:
(BuildbotCombinedQueueView):
Ensuring uniformity of repository branches within a combined queue.
* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
(WebKitBuildbot.prototype.get defaultBranches):
Added; provides a WebKit-specific implementation that sets the queue.branches dictionary to have a
single entry for "openSource" as the default set of branches. Note that we intentionally omitted a
base class implementation of the defaultBranches getter so as to cause a JavaScript TypeError when a
sub-queue of a combined queue does not specify property branch and the derived Buildbot class does not
implement defaultBranches so that a person can either update the definition of the sub-queue or
implement defaultBranches in the derived Buildbot class they are using.

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

5 years ago[WinCairo] SVG path not rendered with all-zero dasharray
commit-queue@webkit.org [Wed, 22 Jul 2015 18:52:47 +0000 (18:52 +0000)]
[WinCairo] SVG path not rendered with all-zero dasharray
https://bugs.webkit.org/show_bug.cgi?id=146997

Patch by Jinyoung Hur <hur.ims@navercorp.com> on 2015-07-22
Reviewed by Martin Robinson.

Source/WebCore:

All-zero dash array should not be passed to cairo_set_dash() as an argument, because it will cause an internal Cairo error.
Rather call cairo_set_dash() with num_dashes=0 to disable dash line.

Tests: fast/canvas/canvas-lineDash.html
       svg/custom/zero-dasharray.html

* platform/graphics/cairo/GraphicsContextCairo.cpp:
(WebCore::GraphicsContext::setLineDash):

LayoutTests:

Canvas 2D context and SVG stroke tests with all-zero dash array are added.

* fast/canvas/canvas-lineDash-expected.txt:
* fast/canvas/script-tests/canvas-lineDash.js:
* svg/custom/zero-dasharray.html: Added
* svg/custom/zero-dasharray-expected.html: Added

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

5 years agoSearch fields render placeholder text improperly.
wenson_hsieh@apple.com [Wed, 22 Jul 2015 18:47:12 +0000 (18:47 +0000)]
Search fields render placeholder text improperly.
https://bugs.webkit.org/show_bug.cgi?id=147192
<rdar://problem/21901076>

Reviewed by Alexey Proskuryakov.

Due to changes in the way AppKit renders search inputs, we must now explicitly
set the placeholder text of a search input rendered using the Mac theme to be
an empty string when rendering the search input box (not including the actual
placeholder text).

* rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::setSearchCellState): Force the placeholder text of
    the NSSearchFieldCell for the Mac theme to be an empty string.

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

5 years agoSwitch WinCairo build to use CMake.
achristensen@apple.com [Wed, 22 Jul 2015 18:14:40 +0000 (18:14 +0000)]
Switch WinCairo build to use CMake.
https://bugs.webkit.org/show_bug.cgi?id=147169

Reviewed by Brent Fulgham.

* Scripts/build-webkit:
* Scripts/webkitdirs.pm:
(determineConfiguration):
(determineArchitecture):
(determinePassedConfiguration):
(passedConfiguration):
(jhbuildWrapperPrefixIfNeeded):
(generateBuildSystemFromCMakeProject):
It's CMake time!  We now use the CMake files to generate a solution in WebKitBuild/Release/WebKit.sln and build that.

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

5 years agoNeed the ability to give only best source UIDs to UserMedia request
commit-queue@webkit.org [Wed, 22 Jul 2015 18:09:08 +0000 (18:09 +0000)]
Need the ability to give only best source UIDs to UserMedia request
https://bugs.webkit.org/show_bug.cgi?id=147171
<rdar://problem/21931121>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-22
Reviewed by Eric Carlson.

* Modules/mediastream/UserMediaRequest.cpp:
(WebCore::UserMediaRequest::constraintsValidated):
* Modules/mediastream/UserMediaRequest.h:
(WebCore::UserMediaRequest::videoDeviceUIDs):
(WebCore::UserMediaRequest::audioDeviceUIDs):
* platform/mediastream/MediaStreamCreationClient.h:
* platform/mediastream/mac/AVCaptureDeviceManager.h:
* platform/mediastream/mac/AVCaptureDeviceManager.mm:
(WebCore::AVCaptureDeviceManager::bestSourcesForTypeAndConstraints):
(WebCore::AVCaptureDeviceManager::bestSourceForTypeAndConstraints): Deleted.
* platform/mediastream/mac/RealtimeMediaSourceCenterMac.cpp:
(WebCore::RealtimeMediaSourceCenterMac::validateRequestConstraints):
(WebCore::RealtimeMediaSourceCenterMac::createMediaStream):
* platform/mock/MockRealtimeMediaSourceCenter.cpp:
(WebCore::MockRealtimeMediaSourceCenter::validateRequestConstraints):

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

5 years agoEnable STATIC_ASSERT_IS_TRIVIALLY_DESTRUCTIBLE for GCC
ossy@webkit.org [Wed, 22 Jul 2015 18:04:12 +0000 (18:04 +0000)]
Enable STATIC_ASSERT_IS_TRIVIALLY_DESTRUCTIBLE for GCC
https://bugs.webkit.org/show_bug.cgi?id=146829

Reviewed by Brent Fulgham.

* heap/GCAssertions.h:

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

5 years agoSource/WebCore:
commit-queue@webkit.org [Wed, 22 Jul 2015 17:21:14 +0000 (17:21 +0000)]
Source/WebCore:
Fix toJSDOMWindow() in the case of an object that has the actual JS DOM window in its prototype chain.
https://bugs.webkit.org/show_bug.cgi?id=146785

Patch by Mark Dittmer <mark.s.dittmer@gmail.com> on 2015-07-22
Reviewed by Mark Lam.

* bindings/js/JSDOMWindowBase.cpp: toJSDOMWindow(): Walk the prototype chain of the given JSValue until a JSDOMWindow or JSDOMWindowShell is found.

LayoutTests:
New test: Object.create(window).location will trigger a crash when toJSDOMWindow() returns NULL on an object that have the JS DOM Window in its prototype chain.
https://bugs.webkit.org/show_bug.cgi?id=146785

Patch by Mark Dittmer <mark.s.dittmer@gmail.com> on 2015-07-22
Reviewed by Mark Lam.

* js/property-of-window-as-prototype-expected.txt:
* js/property-of-window-as-prototype.html:

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

5 years agoRemove revealing getVideoTracks() and getAudioTracks()
commit-queue@webkit.org [Wed, 22 Jul 2015 17:17:12 +0000 (17:17 +0000)]
Remove revealing getVideoTracks() and getAudioTracks()
https://bugs.webkit.org/show_bug.cgi?id=147126
<rdar://problem/21908723>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-22
Reviewed by Eric Carlson.

* Modules/mediastream/MediaStream.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::MediaPlayerPrivateMediaStreamAVFObjC):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::load): Modded to use
tracks() instead of getVideo/AudioTracks()
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::platformLayer): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::playInternal): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::pauseInternal): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setMuted): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::naturalSize): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::hasVideo): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::hasAudio): Ditto
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentMediaTime):
Changed to a FIXME
* platform/mediastream/MediaStreamPrivate.h:

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

5 years agoEnsure MediaPlayerPrivateAVFoundation doesn't load MediaStreams
commit-queue@webkit.org [Wed, 22 Jul 2015 17:12:58 +0000 (17:12 +0000)]
Ensure MediaPlayerPrivateAVFoundation doesn't load MediaStreams
https://bugs.webkit.org/show_bug.cgi?id=147119
<rdar://problem/21904955>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-22
Reviewed by Eric Carlson.

* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h: Set
networkstate to error when loading MediaStreams

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

5 years agoFix quirks in CMake build on Mac and Windows
achristensen@apple.com [Wed, 22 Jul 2015 17:04:03 +0000 (17:04 +0000)]
Fix quirks in CMake build on Mac and Windows
https://bugs.webkit.org/show_bug.cgi?id=147174

Reviewed by Gyuyoung Kim.

.:

* CMakeLists.txt:
* Source/cmake/OptionsWindows.cmake:
Added options I removed in r187022. They are indeed needed.
* Source/cmake/WebKitFS.cmake:
Make the DerivedSources/WebKit directory.

Source/JavaScriptCore:

* PlatformMac.cmake:
Add JSRemoteInspector.cpp and remove semicolon from command to make it actually run.

Source/WebCore:

* PlatformMac.cmake:
Removed files that don't exist any more.
* platform/win/WindowsTouch.h:
Only use definitions of touch structures when compiling with VS2012.

Source/WebKit:

* PlatformMac.cmake:
Fixed syntax, removed files that don't exist any more.

Source/WebKit/win:

* WebView.cpp:
Include winuser.h to get definitions of touch-related structures like tagGESTUREINFO.

Tools:

* CMakeLists.txt:
Don't build DumpRenderTree with CMake for now (until we get that working).
* WinLauncher/CMakeLists.txt:
Renamed WinLauncherLauncher to WinLauncher and WinLauncher to WinLauncherLib to match the Visual Studio build.

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

5 years agoFix cast-align warning in NetworkStateNotifierEfl.cpp
ossy@webkit.org [Wed, 22 Jul 2015 16:08:03 +0000 (16:08 +0000)]
Fix cast-align warning in NetworkStateNotifierEfl.cpp
https://bugs.webkit.org/show_bug.cgi?id=145915

Reviewed by Gyuyoung Kim.

* platform/network/efl/NetworkStateNotifierEfl.cpp:
(WebCore::NetworkStateNotifier::readSocketCallback):

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

5 years ago[Seccomp Filters] Add helpers to get XDG base directory locations
mcatanzaro@igalia.com [Wed, 22 Jul 2015 15:56:50 +0000 (15:56 +0000)]
[Seccomp Filters] Add helpers to get XDG base directory locations
https://bugs.webkit.org/show_bug.cgi?id=142982

Reviewed by Zan Dobersek.

* PlatformEfl.cmake:
* PlatformGTK.cmake:
* Shared/linux/SeccompFilters/XDGBaseDirectory.h: Added.
* Shared/linux/SeccompFilters/XDGBaseDirectoryGLib.cpp: Added.
(WebKit::userHomeDirectory):
(WebKit::userCacheDirectory):
(WebKit::userConfigDirectory):
(WebKit::userDataDirectory):
(WebKit::userRuntimeDirectory):

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

5 years agoWeb Inspector: Change syntax highlighting color for regular expressions to make them...
nvasilyev@apple.com [Wed, 22 Jul 2015 15:44:04 +0000 (15:44 +0000)]
Web Inspector: Change syntax highlighting color for regular expressions to make them more readable
https://bugs.webkit.org/show_bug.cgi?id=146956

Reviewed by Timothy Hatcher.

* UserInterface/Views/FormattedValue.css:
(.formatted-regexp):
* UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
(.syntax-highlighted :matches(.css-string, .javascript-string, .html-attribute-value)):
(.syntax-highlighted .javascript-regexp):
(.syntax-highlighted :matches(.css-string, .javascript-string, .javascript-regexp, .html-attribute-value)): Deleted.

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

5 years ago[l10n] Updated Swedish translation
mcatanzaro@igalia.com [Wed, 22 Jul 2015 14:57:53 +0000 (14:57 +0000)]
[l10n] Updated Swedish translation
https://bugs.webkit.org/show_bug.cgi?id=147190

Patch by Josef Andersson <josef.andersson@fripost.org> on 2015-07-22

* sv.po:

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

5 years ago[EFL][WK2] EWK2ContextTestMultipleProcesses.ewk_context_network_process_model fails...
gyuyoung.kim@webkit.org [Wed, 22 Jul 2015 14:53:31 +0000 (14:53 +0000)]
[EFL][WK2] EWK2ContextTestMultipleProcesses.ewk_context_network_process_model fails to pass
https://bugs.webkit.org/show_bug.cgi?id=142967

Reviewed by Csaba Osztrogonác.

Though processIdentifier() can return 0 when a page is not closed, ewk_context_network_process_model has
not been considered process id can be 0. This patch adds a protection logic which doesn't test when process
id is 0 at the moment.

* UIProcess/API/efl/tests/test_ewk2_context.cpp:
(TEST_F):

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

5 years ago[GTK][EFL] Remove dead functions in LocalizedStrings
ryuan.choi@navercorp.com [Wed, 22 Jul 2015 13:20:40 +0000 (13:20 +0000)]
[GTK][EFL] Remove dead functions in LocalizedStrings
https://bugs.webkit.org/show_bug.cgi?id=147188

Reviewed by Csaba Osztrogonác.

* platform/efl/LocalizedStringsEfl.cpp:
(WebCore::contextMenuItemTagHideMediaControls):
(WebCore::contextMenuitemTagHideMediaControls): Fixed typo since r152117.
(WebCore::inactivePluginText): Deleted since r151530.
(WebCore::textTrackClosedCaptionsText): Deleted since r141864.
* platform/gtk/LocalizedStringsGtk.cpp:
(WebCore::inactivePluginText): Deleted since r151530.
(WebCore::textTrackClosedCaptionsText): Deleted since r141864.

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

5 years ago[check-webkit-style] .lut.h files shouldn't raise a sorting issue
calvaris@igalia.com [Wed, 22 Jul 2015 08:15:48 +0000 (08:15 +0000)]
[check-webkit-style] .lut.h files shouldn't raise a sorting issue
https://bugs.webkit.org/show_bug.cgi?id=147146

Reviewed by Darin Adler.

* Scripts/webkitpy/style/checkers/cpp.py:
(check_include_line): Avoid checking previous lines if it it is a lut.h include.
* Scripts/webkitpy/style/checkers/cpp_unittest.py:
(OrderOfIncludesTest.test_check_alphabetical_include_order): Added test.

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

5 years agoUnreviewed. Fix some warnings when generating GTK+ HTML API docs.
carlosgc@webkit.org [Wed, 22 Jul 2015 08:13:17 +0000 (08:13 +0000)]
Unreviewed. Fix some warnings when generating GTK+ HTML API docs.

* UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add
WebKitWebsiteDataManager and WebKitWebEditor.

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

5 years agoUnreviewed. Update OptionsGTK.cmake and NEWS for 2.9.4 release.
carlosgc@webkit.org [Wed, 22 Jul 2015 07:10:04 +0000 (07:10 +0000)]
Unreviewed. Update OptionsGTK.cmake and NEWS for 2.9.4 release.

.:

* Source/cmake/OptionsGTK.cmake: Bump version numbers.

Source/WebKit2:

* gtk/NEWS: Add release notes for 2.9.4.

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

5 years ago[CSS Selectors Level 4] Add #ifdefs to the new '>>' descendant combinator
benjamin@webkit.org [Wed, 22 Jul 2015 05:23:06 +0000 (05:23 +0000)]
[CSS Selectors Level 4] Add #ifdefs to the new '>>' descendant combinator
https://bugs.webkit.org/show_bug.cgi?id=147184

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-07-21
Reviewed by Anders Carlsson.

Now that '>>>' is dead, the combinator '>>' is at risk.

This patch #ifdef all that code with the other experimental
features from Level 4.

* css/CSSGrammar.y.in:
* css/CSSParserValues.cpp:
(WebCore::CSSParserSelector::appendTagHistory):
* css/CSSParserValues.h:
* css/CSSSelector.cpp:
(WebCore::CSSSelector::CSSSelector):
(WebCore::CSSSelector::selectorText):
* css/CSSSelector.h:
(WebCore::CSSSelector::CSSSelector):

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

5 years agoUpdate Mac test results for libxml2 v2.9.2.
ap@apple.com [Wed, 22 Jul 2015 03:51:12 +0000 (03:51 +0000)]
Update Mac test results for libxml2 v2.9.2.

These results will probably become cross-platform eventually, but for now it's just Mac.

* platform/mac-yosemite/fast/dom/adopt-attribute-crash-expected.txt: Copied from LayoutTests/fast/dom/adopt-attribute-crash-expected.txt.
* platform/mac-yosemite/fast/parser: Added.
* platform/mac-yosemite/fast/parser/xml-colon-entity-expected.txt: Copied from LayoutTests/fast/parser/xml-colon-entity-expected.txt.
* platform/mac-yosemite/fast/parser/xml-declaration-missing-ending-mark-expected.txt: Copied from LayoutTests/fast/parser/xml-declaration-missing-ending-mark-expected.txt.
* platform/mac-yosemite/fast/xsl: Added.
* platform/mac-yosemite/fast/xsl/xslt-extra-content-at-end-expected.png: Copied from LayoutTests/platform/mac/fast/xsl/xslt-extra-content-at-end-expected.png.
* platform/mac-yosemite/fast/xsl/xslt-extra-content-at-end-expected.txt: Copied from LayoutTests/platform/mac/fast/xsl/xslt-extra-content-at-end-expected.txt.
* platform/mac-yosemite/fast/xsl/xslt-missing-namespace-in-xslt-expected.png: Copied from LayoutTests/platform/mac/fast/xsl/xslt-missing-namespace-in-xslt-expected.png.
* platform/mac-yosemite/fast/xsl/xslt-missing-namespace-in-xslt-expected.txt: Copied from LayoutTests/platform/mac/fast/xsl/xslt-missing-namespace-in-xslt-expected.txt.
* platform/mac-yosemite/svg/custom: Added.
* platform/mac-yosemite/svg/custom/bug78807-expected.txt: Copied from LayoutTests/svg/custom/bug78807-expected.txt.
* platform/mac-yosemite/svg/custom/missing-xlink-expected.png: Copied from LayoutTests/platform/mac/svg/custom/missing-xlink-expected.png.
* platform/mac-yosemite/svg/custom/missing-xlink-expected.txt: Copied from LayoutTests/platform/mac/svg/custom/missing-xlink-expected.txt.
* platform/mac-yosemite/svg/custom/path-bad-data-expected.png: Copied from LayoutTests/platform/mac/svg/custom/path-bad-data-expected.png.
* platform/mac-yosemite/svg/custom/path-bad-data-expected.txt: Copied from LayoutTests/platform/mac/svg/custom/path-bad-data-expected.txt.
* platform/mac-yosemite/svg/custom/use-font-face-crash-expected.png: Copied from LayoutTests/platform/mac/svg/custom/use-font-face-crash-expected.png.
* platform/mac-yosemite/svg/custom/use-font-face-crash-expected.txt: Copied from LayoutTests/platform/mac/svg/custom/use-font-face-crash-expected.txt.
* platform/mac/fast/dom/adopt-attribute-crash-expected.txt: Added.
* platform/mac/fast/parser/xml-colon-entity-expected.txt: Added.
* platform/mac/fast/parser/xml-declaration-missing-ending-mark-expected.txt: Added.
* platform/mac/fast/xsl/xslt-extra-content-at-end-expected.png:
* platform/mac/fast/xsl/xslt-extra-content-at-end-expected.txt:
* platform/mac/fast/xsl/xslt-missing-namespace-in-xslt-expected.png:
* platform/mac/fast/xsl/xslt-missing-namespace-in-xslt-expected.txt:
* platform/mac/svg/custom/bug78807-expected.txt: Added.
* platform/mac/svg/custom/missing-xlink-expected.png:
* platform/mac/svg/custom/missing-xlink-expected.txt:
* platform/mac/svg/custom/path-bad-data-expected.png:
* platform/mac/svg/custom/path-bad-data-expected.txt:
* platform/mac/svg/custom/use-font-face-crash-expected.png:
* platform/mac/svg/custom/use-font-face-crash-expected.txt:

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

5 years agoWeb Inspector: console.log("%d", 0) or console.log("%d", "str") show nothing, expecte...
commit-queue@webkit.org [Wed, 22 Jul 2015 02:35:18 +0000 (02:35 +0000)]
Web Inspector: console.log("%d", 0) or console.log("%d", "str") show nothing, expected Number or NaN
https://bugs.webkit.org/show_bug.cgi?id=147163

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-21
Reviewed by Timothy Hatcher.

* UserInterface/Views/ConsoleMessageView.js:
(WebInspector.ConsoleMessageView.prototype._formatWithSubstitutionString.append):
When appending the result for a substitution formatter, don't check against a
falsey value, check against undefined. This will allow falsely values like
0 and NaN to be output as expected.

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

5 years agoWeb Inspector: [Mac] "Open Image In New Window" context menu item does nothing on...
commit-queue@webkit.org [Wed, 22 Jul 2015 01:49:40 +0000 (01:49 +0000)]
Web Inspector: [Mac] "Open Image In New Window" context menu item does nothing on an image
https://bugs.webkit.org/show_bug.cgi?id=147175

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-21
Reviewed by Timothy Hatcher.

Source/WebKit/mac:

* WebCoreSupport/WebInspectorClient.mm:
(-[WebInspectorWindowController webView:contextMenuItemsForElement:defaultMenuItems:]):
Remove default context menus that won't work in the inspector page.

Source/WebKit2:

* UIProcess/mac/WebInspectorProxyMac.mm:
(WebKit::getContextMenuFromProposedMenu):
(WebKit::WebInspectorProxy::platformCreateInspectorPage):
Remove default context menus that won't work in the inspector page.

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

5 years agoWeb Inspector: Node highlights are wrong when the page is zoomed
commit-queue@webkit.org [Wed, 22 Jul 2015 01:46:00 +0000 (01:46 +0000)]
Web Inspector: Node highlights are wrong when the page is zoomed
https://bugs.webkit.org/show_bug.cgi?id=147177

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-21
Reviewed by Simon Fraser.

* inspector/InspectorOverlay.cpp:
(WebCore::InspectorOverlay::update):
Remove scaling that appears to no longer be needed, it was double
scaling the overlay content and misplacing it in the process.

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

5 years agoDefault media controls use a serif font, which seems wrong
dino@apple.com [Wed, 22 Jul 2015 01:39:17 +0000 (01:39 +0000)]
Default media controls use a serif font, which seems wrong
https://bugs.webkit.org/show_bug.cgi?id=147179
<rdar://problem/21931728>

Reviewed by Simon Fraser.

The captions menu (and other text) should use a system style,
-webkit-small-control.

* Modules/mediacontrols/mediaControlsApple.css:
(::-webkit-media-controls):

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

5 years agoAdd newTarget accessor to JS constructor written in C++
utatane.tea@gmail.com [Wed, 22 Jul 2015 00:29:39 +0000 (00:29 +0000)]
Add newTarget accessor to JS constructor written in C++
https://bugs.webkit.org/show_bug.cgi?id=147160

Reviewed by Geoffrey Garen.

This patch adds `ExecState#newTarget()` which returns `new.target` defined in ECMA262 6th.
It enables some C++ constructors (like Intl.XXX constructors) to leverage this to complete
its implementation.

When the constructor is called, |this| in the arguments is used for storing new.target instead.
So by adding the accessor for |this|, JS constructor written in C++ can access new.target.

And at the same time, this patch extends the existing `construct` to accept new.target value.
It is corresponding to the spec's Construct abstract operation.

* interpreter/CallFrame.h:
(JSC::ExecState::newTarget):
* interpreter/Interpreter.cpp:
(JSC::Interpreter::executeConstruct):
* interpreter/Interpreter.h:
* runtime/ConstructData.cpp:
(JSC::construct):
* runtime/ConstructData.h:
(JSC::construct):

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

5 years agoExposed method to query device by UID
commit-queue@webkit.org [Wed, 22 Jul 2015 00:06:05 +0000 (00:06 +0000)]
Exposed method to query device by UID
https://bugs.webkit.org/show_bug.cgi?id=147117
<rdar://problem/21904678>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-21
Reviewed by Eric Carlson.

* platform/mediastream/mac/AVCaptureDeviceManager.h: Added method to
query device by UID
* platform/mediastream/mac/AVCaptureDeviceManager.mm: Ditto
(WebCore::AVCaptureDeviceManager::sourceWithUID): Ditto

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

5 years agoUnreviewed, fix a lot of tests. Need to initialize WTF threading sooner.
fpizlo@apple.com [Wed, 22 Jul 2015 00:01:46 +0000 (00:01 +0000)]
Unreviewed, fix a lot of tests. Need to initialize WTF threading sooner.

* jsc.cpp:
(main):

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

5 years ago[Content Extensions] Use a jump table when consecutive transitions have different...
benjamin@webkit.org [Tue, 21 Jul 2015 23:45:00 +0000 (23:45 +0000)]
[Content Extensions] Use a jump table when consecutive transitions have different targets
https://bugs.webkit.org/show_bug.cgi?id=147099

Reviewed by Alex Christensen.

Source/WebCore:

When handling consecutive single transitions, merge them into
a jump table instead of creating many individual CheckValue.

From local testing on x86_64, it reduces the bytecode size by about 5%
and improve the runtime by about 10%.

* contentextensions/DFABytecode.h:
(WebCore::ContentExtensions::instructionSizeWithArguments):
* contentextensions/DFABytecodeCompiler.cpp:
(WebCore::ContentExtensions::DFABytecodeCompiler::extractJumpTable):
(WebCore::ContentExtensions::DFABytecodeCompiler::transitions):
(WebCore::ContentExtensions::DFABytecodeCompiler::checkForJumpTableMaxBytecodeSize):
(WebCore::ContentExtensions::DFABytecodeCompiler::compileJumpTable):
(WebCore::ContentExtensions::DFABytecodeCompiler::nodeTransitionsMaxBytecodeSize):
(WebCore::ContentExtensions::DFABytecodeCompiler::compileNodeTransitions):
(WebCore::ContentExtensions::DFABytecodeCompiler::ranges): Deleted.
* contentextensions/DFABytecodeCompiler.h:
* contentextensions/DFABytecodeInterpreter.cpp:
(WebCore::ContentExtensions::DFABytecodeInterpreter::interpetJumpTable):
(WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
* contentextensions/DFABytecodeInterpreter.h:

Source/WebKit2:

* UIProcess/API/APIUserContentExtensionStore.h:

LayoutTests:

Add some primitive testing to make sure the code is covered.

* http/tests/contentextensions/test-jump-table-bytecode-generation-expected.txt: Added.
* http/tests/contentextensions/test-jump-table-bytecode-generation.html: Added.
* http/tests/contentextensions/test-jump-table-bytecode-generation.html.json: Added.

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

5 years agoFix the build following <https://trac.webkit.org/changeset/187129>
dbates@webkit.org [Tue, 21 Jul 2015 23:33:37 +0000 (23:33 +0000)]
Fix the build following <https://trac.webkit.org/changeset/187129>
(https://bugs.webkit.org/show_bug.cgi?id=147112)

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::reinstateNetworkProcessAssertionState): Guard implementation with PLATFORM(IOS)
since this logic is specific to the iOS port.

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

5 years agoRename the 'View' log channel to 'Printing'
simon.fraser@apple.com [Tue, 21 Jul 2015 23:31:48 +0000 (23:31 +0000)]
Rename the 'View' log channel to 'Printing'
https://bugs.webkit.org/show_bug.cgi?id=147172

Reviewed by Zalan Bujtas.

"View" was a terrible name for a log channel that was all about printing.
Sort the log channels.

* Platform/Logging.h:
* UIProcess/API/mac/WKView.mm:
(-[WKView drawRect:]):
(-[WKView printOperationWithPrintInfo:forFrame:]):
* UIProcess/mac/WKPrintingView.mm:
(-[WKPrintingView _preparePDFDataForPrintingOnSecondaryThread]):
(pageDidComputePageRects):
(-[WKPrintingView knowsPageRange:]):
(-[WKPrintingView drawRect:]):
(-[WKPrintingView rectForPage:]):
(-[WKPrintingView beginDocument]):
(-[WKPrintingView endDocument]):

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

5 years agoAdd a logging channel for Layout, remove the LiveConnect channel
simon.fraser@apple.com [Tue, 21 Jul 2015 23:31:44 +0000 (23:31 +0000)]
Add a logging channel for Layout, remove the LiveConnect channel
https://bugs.webkit.org/show_bug.cgi?id=147170

Reviewed by Zalan Bujtas.

Add a layout logging channel to WebCore, and remove the LiveConnect channel.

Source/WebCore:

* page/FrameView.cpp:
(WebCore::FrameView::adjustViewSize):
(WebCore::FrameView::forceLayoutParentViewIfNeeded):
(WebCore::FrameView::layout):
(WebCore::FrameView::performPostLayoutTasks):
(WebCore::FrameView::autoSizeIfEnabled):
* platform/Logging.h:

Source/WebKit/mac:

* Misc/WebKitLogging.h:
* Plugins/WebNetscapePluginPackage.mm:
(-[WebNetscapePluginPackage _tryLoad]): Deleted.

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

5 years agoStyleSheetContents::wrapperInsertRule() can create rules that overflow RuleData's...
benjamin@webkit.org [Tue, 21 Jul 2015 23:17:02 +0000 (23:17 +0000)]
StyleSheetContents::wrapperInsertRule() can create rules that overflow RuleData's selector index
https://bugs.webkit.org/show_bug.cgi?id=147144

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-07-21
Reviewed by Alex Christensen.

Source/WebCore:

RuleData identifies selectors by the index in a large array. The index only has 13 bits
so rules with more than 8192 selectors should be split.

One of the paths was not splitting the rule: StyleSheetContents::wrapperInsertRule().
When rules with too many selectors were added, the index would overflow and
some RuleData would point to selectors in the middle of selector chains. The resulting
behavior is random based on the selectors and the DOM.

We cannot easily fix that because the CSS OM API do not expect to create
several rules in response to calls to the API.
In this patch, I don't do anything fancy and just let the calls fail
if we cannot use the rules safely.

Content Extensions were also running into this problem. Large Selector lists are
pretty common, and ContentExtensionStyleSheet::addDisplayNoneSelector() was
overflowing the RuleData, creating broken page.

Unlike CSSOM, there is no problem with splitting rules coming from Content Extensions.
Instead of creating new APIs for that case, I rely on the parser to extend the StyleSheetContents.
That code already knows how to break rules correctly.

Tests: fast/css/insert-rule-overflow-rule-data.html
       http/tests/contentextensions/css-display-none-overflows-rule-data-1.html
       http/tests/contentextensions/css-display-none-overflows-rule-data-2.html

* contentextensions/ContentExtensionStyleSheet.cpp:
(WebCore::ContentExtensions::ContentExtensionStyleSheet::addDisplayNoneSelector):
* css/StyleSheetContents.cpp:
(WebCore::StyleSheetContents::wrapperInsertRule):

LayoutTests:

This bug was affecting two parts of WebKit:
-In CSSOM, StyleSheet.insertRule() could create bogus rules.
 The new test verifies that the call fails instead of creating undefined
 behaviors.
-In ContentExtensions, large selectors are now working correctly. The tests
 cover the case of a default stylesheet and an dynamic stylesheet.

* fast/css/insert-rule-overflow-rule-data-expected.txt: Added.
* fast/css/insert-rule-overflow-rule-data.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-1-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-1.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-1.html.json: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-2-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-2.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-2.html.json: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-3-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-3.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-3.html.json: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-4-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-4.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-4.html.json: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-5-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-5.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-5.html.json: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-6-expected.txt: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-6.html: Added.
* http/tests/contentextensions/css-display-none-overflows-rule-data-6.html.json: Added.

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

5 years ago[Win] Add needTouchEvents() stub to WebChromeClient.h for a successful build with...
commit-queue@webkit.org [Tue, 21 Jul 2015 23:14:43 +0000 (23:14 +0000)]
[Win] Add needTouchEvents() stub to WebChromeClient.h for a successful build with ENABLE_TOUCH_EVENTS=ON
https://bugs.webkit.org/show_bug.cgi?id=147141

Patch by Sungmann Cho <sungmann.cho@navercorp.com> on 2015-07-21
Reviewed by Darin Adler.

* WebCoreSupport/WebChromeClient.h:

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

5 years ago[iOS] Menu drop down such as on nike.com does not stay
zalan@apple.com [Tue, 21 Jul 2015 22:35:57 +0000 (22:35 +0000)]
[iOS] Menu drop down such as on nike.com does not stay
https://bugs.webkit.org/show_bug.cgi?id=147047
rdar://problem/21046961

Reviewed by Benjamin Poulain.

This is a workaround for unintended scrolling while scaling.
(Based on Benjamin Poulain's WIP patch for webkit.org/b/136904)

In certain cases when scaling would result in moving the scrollview (which would trigger
a scroll event on WebCore side), zoomRect is called instead of setZoomScale to ensure
that the scroll position stays intact.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _didCommitLayerTree:]):

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

5 years ago[iOS] Keyboard bold/italic/underline keys don't highlight after being
jhoneycutt@apple.com [Tue, 21 Jul 2015 22:34:27 +0000 (22:34 +0000)]
[iOS] Keyboard bold/italic/underline keys don't highlight after being
tapped to style a selection
https://bugs.webkit.org/show_bug.cgi?id=147164
<rdar://problem/21630806>

Reviewed by Ryosuke Niwa.

* editing/cocoa/EditorCocoa.mm:
(WebCore::Editor::styleForSelectionStart):
Use adjustedSelectionStartForStyleComputation(), which will ensure that
we're at the start of the selected node, not at the end of the node
before the selection.

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

5 years agoWTFCrash() in WebKit::WebProcess::networkConnection()
dbates@webkit.org [Tue, 21 Jul 2015 22:33:53 +0000 (22:33 +0000)]
WTFCrash() in WebKit::WebProcess::networkConnection()
https://bugs.webkit.org/show_bug.cgi?id=147112
<rdar://problem/18477459>

Reviewed by Gavin Barraclough.

Source/WebKit2:

Fixes an issue where a newly launched network process may be jetsam'd because it has not
taken a process assertion between the time it was launched and the time when a web process
makes use of it.

Initially a network process does not have a process assertion. A process assertion is taken
(if one has not been taken) for the network process when a process assertion is taken for at
least one web process. When the network process crashes a WebProcess may ultimately launch a
new network process in WebProcess::networkConnection(). The new network process may be jetsam'd
immediately when the system is under some measure pressure because it has a low jetsam priority,
0 (since it does not have a process assertion and higher priority implies that a process is less
likely to be jetsam'd). And the logic in WebProcess::networkConnection() explicitly calls
CRASH() if the newly launched network process crashes immediately. Towards preventing the newly
launched network process from being jetsam'd we should obtain a process assertion for it.

* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::WebProcessPool): Initialize m_didNetworkProcessCrash to false.
(WebKit::WebProcessPool::ensureNetworkProcess): If the network process crashed (m_didNetworkProcessCrash == true)
then tell each process in the pool to reinstate their network activity token for the new network process.
(WebKit::WebProcessPool::networkProcessCrashed): Set m_didNetworkProcessCrash to true when the
network process crashed.
* UIProcess/WebProcessPool.h:
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::reinstateNetworkProcessAssertionState): Added.
(WebKit::WebProcessProxy::didSetAssertionState): Add assert to ensure we never have both
a background- and foreground- activity token for the network process.
* UIProcess/WebProcessProxy.h:

Source/WTF:

Add explicit boolean conversion function and remove overload of operator! to support
checking whether an activity token is valid more directly than using the overloaded operator!.

* wtf/RefCounter.h:
(WTF::RefCounter::Token::operator bool): Added.
(WTF::RefCounter::Token::operator!): Deleted.

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

5 years agoPlacing video in fullscreen caused WebKit crash at WebCore::Range::textQuads
timothy_horton@apple.com [Tue, 21 Jul 2015 22:16:16 +0000 (22:16 +0000)]
Placing video in fullscreen caused WebKit crash at WebCore::Range::textQuads
https://bugs.webkit.org/show_bug.cgi?id=147166
<rdar://problem/21928558>

Reviewed by Simon Fraser.

* editing/FrameSelection.cpp:
(WebCore::FrameSelection::getClippedVisibleTextRectangles):
Check the Range, as always.

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

5 years ago[El Capitan] Test gardening
mmaxfield@apple.com [Tue, 21 Jul 2015 21:43:04 +0000 (21:43 +0000)]
[El Capitan] Test gardening
https://bugs.webkit.org/show_bug.cgi?id=147059

* platform/mac-yosemite/fast/dom/52776-expected.png: Copied from LayoutTests/platform/mac/fast/dom/52776-expected.png.
* platform/mac-yosemite/fast/text/complex-text-opacity-expected.png: Copied from LayoutTests/platform/mac/fast/text/complex-text-opacity-expected.png.
* platform/mac-yosemite/fast/text/font-weights-expected.png: Copied from LayoutTests/platform/mac/fast/text/font-weights-expected.png.
* platform/mac-yosemite/fast/text/indic-expected.png: Copied from LayoutTests/platform/mac/fast/text/indic-expected.png.
* platform/mac-yosemite/fast/text/indic-expected.txt: Copied from LayoutTests/platform/mac/fast/text/indic-expected.txt.
* platform/mac-yosemite/fast/text/international/bidi-AN-after-L-expected.png: Copied from LayoutTests/platform/mac/fast/text/international/bidi-AN-after-L-expected.png.
* platform/mac-yosemite/fast/text/international/bidi-mirror-he-ar-expected.png: Copied from LayoutTests/platform/mac/fast/text/international/bidi-mirror-he-ar-expected.png.
* platform/mac-yosemite/fast/text/international/bidi-neutral-directionality-paragraph-start-expected.png: Copied from LayoutTests/platform/mac/fast/text/international/bidi-neutral-directionality-paragraph-start-expected.png.
* platform/mac-yosemite/fast/text/international/bidi-neutral-run-expected.png: Copied from LayoutTests/platform/mac/fast/text/international/bidi-neutral-run-expected.png.
* platform/mac-yosemite/fast/text/international/danda-space-expected.png: Copied from LayoutTests/platform/mac/fast/text/international/danda-space-expected.png.
* platform/mac-yosemite/fast/text/international/danda-space-expected.txt: Copied from LayoutTests/platform/mac/fast/text/international/danda-space-expected.txt.
* platform/mac-yosemite/svg/W3C-SVG-1.1/text-intro-05-t-expected.png: Copied from LayoutTests/platform/mac/svg/W3C-SVG-1.1/text-intro-05-t-expected.png.
* platform/mac-yosemite/svg/text/text-intro-05-t-expected.png: Copied from LayoutTests/platform/mac/svg/text/text-intro-05-t-expected.png.
* platform/mac/fast/dom/52776-expected.png:
* platform/mac/fast/dom/52776-expected.txt:
* platform/mac/fast/text/arabic-times-new-roman-expected.png:
* platform/mac/fast/text/arabic-times-new-roman-expected.txt:
* platform/mac/fast/text/complex-text-opacity-expected.png:
* platform/mac/fast/text/complex-text-opacity-expected.txt:
* platform/mac/fast/text/font-weights-expected.png:
* platform/mac/fast/text/font-weights-expected.txt:
* platform/mac/fast/text/indic-expected.png:
* platform/mac/fast/text/indic-expected.txt:
* platform/mac/fast/text/international/bidi-AN-after-L-expected.png:
* platform/mac/fast/text/international/bidi-AN-after-L-expected.txt:
* platform/mac/fast/text/international/bidi-mirror-he-ar-expected.png:
* platform/mac/fast/text/international/bidi-mirror-he-ar-expected.txt:
* platform/mac/fast/text/international/bidi-neutral-directionality-paragraph-start-expected.png:
* platform/mac/fast/text/international/bidi-neutral-directionality-paragraph-start-expected.txt:
* platform/mac/fast/text/international/bidi-neutral-run-expected.png:
* platform/mac/fast/text/international/bidi-neutral-run-expected.txt:
* platform/mac/fast/text/international/danda-space-expected.png:
* platform/mac/fast/text/international/danda-space-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-05-t-expected.png:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-05-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/text-intro-05-t-expected.png:
* platform/mac/svg/W3C-SVG-1.1/text-intro-05-t-expected.txt:
* platform/mac/svg/text/text-intro-05-t-expected.png:
* platform/mac/svg/text/text-intro-05-t-expected.txt:

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

5 years agoFixed VM pool allocation should have a reserve for allocations that cannot fail
fpizlo@apple.com [Tue, 21 Jul 2015 21:41:30 +0000 (21:41 +0000)]
Fixed VM pool allocation should have a reserve for allocations that cannot fail
https://bugs.webkit.org/show_bug.cgi?id=147154
rdar://problem/21847618

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

This adds the notion of a JIT pool reserve fraction. Some fraction, currently 1/4, of
the JIT pool is reserved for allocations that cannot fail. It makes sense to make this
a fraction rather than a constant because each allocation that can fail may cause some
number of allocations that cannot fail (for example, the OSR exit thunks that we
compile when we exit from some CodeBlock cannot fail).

I've tested this by adding a test mode where we artificially limit the JIT pool size.
Prior to the fix, we had >20 failures. Now we have none.

* heap/GCLogging.cpp:
(WTF::printInternal): I needed a dump method on Options members when debugging this.
* heap/GCLogging.h:
* jit/ExecutableAllocator.h: Raise the ARM64 limit to 32MB because 16MB is cutting it too close.
* jit/ExecutableAllocatorFixedVMPool.cpp:
(JSC::FixedVMPoolExecutableAllocator::FixedVMPoolExecutableAllocator): Add the ability to artificially limit JIT pool size for testing.
(JSC::ExecutableAllocator::memoryPressureMultiplier): Implement the reserve when computing memory pressure for JIT tier-up heuristics.
(JSC::ExecutableAllocator::allocate): Implement the reserve when allocating can-fail things.
* jsc.cpp: Rewire some options parsing so that CommandLine happens before we create the JIT pool.
(main):
(CommandLine::parseArguments):
(jscmain):
* runtime/Options.cpp:
(JSC::OptionRange::dump): I needed a dump method on Options members when debugging this.
(JSC::Options::initialize): This can now be called more than once.
* runtime/Options.h:

Tools:

Add a new test mode where we artificially limit JIT memory to 50KB. If our JIT OOM
mitigations work, these should all pass. Prior to this patch there were >20 failures.

* Scripts/run-jsc-stress-tests:

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

5 years agoASSERT(m_suspendMessageCount >= 0) fails in ProcessThrottler::didCancelProcessSuspens...
dbates@webkit.org [Tue, 21 Jul 2015 21:39:58 +0000 (21:39 +0000)]
ASSERT(m_suspendMessageCount >= 0) fails in ProcessThrottler::didCancelProcessSuspension()
when WebContent process crashes; Network process may never voluntarily suspend
https://bugs.webkit.org/show_bug.cgi?id=147122
<rdar://problem/21906759>

Reviewed by Chris Dumez.

Fixes an issue where the network process may never voluntarily release its process assertion.

Currently the network process always sends both a ProcessReadyToSuspend and CancelPrepareToSuspend
message in response to receiving a PrepareToSuspend message and CancelPrepareToSuspend message,
respectively. The process throttler expects to receive either a ProcessReadyToSuspend message
or a CancelPrepareToSuspend message (and not both) in response to sending the message sequence
PrepareToSuspend, CancelPrepareToSuspend. When a process throttler receives both messages in
response to this sequence then its internal message count becomes imbalanced and it will
never release the process assertion it manages. One user interaction that can cause such an
imbalance, in the process throttler held by NetworkProcessProxy, is switching tabs.

* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::cancelPrepareToSuspend): Do not send message NetworkProcessProxy::DidCancelProcessSuspension.
* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::didCancelProcessSuspension): Deleted.
* UIProcess/Network/NetworkProcessProxy.h:
* UIProcess/Network/NetworkProcessProxy.messages.in: Remove message NetworkProcessProxy::DidCancelProcessSuspension.

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

5 years agoWeb Inspector: Total download size doesn't update soon after loading
commit-queue@webkit.org [Tue, 21 Jul 2015 21:23:26 +0000 (21:23 +0000)]
Web Inspector: Total download size doesn't update soon after loading
https://bugs.webkit.org/show_bug.cgi?id=147161

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-07-21
Reviewed by Timothy Hatcher.

* UserInterface/Models/DefaultDashboard.js:
(WebInspector.DefaultDashboard.prototype._mainResourceDidChange):
Previously autorecording would always have made us start capturing,
however we only autorecord if users are on the Timeline tab. Just
reset the time always, a navigation happened and start the timer.

(WebInspector.DefaultDashboard.prototype._resourceSizeDidChange):
Move to a better location within the file.

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

5 years agoMake sure to invalidate requests for user media after webpage reset
commit-queue@webkit.org [Tue, 21 Jul 2015 21:23:12 +0000 (21:23 +0000)]
Make sure to invalidate requests for user media after webpage reset
https://bugs.webkit.org/show_bug.cgi?id=147155
<rdar://problem/21924174>

Patch by Matthew Daiter <mdaiter@apple.com> on 2015-07-21
Reviewed by Brent Fulgham.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::resetState): Added user media reset

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