WebKit-https.git
8 years agoAdded bmalloc to the WebKit workspace.
mitz@apple.com [Tue, 8 Apr 2014 20:05:07 +0000 (20:05 +0000)]
Added bmalloc to the WebKit workspace.
https://bugs.webkit.org/show_bug.cgi?id=131362

Reviewed by Geoff Garen.

* WebKit.xcworkspace/contents.xcworkspacedata:
* WebKit.xcworkspace/xcshareddata/xcschemes/All Source (target WebProcess).xcscheme:
* WebKit.xcworkspace/xcshareddata/xcschemes/All Source.xcscheme:

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

8 years ago[GTK] Unreviewed GTK gardening.
commit-queue@webkit.org [Tue, 8 Apr 2014 20:04:39 +0000 (20:04 +0000)]
[GTK] Unreviewed GTK gardening.

Update text expectations for failing tests:
  accessibility/children-changed-sends-notification.html
  accessibility/notification-listeners.html
  fast/repaint/blend-mode-isolate-stacking-context.html
  fast/repaint/hidpi-absolute-positioned-element-wrong-cliprect-after-move.html

Rebaseline fast/multicol/client-rects-expected.txt after r165991

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

* platform/gtk/TestExpectations:
* platform/gtk/fast/multicol/client-rects-expected.txt:

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

8 years agoFail silently if the LLVM dylib isn't found
fpizlo@apple.com [Tue, 8 Apr 2014 20:03:41 +0000 (20:03 +0000)]
Fail silently if the LLVM dylib isn't found
https://bugs.webkit.org/show_bug.cgi?id=131385

Reviewed by Mark Hahnenberg.

* dfg/DFGPlan.cpp:
(JSC::DFG::Plan::compileInThreadImpl):
* llvm/InitializeLLVM.cpp:
(JSC::initializeLLVM):
* llvm/InitializeLLVM.h:
* llvm/InitializeLLVMPOSIX.cpp:
(JSC::initializeLLVMPOSIX):

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

8 years agoBuild bmalloc on iOS too
ggaren@apple.com [Tue, 8 Apr 2014 19:48:42 +0000 (19:48 +0000)]
Build bmalloc on iOS too
https://bugs.webkit.org/show_bug.cgi?id=131381

Reviewed by Andreas Kling.

.:

* Source/Makefile: Build it.

Tools:

* Scripts/build-webkit:

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

8 years agoFlagsChanged events are not delivered to input methods when using async text input
ap@apple.com [Tue, 8 Apr 2014 19:42:08 +0000 (19:42 +0000)]
FlagsChanged events are not delivered to input methods when using async text input
https://bugs.webkit.org/show_bug.cgi?id=131383

Reviewed by Anders Carlsson.

* UIProcess/API/mac/WKView.mm: (-[WKView _interpretKeyEvent:completionHandler:]):
The early return is no longer needed.

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

8 years agoRepatch should support setters and plant calls to them directly
fpizlo@apple.com [Tue, 8 Apr 2014 19:39:55 +0000 (19:39 +0000)]
Repatch should support setters and plant calls to them directly
https://bugs.webkit.org/show_bug.cgi?id=130750

Source/JavaScriptCore:

Reviewed by Geoffrey Garen.

All of the infrastructure was in place so this just enables setter optimization.

This is a 12x speed-up on setter microbenchmarks. This is a 1% speed-up on Octane.

* bytecode/PolymorphicPutByIdList.cpp:
(JSC::PutByIdAccess::visitWeak):
* bytecode/PolymorphicPutByIdList.h:
(JSC::PutByIdAccess::setter):
(JSC::PutByIdAccess::customSetter): Deleted.
* bytecode/PutByIdStatus.cpp:
(JSC::PutByIdStatus::computeForStubInfo):
* jit/Repatch.cpp:
(JSC::toString):
(JSC::kindFor):
(JSC::customFor):
(JSC::generateByIdStub):
(JSC::tryCachePutByID):
(JSC::tryBuildPutByIdList):
* runtime/JSObject.cpp:
(JSC::JSObject::put):
* runtime/Lookup.h:
(JSC::putEntry):
* runtime/PutPropertySlot.h:
(JSC::PutPropertySlot::setCacheableSetter):
(JSC::PutPropertySlot::isCacheableSetter):
(JSC::PutPropertySlot::isCacheableCustom):
(JSC::PutPropertySlot::setCacheableCustomProperty): Deleted.
(JSC::PutPropertySlot::isCacheableCustomProperty): Deleted.
* tests/stress/setter.js: Added.
(foo):

LayoutTests:

Reviewed by Geoffrey Garen.

* js/regress/script-tests/setter.js: Added.
* js/regress/setter-expected.txt: Added.
* js/regress/setter.html: Added.

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

8 years ago2014-04-08 Geoffrey Garen <ggaren@apple.com>
ggaren@apple.com [Tue, 8 Apr 2014 19:26:17 +0000 (19:26 +0000)]
2014-04-08  Geoffrey Garen  <ggaren@apple.com>

        Removed an unused file.

        Unreviewed.

        * bmalloc/AsyncTask.cpp: Removed.

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

8 years agoRefactor to make JSMainThreadExecState's constructor and destructor private.
mark.lam@apple.com [Tue, 8 Apr 2014 19:12:37 +0000 (19:12 +0000)]
Refactor to make JSMainThreadExecState's constructor and destructor private.
<https://webkit.org/b/131372>

Reviewed by Mark Hahnenberg.

This is in preparation for subsequent patches to ensure that we don't
exit the VM with an exception still pending.

No new tests required.  This is only a refactor of existing behavior.

* bindings/js/JSDOMGlobalObjectTask.cpp:
* bindings/js/JSMainThreadExecState.h:
(WebCore::JSMainThreadExecState::runTask):

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

8 years agoClean up old protocol JSON files to better match the latest
timothy@apple.com [Tue, 8 Apr 2014 19:07:06 +0000 (19:07 +0000)]
Clean up old protocol JSON files to better match the latest
https://bugs.webkit.org/show_bug.cgi?id=131308

Reviewed by Joseph Pecoraro.

* Versions/Inspector-iOS-6.0.json:
* Versions/Inspector-iOS-7.0.json:

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

8 years agoWebKit2 View Gestures (Swipe): Swipe-start hysteresis
timothy_horton@apple.com [Tue, 8 Apr 2014 19:00:26 +0000 (19:00 +0000)]
WebKit2 View Gestures (Swipe): Swipe-start hysteresis
https://bugs.webkit.org/show_bug.cgi?id=127393
<rdar://problem/15876822>

Reviewed by Anders Carlsson.

We shouldn't start a swipe immediately upon very small scrolls in the correct direction,
because we don't want to get the user trapped in a swipe when they want to scroll.

We'll accumulate the scroll deltas and wait until the user has scrolled at least 15px horizontally.
In addition, we'll drop the swipe completely if any event has a vertical delta equal to half (or more)
of the horizontal delta.

* UIProcess/mac/ViewGestureController.h:
* UIProcess/mac/ViewGestureControllerMac.mm:
(WebKit::ViewGestureController::ViewGestureController):
(WebKit::ViewGestureController::deltaIsSufficientToBeginSwipe):
(WebKit::ViewGestureController::handleScrollWheelEvent):
(WebKit::ViewGestureController::wheelEventWasNotHandledByWebCore):

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

8 years ago[Mac][WK2] Videos do not have access to session cookies
jer.noble@apple.com [Tue, 8 Apr 2014 18:26:51 +0000 (18:26 +0000)]
[Mac][WK2] Videos do not have access to session cookies
https://bugs.webkit.org/show_bug.cgi?id=129687

Reviewed by Eric Carlson.

Update the CookieStorageShim to track changes in underlying networking stack.

* Shared/mac/CookieStorageShim.mm:
(WebKit::CookieStorageShim::initialize):
(-[WKNSURLSessionLocal _getCookieHeadersForTask:completionHandler:]):

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

8 years ago[WK2][iOS] Consecutive videos in full screen display only black
jer.noble@apple.com [Tue, 8 Apr 2014 18:22:56 +0000 (18:22 +0000)]
[WK2][iOS] Consecutive videos in full screen display only black
https://bugs.webkit.org/show_bug.cgi?id=131316

Reviewed by Eric Carlson.

Update the MediaPlayer's full screen attributes whenever the underlying engine changes,
not just when the engine is initially created. Also, clear the videoLayer out of the
fullscreen layer when destroying the videoLayer.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer):

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

8 years ago[New Multicolumn] Child top margin sometimes ignored for column balancing
commit-queue@webkit.org [Tue, 8 Apr 2014 18:19:47 +0000 (18:19 +0000)]
[New Multicolumn] Child top margin sometimes ignored for column balancing
https://bugs.webkit.org/show_bug.cgi?id=122754

Patch by Morten Stenshorne <mstensho@opera.com> on 2014-04-08
Reviewed by David Hyatt.

Source/WebCore:

We need to set zero page logical height in LayoutState when column
height is unknown (when the columns haven't yet been
balanced). There's code that assumes that non-zero page height means
that page height is known. Lying about this makes the pagination code
believe that every top margin is adjacent to a column break, which
makes it eat and ignore all top margins.

This should be cleaned up, but it's easier to wait until the old
multicol code has been removed.

Tests: fast/multicol/break-in-scrollable.html
       fast/multicol/newmulticol/leading-and-trailing-margin.html
       fast/multicol/newmulticol/leading-margin.html

* rendering/LayoutState.cpp:
(WebCore::LayoutState::LayoutState):
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
* rendering/RenderFlowThread.h:
* rendering/RenderMultiColumnFlowThread.cpp:
(WebCore::RenderMultiColumnFlowThread::isPageLogicalHeightKnown):
* rendering/RenderMultiColumnFlowThread.h:

LayoutTests:

* fast/multicol/break-in-scrollable-expected.html: Added.
* fast/multicol/break-in-scrollable.html: Added.
* fast/multicol/newmulticol/leading-and-trailing-margin-expected.html: Added.
* fast/multicol/newmulticol/leading-and-trailing-margin.html: Added.
* fast/multicol/newmulticol/leading-margin-expected.html: Added.
* fast/multicol/newmulticol/leading-margin.html: Added.

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

8 years agoAllow elements to register for changes in page scale
dino@apple.com [Tue, 8 Apr 2014 18:06:11 +0000 (18:06 +0000)]
Allow elements to register for changes in page scale
https://bugs.webkit.org/show_bug.cgi?id=131319

Reviewed by Eric Carlson.

Some parts of WebCore need to react to changes in the page
scale factor, such as resizing when the user zooms. A followup
patch will enable this for media controls - this simply lays
the groundwork.

At the moment we only allow HTMLMediaElements to register, but if
necessary this could be expanded in the future.

* dom/Document.cpp: New methods to keep a list of HTMLMediaElements that
are interested in updates.
(WebCore::Document::registerForPageScaleFactorChangedCallbacks):
(WebCore::Document::unregisterForPageScaleFactorChangedCallbacks):
(WebCore::Document::pageScaleFactorChanged):
* dom/Document.h:
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::HTMLMediaElement):
(WebCore::HTMLMediaElement::registerWithDocument): Add ourselves to the
the document's pageScale callback.
(WebCore::HTMLMediaElement::unregisterWithDocument): Remove ourselves from the
the document's pageScale callback.
(WebCore::HTMLMediaElement::setMediaControlsDependOnPageScaleFactor): Add/remove ourselves to/from
the callback if necessary.
(WebCore::HTMLMediaElement::pageScaleFactorChanged): The callback function. Empty for now.
* html/HTMLMediaElement.h:
(WebCore::HTMLMediaElement::mediaControlsDependOnPageScaleFactor): Accessor.
* page/Page.cpp:
(WebCore::Page::setPageScaleFactor): Tell all documents that the user has zoomed.

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

8 years ago[Cocoa] Add a way to tell whether a WKWebProcessPlugInNodeHandle is a text-type HTML...
mitz@apple.com [Tue, 8 Apr 2014 18:04:59 +0000 (18:04 +0000)]
[Cocoa] Add a way to tell whether a WKWebProcessPlugInNodeHandle is a text-type HTML input element
https://bugs.webkit.org/show_bug.cgi?id=131374

Reviewed by Anders Carlsson.

* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.h:
* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.mm:
(-[WKWebProcessPlugInNodeHandle isTextField]): Added this getter. Calls
InjectedBundleNodeHandle::isTextField.
* WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
(WebKit::InjectedBundleNodeHandle::isTextField): Added. Uses
WebCore::HTMLInputElement::isText, which is consistent with what
WebChromeClient::focusedElementChanged uses to decide whether to call didFocusTextField.
* WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:

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

8 years ago[Cocoa] Add a _certificateChain property to WKWebProcessPlugInFrame
mitz@apple.com [Tue, 8 Apr 2014 17:45:50 +0000 (17:45 +0000)]
[Cocoa] Add a _certificateChain property to WKWebProcessPlugInFrame
https://bugs.webkit.org/show_bug.cgi?id=131370

Reviewed by Anders Carlsson.

* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:
(-[WKWebProcessPlugInFrame _certificateChain]): Added this getter, which uses the new
WebFrame::certificateInfo.
* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFramePrivate.h:
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::certificateInfo): Added this getter.
* WebProcess/WebPage/WebFrame.h:

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

8 years ago[Cocoa] Add a bundle form delegate method corresponding to textDidChangeInTextField
mitz@apple.com [Tue, 8 Apr 2014 17:36:39 +0000 (17:36 +0000)]
[Cocoa] Add a bundle form delegate method corresponding to textDidChangeInTextField
https://bugs.webkit.org/show_bug.cgi?id=131369

Reviewed by Anders Carlsson.

* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Declared
new delegate method.
* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
(-[WKWebProcessPlugInBrowserContextController _setFormDelegate:]): Added an override
of API::InjectedBundle::FormClient::textDidChangeInTextField which calls the new delegate
method.

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

8 years ago../WebKit/mac: WebKit part of [Cocoa] Add WKFormDelegate
mitz@apple.com [Tue, 8 Apr 2014 17:17:44 +0000 (17:17 +0000)]
../WebKit/mac: WebKit part of [Cocoa] Add WKFormDelegate
https://bugs.webkit.org/show_bug.cgi?id=131343

Reviewed by Anders Carlsson.

* MigrateHeaders.make: Added new WebKit2 headers to WEBKIT2_HEADERS.

../WebKit2: [Cocoa] Add WKFormDelegate
https://bugs.webkit.org/show_bug.cgi?id=131343

Reviewed by Anders Carlsson.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _formDelegate]): Added this accessor.
(-[WKWebView _setFormDelegate:]): Ditto.
* UIProcess/API/Cocoa/WKWebViewPrivate.h: Declared _formDelegate property.

* UIProcess/API/Cocoa/_WKFormDelegate.h: Added.

* UIProcess/API/Cocoa/_WKFormInputSession.h: Added.

* UIProcess/ios/WKContentView.h: Moved _webView ivar into the @interface…
* UIProcess/ios/WKContentView.mm: …from the @implementation.

* UIProcess/ios/WKContentViewInteraction.h: Added _formInputSession ivar and
formAccessoryView property.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKFormInputSession initWithContentView:userObject:]): Added.
(-[WKFormInputSession dealloc]): Added.
(-[WKFormInputSession userObject]): Added.
(-[WKFormInputSession isValid]): Added.
(-[WKFormInputSession accessoryViewCustomButtonTitle]): Added.
(-[WKFormInputSession setAccessoryViewCustomButtonTitle:]): Added.
(-[WKFormInputSession invalidate]): Added.
(-[WKContentView cleanupInteraction]): Invalidate and release the input session.
(-[WKContentView formAccessoryView]): Added this accessor.
(-[WKContentView _startAssistingNode:userObject:]): Create an input session and message the
form delegate.
(-[WKContentView _stopAssistingNode]): Invalidate and release the input session.

* WebKit2.xcodeproj/project.pbxproj: Added references to new files.

* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Added
comment.

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

8 years agoUnreviewed gardening: Prevent users from attempting
bfulgham@apple.com [Tue, 8 Apr 2014 16:47:12 +0000 (16:47 +0000)]
Unreviewed gardening: Prevent users from attempting
to build with known invalid cURL.

* Scripts/webkitdirs.pm:
(checkInstalledTools): Block build attempts with bad
Cygwin tool set.

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

8 years ago[WinCairo] Compile error in TextureMapper.h
commit-queue@webkit.org [Tue, 8 Apr 2014 16:40:04 +0000 (16:40 +0000)]
[WinCairo] Compile error in TextureMapper.h
https://bugs.webkit.org/show_bug.cgi?id=131360

Patch by peavo@outlook.com <peavo@outlook.com> on 2014-04-08
Reviewed by Brent Fulgham.

The TextureMapper class has pure virtual methods, and cannot be instantiated.

* platform/graphics/texmap/TextureMapper.h:
(WebCore::TextureMapper::platformCreateAccelerated):

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

8 years ago[WebVTT] Begin Enabling W3C VTT Tests
bfulgham@apple.com [Tue, 8 Apr 2014 16:26:24 +0000 (16:26 +0000)]
[WebVTT] Begin Enabling W3C VTT Tests
https://bugs.webkit.org/show_bug.cgi?id=131345

Reviewed by Darin Adler.

Move a number of tests out of 'opera' into a new 'w3c' folder.

* media/track/opera/interfaces/HTMLElement/HTMLMediaElement/addTextTrack-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLMediaElement/addTextTrack.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLMediaElement/textTracks-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLMediaElement/textTracks.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/default-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/default.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/label-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/label.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/readyState-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/readyState.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/srclang-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/srclang.html: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/track-expected.txt: Removed.
* media/track/opera/interfaces/HTMLElement/HTMLTrackElement/track.html: Removed.
* media/track/opera/interfaces/TextTrack/addCue-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/addCue.html: Removed.
* media/track/opera/interfaces/TextTrack/constants-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/constants.html: Removed.
* media/track/opera/interfaces/TextTrack/cues-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/cues.html: Removed.
* media/track/opera/interfaces/TextTrack/kind-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/kind.html: Removed.
* media/track/opera/interfaces/TextTrack/label-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/label.html: Removed.
* media/track/opera/interfaces/TextTrack/language-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/language.html: Removed.
* media/track/opera/interfaces/TextTrack/mode-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/mode.html: Removed.
* media/track/opera/interfaces/TextTrack/oncuechange-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/oncuechange.html: Removed.
* media/track/opera/interfaces/TextTrack/removeCue-expected.txt: Removed.
* media/track/opera/interfaces/TextTrack/removeCue.html: Removed.
* media/track/opera/interfaces/TextTrackCue/align-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/align.html: Removed.
* media/track/opera/interfaces/TextTrackCue/endTime-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/endTime.html: Removed.
* media/track/opera/interfaces/TextTrackCue/id-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/id.html: Removed.
* media/track/opera/interfaces/TextTrackCue/pauseOnExit-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/pauseOnExit.html: Removed.
* media/track/opera/interfaces/TextTrackCue/startTime-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/startTime.html: Removed.
* media/track/opera/interfaces/TextTrackCue/track-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCue/track.html: Removed.
* media/track/opera/interfaces/TextTrackCueList/getCueById-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCueList/getCueById.html: Removed.
* media/track/opera/interfaces/TextTrackCueList/length-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackCueList/length.html: Removed.
* media/track/opera/interfaces/TextTrackList/length-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackList/length.html: Removed.
* media/track/opera/interfaces/TextTrackList/onaddtrack-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackList/onaddtrack.html: Removed.
* media/track/opera/interfaces/TextTrackList/onremovetrack-expected.txt: Removed.
* media/track/opera/interfaces/TextTrackList/onremovetrack.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/2_tracks-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/2_tracks.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_end-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_end.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_50-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_50.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_gt_50-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_gt_50.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50_size_gt_maximum_size-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50_size_gt_maximum_size.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_start-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/align_start.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/audio_has_no_subtitles-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/audio_has_no_subtitles.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/basic-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/basic.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/decode_escaped_entities-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/decode_escaped_entities.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size_while_paused-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size_while_paused.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text_while_paused-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text_while_paused.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_remove_cue_while_paused-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/dom_override_remove_cue_while_paused.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/media/background.gif: Removed.
* media/track/opera/track/webvtt/rendering/reftest/media/white.mp4: Removed.
* media/track/opera/track/webvtt/rendering/reftest/media/white.webm: Removed.
* media/track/opera/track/webvtt/rendering/reftest/one_line_cue_plus_wrapped_cue-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/one_line_cue_plus_wrapped_cue.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/size_50-ref.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/size_50.html: Removed.
* media/track/opera/track/webvtt/rendering/reftest/support/2_cues_overlapping_completely_move_up.vtt: Removed.
* media/track/opera/track/webvtt/rendering/reftest/support/align_end_long.vtt: Removed.
* media/track/opera/track/webvtt/rendering/reftest/support/foo.vtt: Removed.
* media/track/opera/track/webvtt/rendering/reftest/support/refTestWait.js: Removed.
* media/track/w3c: Added.
* media/track/w3c/interfaces: Added.
* media/track/w3c/interfaces/HTMLMediaElement: Added.
* media/track/w3c/interfaces/HTMLMediaElement/addTextTrack-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLMediaElement/addTextTrack-expected.txt.
* media/track/w3c/interfaces/HTMLMediaElement/addTextTrack.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLMediaElement/addTextTrack.html.
* media/track/w3c/interfaces/HTMLMediaElement/textTracks-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLMediaElement/textTracks-expected.txt.
* media/track/w3c/interfaces/HTMLMediaElement/textTracks.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLMediaElement/textTracks.html.
* media/track/w3c/interfaces/HTMLTrackElement: Added.
* media/track/w3c/interfaces/HTMLTrackElement/default-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/default-expected.txt.
* media/track/w3c/interfaces/HTMLTrackElement/default.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/default.html.
* media/track/w3c/interfaces/HTMLTrackElement/label-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/label-expected.txt.
* media/track/w3c/interfaces/HTMLTrackElement/label.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/label.html.
* media/track/w3c/interfaces/HTMLTrackElement/readyState-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/readyState-expected.txt.
* media/track/w3c/interfaces/HTMLTrackElement/readyState.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/readyState.html.
* media/track/w3c/interfaces/HTMLTrackElement/srclang-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/srclang-expected.txt.
* media/track/w3c/interfaces/HTMLTrackElement/srclang.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/srclang.html.
* media/track/w3c/interfaces/HTMLTrackElement/track-expected.txt: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/track-expected.txt.
* media/track/w3c/interfaces/HTMLTrackElement/track.html: Copied from media/track/opera/interfaces/HTMLElement/HTMLTrackElement/track.html.
* media/track/w3c/interfaces/TextTrack: Added.
* media/track/w3c/interfaces/TextTrack/addCue-expected.txt: Copied from media/track/opera/interfaces/TextTrack/addCue-expected.txt.
* media/track/w3c/interfaces/TextTrack/addCue.html: Copied from media/track/opera/interfaces/TextTrack/addCue.html.
* media/track/w3c/interfaces/TextTrack/constants-expected.txt: Copied from media/track/opera/interfaces/TextTrack/constants-expected.txt.
* media/track/w3c/interfaces/TextTrack/constants.html: Copied from media/track/opera/interfaces/TextTrack/constants.html.
* media/track/w3c/interfaces/TextTrack/cues-expected.txt: Copied from media/track/opera/interfaces/TextTrack/cues-expected.txt.
* media/track/w3c/interfaces/TextTrack/cues.html: Copied from media/track/opera/interfaces/TextTrack/cues.html.
* media/track/w3c/interfaces/TextTrack/kind-expected.txt: Copied from media/track/opera/interfaces/TextTrack/kind-expected.txt.
* media/track/w3c/interfaces/TextTrack/kind.html: Copied from media/track/opera/interfaces/TextTrack/kind.html.
* media/track/w3c/interfaces/TextTrack/label-expected.txt: Copied from media/track/opera/interfaces/TextTrack/label-expected.txt.
* media/track/w3c/interfaces/TextTrack/label.html: Copied from media/track/opera/interfaces/TextTrack/label.html.
* media/track/w3c/interfaces/TextTrack/language-expected.txt: Copied from media/track/opera/interfaces/TextTrack/language-expected.txt.
* media/track/w3c/interfaces/TextTrack/language.html: Copied from media/track/opera/interfaces/TextTrack/language.html.
* media/track/w3c/interfaces/TextTrack/mode-expected.txt: Copied from media/track/opera/interfaces/TextTrack/mode-expected.txt.
* media/track/w3c/interfaces/TextTrack/mode.html: Copied from media/track/opera/interfaces/TextTrack/mode.html.
* media/track/w3c/interfaces/TextTrack/oncuechange-expected.txt: Copied from media/track/opera/interfaces/TextTrack/oncuechange-expected.txt.
* media/track/w3c/interfaces/TextTrack/oncuechange.html: Copied from media/track/opera/interfaces/TextTrack/oncuechange.html.
* media/track/w3c/interfaces/TextTrack/removeCue-expected.txt: Copied from media/track/opera/interfaces/TextTrack/removeCue-expected.txt.
* media/track/w3c/interfaces/TextTrack/removeCue.html: Copied from media/track/opera/interfaces/TextTrack/removeCue.html.
* media/track/w3c/interfaces/TextTrackCue: Added.
* media/track/w3c/interfaces/TextTrackCue/align-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/align-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/align.html: Copied from media/track/opera/interfaces/TextTrackCue/align.html.
* media/track/w3c/interfaces/TextTrackCue/endTime-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/endTime-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/endTime.html: Copied from media/track/opera/interfaces/TextTrackCue/endTime.html.
* media/track/w3c/interfaces/TextTrackCue/id-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/id-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/id.html: Copied from media/track/opera/interfaces/TextTrackCue/id.html.
* media/track/w3c/interfaces/TextTrackCue/pauseOnExit-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/pauseOnExit-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/pauseOnExit.html: Copied from media/track/opera/interfaces/TextTrackCue/pauseOnExit.html.
* media/track/w3c/interfaces/TextTrackCue/startTime-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/startTime-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/startTime.html: Copied from media/track/opera/interfaces/TextTrackCue/startTime.html.
* media/track/w3c/interfaces/TextTrackCue/track-expected.txt: Copied from media/track/opera/interfaces/TextTrackCue/track-expected.txt.
* media/track/w3c/interfaces/TextTrackCue/track.html: Copied from media/track/opera/interfaces/TextTrackCue/track.html.
* media/track/w3c/interfaces/TextTrackCueList: Added.
* media/track/w3c/interfaces/TextTrackCueList/getCueById-expected.txt: Copied from media/track/opera/interfaces/TextTrackCueList/getCueById-expected.txt.
* media/track/w3c/interfaces/TextTrackCueList/getCueById.html: Copied from media/track/opera/interfaces/TextTrackCueList/getCueById.html.
* media/track/w3c/interfaces/TextTrackCueList/length-expected.txt: Copied from media/track/opera/interfaces/TextTrackCueList/length-expected.txt.
* media/track/w3c/interfaces/TextTrackCueList/length.html: Copied from media/track/opera/interfaces/TextTrackCueList/length.html.
* media/track/w3c/interfaces/TextTrackList: Added.
* media/track/w3c/interfaces/TextTrackList/length-expected.txt: Copied from media/track/opera/interfaces/TextTrackList/length-expected.txt.
* media/track/w3c/interfaces/TextTrackList/length.html: Copied from media/track/opera/interfaces/TextTrackList/length.html.
* media/track/w3c/interfaces/TextTrackList/onaddtrack-expected.txt: Copied from media/track/opera/interfaces/TextTrackList/onaddtrack-expected.txt.
* media/track/w3c/interfaces/TextTrackList/onaddtrack.html: Copied from media/track/opera/interfaces/TextTrackList/onaddtrack.html.
* media/track/w3c/interfaces/TextTrackList/onremovetrack-expected.txt: Copied from media/track/opera/interfaces/TextTrackList/onremovetrack-expected.txt.
* media/track/w3c/interfaces/TextTrackList/onremovetrack.html: Copied from media/track/opera/interfaces/TextTrackList/onremovetrack.html.
* media/track/w3c/track: Added.
* media/track/w3c/track/webvtt: Added.
* media/track/w3c/track/webvtt/2_tracks-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/2_tracks-ref.html.
* media/track/w3c/track/webvtt/2_tracks.html: Copied from media/track/opera/track/webvtt/rendering/reftest/2_tracks.html.
* media/track/w3c/track/webvtt/align_end-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_end-ref.html.
* media/track/w3c/track/webvtt/align_end.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_end.html.
* media/track/w3c/track/webvtt/align_middle-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle-ref.html.
* media/track/w3c/track/webvtt/align_middle.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle.html.
* media/track/w3c/track/webvtt/align_middle_position_50-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_50-ref.html.
* media/track/w3c/track/webvtt/align_middle_position_50.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_50.html.
* media/track/w3c/track/webvtt/align_middle_position_gt_50-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_gt_50-ref.html.
* media/track/w3c/track/webvtt/align_middle_position_gt_50.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_gt_50.html.
* media/track/w3c/track/webvtt/align_middle_position_lt_50-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50-ref.html.
* media/track/w3c/track/webvtt/align_middle_position_lt_50.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50.html.
* media/track/w3c/track/webvtt/align_middle_position_lt_50_size_gt_maximum_size-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50_size_gt_maximum_size-ref.html.
* media/track/w3c/track/webvtt/align_middle_position_lt_50_size_gt_maximum_size.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_middle_position_lt_50_size_gt_maximum_size.html.
* media/track/w3c/track/webvtt/align_start-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_start-ref.html.
* media/track/w3c/track/webvtt/align_start.html: Copied from media/track/opera/track/webvtt/rendering/reftest/align_start.html.
* media/track/w3c/track/webvtt/audio_has_no_subtitles-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/audio_has_no_subtitles-ref.html.
* media/track/w3c/track/webvtt/audio_has_no_subtitles.html: Copied from media/track/opera/track/webvtt/rendering/reftest/audio_has_no_subtitles.html.
* media/track/w3c/track/webvtt/background.gif: Copied from media/track/opera/track/webvtt/rendering/reftest/media/background.gif.
* media/track/w3c/track/webvtt/basic-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/basic-ref.html.
* media/track/w3c/track/webvtt/basic.html: Copied from media/track/opera/track/webvtt/rendering/reftest/basic.html.
* media/track/w3c/track/webvtt/decode_escaped_entities-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/decode_escaped_entities-ref.html.
* media/track/w3c/track/webvtt/decode_escaped_entities.html: Copied from media/track/opera/track/webvtt/rendering/reftest/decode_escaped_entities.html.
* media/track/w3c/track/webvtt/dom_override_cue_align_position_line_size-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size-ref.html.
* media/track/w3c/track/webvtt/dom_override_cue_align_position_line_size.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size.html.
* media/track/w3c/track/webvtt/dom_override_cue_align_position_line_size_while_paused-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size_while_paused-ref.html.
* media/track/w3c/track/webvtt/dom_override_cue_align_position_line_size_while_paused.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_align_position_line_size_while_paused.html.
* media/track/w3c/track/webvtt/dom_override_cue_text-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text-ref.html.
* media/track/w3c/track/webvtt/dom_override_cue_text.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text.html.
* media/track/w3c/track/webvtt/dom_override_cue_text_while_paused-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text_while_paused-ref.html.
* media/track/w3c/track/webvtt/dom_override_cue_text_while_paused.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_cue_text_while_paused.html.
* media/track/w3c/track/webvtt/dom_override_remove_cue_while_paused-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_remove_cue_while_paused-ref.html.
* media/track/w3c/track/webvtt/dom_override_remove_cue_while_paused.html: Copied from media/track/opera/track/webvtt/rendering/reftest/dom_override_remove_cue_while_paused.html.
* media/track/w3c/track/webvtt/media: Added.
* media/track/w3c/track/webvtt/media/white.mp4: Copied from media/track/opera/track/webvtt/rendering/reftest/media/white.mp4.
* media/track/w3c/track/webvtt/media/white.webm: Copied from media/track/opera/track/webvtt/rendering/reftest/media/white.webm.
* media/track/w3c/track/webvtt/one_line_cue_plus_wrapped_cue-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/one_line_cue_plus_wrapped_cue-ref.html.
* media/track/w3c/track/webvtt/one_line_cue_plus_wrapped_cue.html: Copied from media/track/opera/track/webvtt/rendering/reftest/one_line_cue_plus_wrapped_cue.html.
* media/track/w3c/track/webvtt/size_50-expected.html: Copied from media/track/opera/track/webvtt/rendering/reftest/size_50-ref.html.
* media/track/w3c/track/webvtt/size_50.html: Copied from media/track/opera/track/webvtt/rendering/reftest/size_50.html.
* media/track/w3c/track/webvtt/support: Added.
* media/track/w3c/track/webvtt/support/2_cues_overlapping_completely_move_up.vtt: Copied from media/track/opera/track/webvtt/rendering/reftest/support/2_cues_overlapping_completely_move_up.vtt.
* media/track/w3c/track/webvtt/support/align_end_long.vtt: Copied from media/track/opera/track/webvtt/rendering/reftest/support/align_end_long.vtt.
* media/track/w3c/track/webvtt/support/foo.vtt: Copied from media/track/opera/track/webvtt/rendering/reftest/support/foo.vtt.
* media/track/w3c/track/webvtt/support/refTestWait.js: Copied from media/track/opera/track/webvtt/rendering/reftest/support/refTestWait.js.
* platform/eft/TestExpectations: Skip w3c tests.
* platform/gtk/TestExpectations: Skip w3c tests.

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

8 years agoSubpixel rendering: Slow paint path for inlines should snap to device pixels.
zalan@apple.com [Tue, 8 Apr 2014 16:19:56 +0000 (16:19 +0000)]
Subpixel rendering: Slow paint path for inlines should snap to device pixels.
https://bugs.webkit.org/show_bug.cgi?id=131259

Reviewed by Simon Fraser.

InlineTextBox::paint needs to round to the same device pixel position as SimpleLineLayout does.

Source/WebCore:

Test: fast/inline/hidpi-slow-path-text-on-subpixel-position.html

* rendering/InlineTextBox.cpp:
(WebCore::InlineTextBox::paint):
* rendering/TextPainter.h: Cleanup. No reason to have them as references here.

LayoutTests:

* fast/inline/hidpi-slow-path-text-on-subpixel-position-expected.html: Added.
* fast/inline/hidpi-slow-path-text-on-subpixel-position.html: Added.

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

8 years agoFallback to default storage session when there isn't a valid session ID
dbates@webkit.org [Tue, 8 Apr 2014 16:09:29 +0000 (16:09 +0000)]
Fallback to default storage session when there isn't a valid session ID
https://bugs.webkit.org/show_bug.cgi?id=131326
<rdar://problem/16231679>

Reviewed by Alexey Proskuryakov.

Fixes and issue where we may use the wrong storage session after disabling
a private browsing session.

Currently WebKit1 and WebKit2 without NetworkProcess assume that there
is always a non-null private browsing storage session so long as the page
has a non-default session ID. Instead we should only use the private browsing
storage session when it's non-null and the page has a non-default session ID;
otherwise, we should use the default storage session. This change will make
the behavior in WebKit1 and WebKit2 without NetworkProcess consistent with
the behavior in WebKit2 with NetworkProcess.

Source/WebKit/mac:

* WebCoreSupport/WebFrameNetworkingContext.mm:
(WebFrameNetworkingContext::storageSession):

Source/WebKit2:

* WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
(WebKit::WebFrameNetworkingContext::storageSession):

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

8 years agoKeep 'webkitClosedCaptionsVisible' API in sync with captions display preferences
bfulgham@apple.com [Tue, 8 Apr 2014 16:01:38 +0000 (16:01 +0000)]
Keep 'webkitClosedCaptionsVisible' API in sync with captions display preferences
https://bugs.webkit.org/show_bug.cgi?id=131344

Reviewed by Eric Carlson.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::configureTextTrackGroup) If we decide that captions should
be active (due to user preferences) make sure the 'webkitClosedCaptionsVisible' state
is turned on.

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

8 years agoSubpixel rendering: Paint the filter effect result image on device pixel position.
zalan@apple.com [Tue, 8 Apr 2014 14:52:33 +0000 (14:52 +0000)]
Subpixel rendering: Paint the filter effect result image on device pixel position.
https://bugs.webkit.org/show_bug.cgi?id=131255

Reviewed by Simon Fraser.

This patch moves filter effect images from integral to device pixel position. However,
result images are still integral based.

Source/WebCore:

Test: css3/filters/hidpi-filter-is-on-subpixel-position.html

* rendering/FilterEffectRenderer.cpp:
(WebCore::FilterEffectRendererHelper::applyFilterEffect):

LayoutTests:

* css3/filters/hidpi-filter-is-on-subpixel-position-expected.html: Added.
* css3/filters/hidpi-filter-is-on-subpixel-position.html: Added.

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

8 years agoSubpixel rendering: Make border images device pixel aware.
zalan@apple.com [Tue, 8 Apr 2014 14:50:38 +0000 (14:50 +0000)]
Subpixel rendering: Make border images device pixel aware.
https://bugs.webkit.org/show_bug.cgi?id=131209

Reviewed by Simon Fraser.

Snap border-image size and position to device pixels. It works both on generated and bitmap images.

Source/WebCore:

Test: fast/borders/hidpi-border-image-gradient-on-subpixels.html

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

LayoutTests:

* fast/borders/hidpi-border-image-gradient-on-subpixels-expected.html: Added.
* fast/borders/hidpi-border-image-gradient-on-subpixels.html: Added.

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

8 years ago[SOUP] Control cookie management according ResourceRequest.allowCookies()
commit-queue@webkit.org [Tue, 8 Apr 2014 12:09:51 +0000 (12:09 +0000)]
[SOUP] Control cookie management according ResourceRequest.allowCookies()
https://bugs.webkit.org/show_bug.cgi?id=131026

Patch by Youenn Fablet <youenn.fablet@crf.canon.fr> on 2014-04-08
Reviewed by Sergio Villar Senin.

Source/WebCore:

Added per soup-message disabling of cookie jar manager when related ResourceRequest does not allow cookies (e.g. some cross-origin requests).

Patch is covered by unskipped test http/tests/xmlhttprequest/cross-origin-cookie-storage.html.

* platform/network/soup/ResourceRequestSoup.cpp:
(WebCore::ResourceRequest::updateSoupMessageMembers): Added disabling of cookie jar manager if cookies are not allowed.

Source/WebKit2:

Added setting of accept cookies policy for the current soup network session cookie jar and all tracked sessions.
Moved the implementation of cookie policy setting from WebCookieManager to WebFrameNetworkingContext.

* WebProcess/Cookies/soup/WebCookieManagerSoup.cpp:
(WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy): Moved implementation to WebCookieManager::platformSetHTTPCookieAcceptPolicy.
* WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
(WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts): Moved implementation from WebCookieManager::platformSetHTTPCookieAcceptPolicy and set the cookie jar accept policy to the cookie jars of all sessions in addition to the default cookie jar.
* WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h: Added method prototype.

LayoutTests:

* platform/efl/TestExpectations: Unskipped test http/tests/xmlhttprequest/cross-origin-cookie-storage.html.
* platform/gtk/TestExpectations: Ditto.

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

8 years ago[CSS Grid Layout] Handle min/max height in the grid element
svillar@igalia.com [Tue, 8 Apr 2014 12:05:33 +0000 (12:05 +0000)]
[CSS Grid Layout] Handle min/max height in the grid element
https://bugs.webkit.org/show_bug.cgi?id=131302

Reviewed by Darin Adler.

Source/WebCore:

Removed a FIXME in the code as we're already handling min/max
height in the code. Added a couple of test cases to improve the
test coverage.

Merged from Blink r161876 by <jchaffraix@chromium.org>

Tests: fast/css-grid-layout/flex-content-sized-columns-resize.html
       fast/css-grid-layout/grid-element-min-max-height.html

* rendering/RenderGrid.cpp:
(WebCore::RenderGrid::layoutGridItems):

LayoutTests:

Added test coverage for min/max height handling in the grid
item. Also added other test to cover a blind spot in our testing,
resizing of content sized columns with flexible breadths.

Merged from Blink r161876 by <jchaffraix@chromium.org> and r166914 by <rego@igalia.com>.

* fast/css-grid-layout/flex-content-sized-columns-resize-expected.html: Added.
* fast/css-grid-layout/flex-content-sized-columns-resize.html: Added.
* fast/css-grid-layout/grid-element-min-max-height-expected.txt: Added.
* fast/css-grid-layout/grid-element-min-max-height.html: Added.

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

8 years ago[CSSRegions] Remove unused RenderBox::clearRenderBoxRegionInfo
mihnea@adobe.com [Tue, 8 Apr 2014 09:21:44 +0000 (09:21 +0000)]
[CSSRegions] Remove unused RenderBox::clearRenderBoxRegionInfo
https://bugs.webkit.org/show_bug.cgi?id=131352

Reviewed by Andrei Bucur.

No new tests, code clean-up.

* rendering/RenderBox.cpp:
(WebCore::RenderBox::clearRenderBoxRegionInfo): Deleted.
* rendering/RenderBox.h:

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

8 years agoBuildfix after r166917
commit-queue@webkit.org [Tue, 8 Apr 2014 09:15:06 +0000 (09:15 +0000)]
Buildfix after r166917
https://bugs.webkit.org/show_bug.cgi?id=131351

Patch by Zsolt Borbely <zsborbely.u-szeged@partner.samsung.com> on 2014-04-08
Reviewed by Andrei Bucur.

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::accessibleNameForNode):

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

8 years agoFix assertions triggered by CSS calc changes in r166860
darin@apple.com [Tue, 8 Apr 2014 08:58:43 +0000 (08:58 +0000)]
Fix assertions triggered by CSS calc changes in r166860
https://bugs.webkit.org/show_bug.cgi?id=131346

Reviewed by Andrei Bucur.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::getBorderRadiusCornerValues): Use isPercentNotCalculated() instead of
type() == Percent; no behavior change.
(WebCore::getBorderRadiusCornerValue): Ditto.
(WebCore::lineHeightFromStyle): Use isPercentNotCalculated() before code
that calls percent(), which won't work for a calculated length.

* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyBorderRadius::applyValue): Use isNegative and isZero rather
than calling value() unconditionally. Should make calculated values work better.

* html/HTMLPlugInImageElement.cpp:
(WebCore::is100Percent): Use isPercentNotCalculated() before code
that calls percent(), which won't work for a calculated length.

* platform/Length.cpp:
(WebCore::CalculationValueMap::deref): Use adoptRef here instead of calling deref
immediately, so the deref will happen after calling remove. This makes the code
work properly even if it's reentered inside the calculation value's destructor.

* platform/Length.h:
(WebCore::Length::percent): Change assert to isPercentNotCalculated, since the
value function this calls only works for non-calculated values anyway.
(WebCore::Length::isPercentNotCalculated): Added.
(WebCore::Length::isPercent): Changed to call isPercentNotCalculated.
(WebCore::Length::isSpecified): Changed to call isPercent.

* platform/graphics/transforms/TranslateTransformOperation.h:
(WebCore::TranslateTransformOperation::apply): Use isPercentNotCalculated()
instead of type() == Percent; no behavior change.

* rendering/AutoTableLayout.cpp:
(WebCore::AutoTableLayout::recalcColumn): Use isPercentNotCalculated()
before code that calls value() or percent(), which won't work for a calculated length.
(WebCore::AutoTableLayout::computeIntrinsicLogicalWidths): Ditto.
(WebCore::AutoTableLayout::calcEffectiveLogicalWidth): Ditto.
(WebCore::AutoTableLayout::layout): Ditto.
* rendering/FixedTableLayout.cpp:
(WebCore::FixedTableLayout::layout): Ditto.
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions): Ditto.
* rendering/RenderTableSection.cpp:
(WebCore::updateLogicalHeightForCell): Ditto.
(WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows): Ditto.
(WebCore::RenderTableSection::distributeExtraLogicalHeightToRows): Ditto.

* rendering/style/RenderStyle.cpp:
(WebCore::requireTransformOrigin): Use modern for loop. Also marked function static,
since it's private to this file.
(WebCore::RenderStyle::applyTransform): Use isPercentNotCalculated() instead of
type() == Percent; no behavior change. Also use a modern for loop and auto& to avoid
a really long type name.

* rendering/svg/RenderSVGRoot.cpp:
(WebCore::RenderSVGRoot::computeIntrinsicRatioInformation): Use isPercentNotCalculated()
before code that calls percent(), which won't work for a calculated length.

* platform/Length.h:
(WebCore::Length::percent):
(WebCore::Length::isPercentNotCalculated):
(WebCore::Length::isPercent):
(WebCore::Length::isSpecified):
* platform/graphics/transforms/TranslateTransformOperation.h:
(WebCore::TranslateTransformOperation::apply):
* rendering/AutoTableLayout.cpp:
(WebCore::AutoTableLayout::recalcColumn):
(WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
(WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
(WebCore::AutoTableLayout::layout):
* rendering/FixedTableLayout.cpp:
(WebCore::FixedTableLayout::layout):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
* rendering/RenderTableSection.cpp:
(WebCore::updateLogicalHeightForCell):
(WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows):
(WebCore::RenderTableSection::distributeExtraLogicalHeightToRows):
* rendering/style/RenderStyle.cpp:
(WebCore::requireTransformOrigin):
(WebCore::RenderStyle::applyTransform):
* rendering/svg/RenderSVGRoot.cpp:
(WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):

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

8 years ago[GTK] Remove media controls dead code
calvaris@igalia.com [Tue, 8 Apr 2014 08:15:39 +0000 (08:15 +0000)]
[GTK] Remove media controls dead code
https://bugs.webkit.org/show_bug.cgi?id=131300

Reviewed by Eric Carlson.

MediaControlsGtk.cpp is no longer used so we can remove it from
the repo.

No new tests needed.

* PlatformGTK.cmake: Remove html/shadow/MediaControlsGtk.cpp from
compilation.
* html/shadow/MediaControlsGtk.cpp: Removed.

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

8 years ago[CSSRegions] Fixed positioned elements in named flows have fragmented content
mihnea@adobe.com [Tue, 8 Apr 2014 08:13:11 +0000 (08:13 +0000)]
[CSSRegions] Fixed positioned elements in named flows have fragmented content
https://bugs.webkit.org/show_bug.cgi?id=130595

Reviewed by Darin Adler.

Source/WebCore:

Fixed positioned elements that have the named flow as parent are positioned
and sized relative to the viewport. Because of that, when the named flow
has an associated region chain, the fixed positioned elements should not
be fragmented.

By making a fixed positioned element with a named flow parent unsplittable
for fragmentation, we prevent this wrong behavior.

Test: fast/regions/fixed-pos-content-fragmented.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::isUnsplittableForPagination):

LayoutTests:

* fast/regions/fixed-pos-content-fragmented-expected.html: Added.
* fast/regions/fixed-pos-content-fragmented.html: Added.

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

8 years agoRegression: AX: image labels no longer exposed to AX API in SVG test case
cfleizach@apple.com [Tue, 8 Apr 2014 07:59:22 +0000 (07:59 +0000)]
Regression: AX: image labels no longer exposed to AX API in SVG test case
https://bugs.webkit.org/show_bug.cgi?id=131208

Reviewed by Daniel Bates.

Source/WebCore:

accessibleNameForNode should work on any Element, not just HTML elements.

Test: accessibility/svg-labelledby.html

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::accessibleNameForNode):

LayoutTests:

* accessibility/svg-labelledby-expected.txt: Added.
* accessibility/svg-labelledby.html: Added.

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

8 years ago[GTK] [EFL] Build fails with GCC < 4.8.x
agomez@igalia.com [Tue, 8 Apr 2014 07:37:37 +0000 (07:37 +0000)]
[GTK] [EFL] Build fails with GCC < 4.8.x
https://bugs.webkit.org/show_bug.cgi?id=130585

Reviewed by Martin Robinson.

The behavior in lower versions of GCC seem to be related to
http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-active.html#2132.

Provided explicit casts for the failing ambiguous overloads.

Source/WebCore:

* platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
(WebCore::AudioFileReader::createBus):
* platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
(webKitMediaSrcChangeState):
(webKitMediaVideoSrcNeedDataCb):
(webKitMediaAudioSrcNeedDataCb):
(webKitMediaVideoSrcEnoughDataCb):
(webKitMediaAudioSrcEnoughDataCb):
(webKitMediaVideoSrcSeekDataCb):
(webKitMediaAudioSrcSeekDataCb):
* platform/gtk/GtkDragAndDropHelper.cpp:
(WebCore::GtkDragAndDropHelper::handleDragLeave):
* platform/gtk/SharedTimerGtk.cpp:
(WebCore::setSharedTimerFireInterval):

Source/WTF:

* wtf/gtk/MainThreadGtk.cpp:
(WTF::scheduleDispatchFunctionsOnMainThread):
* wtf/gtk/RunLoopGtk.cpp:
(WTF::RunLoop::wakeUp): Provided lambda with a RefPtr instead of
ref and de-referring.

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

8 years agoChange NavigatorContentUtils client ownership from port side to NavigatorContentUtils
gyuyoung.kim@samsung.com [Tue, 8 Apr 2014 07:14:20 +0000 (07:14 +0000)]
Change NavigatorContentUtils client ownership from port side to NavigatorContentUtils
https://bugs.webkit.org/show_bug.cgi?id=131299

Reviewed by Darin Adler.

EFL and GTK ports have managed own client of NavigatorContentUtils though it is only passed to
NavigatorContentUtils. The NavigatorContentUtils has used the client to call port functions. So,
there is no reason port implementation needs to manage the ownership. To manage the client is
unnecessary work in current implementation.

Source/WebCore:

No new tests, no behavior changes.

* Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
(WebCore::NavigatorContentUtils::create):
(WebCore::provideNavigatorContentUtilsTo):
* Modules/navigatorcontentutils/NavigatorContentUtils.h:
* Modules/navigatorcontentutils/NavigatorContentUtilsClient.h:

Source/WebKit/efl:

* ewk/ewk_view.cpp:
(_ewk_view_priv_new):

Source/WebKit/gtk:

* webkit/webkitwebview.cpp:
(webkit_web_view_init):
* webkit/webkitwebviewprivate.h:

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

8 years ago[WK2] Fix unused parameter compile warning
gyuyoung.kim@samsung.com [Tue, 8 Apr 2014 06:55:22 +0000 (06:55 +0000)]
[WK2] Fix unused parameter compile warning
https://bugs.webkit.org/show_bug.cgi?id=131260

Reviewed by Darin Adler.

Remove the arguments name without UNUSED_PARAM().

* UIProcess/API/APIDownloadClient.h:
(API::DownloadClient::didReceiveData):
(API::DownloadClient::shouldDecodeSourceDataOfMIMEType):
(API::DownloadClient::decideDestinationWithSuggestedFilename):
(API::DownloadClient::didCreateDestination):
* UIProcess/API/APIFindClient.h:
(API::FindClient::didCountStringMatches):
(API::FindClient::didFindString):
* UIProcess/API/APIHistoryClient.h:
(API::HistoryClient::didPerformClientRedirect):
(API::HistoryClient::didPerformServerRedirect):
(API::HistoryClient::didUpdateHistoryTitle):
* UIProcess/API/APILoaderClient.h:
(API::LoaderClient::didStartProvisionalLoadForFrame):
(API::LoaderClient::didReceiveServerRedirectForProvisionalLoadForFrame):
(API::LoaderClient::didFailProvisionalLoadWithErrorForFrame):
(API::LoaderClient::didCommitLoadForFrame):
(API::LoaderClient::didFinishLoadForFrame):
(API::LoaderClient::didFailLoadWithErrorForFrame):
(API::LoaderClient::didChangeBackForwardList):
* UIProcess/API/APIPolicyClient.h:
(API::PolicyClient::decidePolicyForNavigationAction):
(API::PolicyClient::decidePolicyForNewWindowAction):
(API::PolicyClient::decidePolicyForResponse):
(API::PolicyClient::unableToImplementPolicy):

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

8 years ago[Mac] Allow com.apple.ViewBridge preferences reading in plug-in sandbox profile
ap@apple.com [Tue, 8 Apr 2014 06:51:51 +0000 (06:51 +0000)]
[Mac] Allow com.apple.ViewBridge preferences reading in plug-in sandbox profile
https://bugs.webkit.org/show_bug.cgi?id=131306
<rdar://problem/16359865>

Reviewed by Sam Weinig.

* Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb: Do it.

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

8 years agoSkipped some HighDPI tests for GTK+
mrobinson@webkit.org [Tue, 8 Apr 2014 06:09:32 +0000 (06:09 +0000)]
Skipped some HighDPI tests for GTK+

* platform/gtk/TestExpectations: GTK+ does not yet have HighDPI support.

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

8 years ago[GTK] Remove WebKit1 test results and merge TestExpectations files
mrobinson@webkit.org [Tue, 8 Apr 2014 06:02:01 +0000 (06:02 +0000)]
[GTK] Remove WebKit1 test results and merge TestExpectations files
https://bugs.webkit.org/show_bug.cgi?id=131342

Merge all WebKit1 test expectations into the gtk directory and also merge the WebKit2
test expectations files into the GTK+ one, removing duplicate lines.

* http/tests/security/resources/drag-drop-allowed-expected.txt: Added.
* platform/gtk-wk1: Removed.
* platform/gtk-wk2: Removed.
* platform/gtk/TestExpectations: Merged in WebKit2 expectations.
* platform/gtk/accessibility/file-upload-button-stringvalue-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/accessibility/file-upload-button-stringvalue-expected.txt.
* platform/gtk/fast/events/wheelevent-in-horizontal-scrollbar-in-rtl-expected.txt:
* platform/gtk/fast/events/wheelevent-in-vertical-scrollbar-in-rtl-expected.txt:
* platform/gtk/http/tests/loading/basic-auth-resend-wrong-credentials-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/loading/basic-auth-resend-wrong-credentials-expected.txt.
* platform/gtk/http/tests/loading/basic-credentials-sent-automatically-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/loading/basic-credentials-sent-automatically-expected.txt.
* platform/gtk/http/tests/misc/401-alternative-content-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/misc/401-alternative-content-expected.txt.
* platform/gtk/http/tests/misc/authentication-redirect-1/authentication-sent-to-redirect-cross-origin-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/misc/authentication-redirect-1/authentication-sent-to-redirect-cross-origin-expected.txt.
* platform/gtk/http/tests/misc/authentication-redirect-2/authentication-sent-to-redirect-same-origin-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/misc/authentication-redirect-2/authentication-sent-to-redirect-same-origin-expected.txt.
* platform/gtk/http/tests/misc/authentication-redirect-4/authentication-sent-to-redirect-same-origin-url-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/misc/authentication-redirect-4/authentication-sent-to-redirect-same-origin-url-expected.txt.
* platform/gtk/http/tests/security/401-logout/401-logout-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/security/401-logout/401-logout-expected.txt.
* platform/gtk/http/tests/xmlhttprequest/failed-auth-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/xmlhttprequest/failed-auth-expected.txt.
* platform/gtk/http/tests/xmlhttprequest/remember-bad-password-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/http/tests/xmlhttprequest/remember-bad-password-expected.txt.
* platform/gtk/js/dom/global-constructors-attributes-expected.txt: Renamed from LayoutTests/platform/gtk-wk2/js/dom/global-constructors-attributes-expected.txt.
* platform/gtk/plugins/npruntime/object-from-destroyed-plugin-expected.txt:
* platform/gtk/plugins/npruntime/object-from-destroyed-plugin-in-subframe-expected.txt:
* platform/gtk/plugins/plugin-clip-subframe-expected.txt:

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

8 years agoBuild bmalloc on Mac
ggaren@apple.com [Tue, 8 Apr 2014 05:31:41 +0000 (05:31 +0000)]
Build bmalloc on Mac
https://bugs.webkit.org/show_bug.cgi?id=131333

Reviewed by Mark Rowe.

.:

* Source/Makefile:
* WebKitBuild: Added.
* WebKitBuild/Debug: Added.

Source/bmalloc:

* Makefile: Added. For make clients.

These files are required for building any project in WebKit. I copied
them from WTF:
* Configurations: Added.
* Configurations/Base.xcconfig: Added.
* Configurations/DebugRelease.xcconfig: Added.
* Configurations/bmalloc.xcconfig: Added.
* Configurations/iOS.xcconfig: Added.
* Configurations/mbmalloc.xcconfig: Added.

* bmalloc.xcodeproj/project.pbxproj: I removed per-project-file stuff
from here because everything is in .xcconfig files now.

I had to fix a bunch of minor warnings, since they're enabled in our
.xcconfig files:

* bmalloc/AsyncTask.h:
(bmalloc::Function>::AsyncTask):
* bmalloc/BAssert.h:
* bmalloc/BoundaryTagInlines.h:
(bmalloc::validate):
* bmalloc/Heap.cpp:
(bmalloc::Heap::Heap):
(bmalloc::Heap::allocateLarge):
(bmalloc::Heap::deallocateLarge):
* bmalloc/Mutex.h:
(bmalloc::Mutex::Mutex): Deleted.
* bmalloc/VMAllocate.h:
(bmalloc::vmValidate):
* bmalloc/mbmalloc.cpp:

Tools:

* Scripts/build-webkit: Add the bmalloc target if we're on Mac.
(Note: Just testing Mac is not good enough because in this
script 'Mac' means 'Mac or iOS'.)

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

8 years ago[CSS Shapes] Simplify the parsing of width arguments for Inset shapes
zoltan@webkit.org [Tue, 8 Apr 2014 04:47:05 +0000 (04:47 +0000)]
[CSS Shapes] Simplify the parsing of width arguments for Inset shapes
https://bugs.webkit.org/show_bug.cgi?id=131305

Reviewed by Andreas Kling.

This code introduces some helper functions for setting the size arguments of inset shapes. This change
also modifies the code to be the same as in Blink, so it helps us to keep the shapes code similar.

No new tests, no behavior change.

* css/CSSBasicShapes.h:
(WebCore::CSSBasicShapeInset::updateShapeSize4Values):
(WebCore::CSSBasicShapeInset::updateShapeSize1Value):
(WebCore::CSSBasicShapeInset::updateShapeSize2Values):
(WebCore::CSSBasicShapeInset::updateShapeSize3Values):
* css/CSSParser.cpp:
(WebCore::CSSParser::parseBasicShapeInset):

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

8 years agoSetters are just getters that take an extra argument and don't return a value
fpizlo@apple.com [Tue, 8 Apr 2014 03:55:12 +0000 (03:55 +0000)]
Setters are just getters that take an extra argument and don't return a value
https://bugs.webkit.org/show_bug.cgi?id=131336

Reviewed by Geoffrey Garen.

Other than that, they're totally the same thing.

This isn't as dumb as it sounds.

Most of the work in calling an accessor has to do with emitting the necessary checks for
figuring out whether we're calling the accessor we expected, followed by the boilerplate
needed for setting up a call inside of a stub. It makes sense for the code to be totally
common.

* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::storeValue):
(JSC::AssemblyHelpers::moveTrustedValue):
* jit/CCallHelpers.h:
(JSC::CCallHelpers::setupResults):
* jit/Repatch.cpp:
(JSC::kindFor):
(JSC::customFor):
(JSC::generateByIdStub):
(JSC::tryCacheGetByID):
(JSC::tryBuildGetByIDList):
(JSC::tryCachePutByID):
(JSC::tryBuildPutByIdList):
(JSC::generateGetByIdStub): Deleted.
(JSC::emitCustomSetterStub): Deleted.
* runtime/JSCJSValue.h:
(JSC::JSValue::asValue):
* runtime/PutPropertySlot.h:
(JSC::PutPropertySlot::cachedOffset):

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

8 years agoCrash in com.apple.WebKit.Plugin.Development at com.apple.WebKit2: WebKit::PluginCont...
slewis@apple.com [Tue, 8 Apr 2014 03:49:37 +0000 (03:49 +0000)]
Crash in com.apple.WebKit.Plugin.Development at com.apple.WebKit2: WebKit::PluginControllerProxy::pluginInstanceID
<rdar://problem/16479432>
https://bugs.webkit.org/show_bug.cgi?id=131203

Reviewed by Geoff Garen.

pluginController was being removed before accessing the pluginInstanceID.

* PluginProcess/WebProcessConnection.cpp:
(WebKit::WebProcessConnection::removePluginControllerProxy):

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

8 years agoMore Mountain Lion build fix.
mitz@apple.com [Tue, 8 Apr 2014 02:46:49 +0000 (02:46 +0000)]
More Mountain Lion build fix.

* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:

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

8 years ago[iOS][WK2] Implement the update of content offset on animated resize
benjamin@webkit.org [Tue, 8 Apr 2014 02:12:42 +0000 (02:12 +0000)]
[iOS][WK2] Implement the update of content offset on animated resize
https://bugs.webkit.org/show_bug.cgi?id=131329

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-04-07
Reviewed by Tim Horton.

Compute a reasonable target offset on rotation. This goes in 3 steps:
1) Move the page so that the center does not move during scaling.
2) Limit the range to keep the page in scrollview without rubberbanding.
3) The horizontal content stays the same but the vertical area changes. When on the top or bottom
   edge, stick to the edge.

The code is moved inside _beginAnimatedResizeToSize:obscuredInsets:minimumLayoutSizeOverride: so that we can tell
the WebProcess where the scroll position will be at the end of the animation.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _frameOrBoundsChangedFrom:]):
(-[WKWebView _updateVisibleContentRects]):
(-[WKWebView _beginAnimatedResizeToSize:obscuredInsets:minimumLayoutSizeOverride:]):

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

8 years agoMountain Lion build fix.
mitz@apple.com [Tue, 8 Apr 2014 02:07:14 +0000 (02:07 +0000)]
Mountain Lion build fix.

* UIProcess/ios/PageClientImplIOS.mm:
* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:

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

8 years agoHandle decoding of nil invocation arguments
andersca@apple.com [Tue, 8 Apr 2014 01:38:09 +0000 (01:38 +0000)]
Handle decoding of nil invocation arguments
https://bugs.webkit.org/show_bug.cgi?id=131335
<rdar://problem/16528449>

Reviewed by Tim Horton.

* Shared/APIArray.h:
Don't crash if the array element is null.

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

8 years agofast/css3-text/css3-text-decoration/text-decoration-thickness.html fails on GTK
mrobinson@webkit.org [Tue, 8 Apr 2014 01:35:19 +0000 (01:35 +0000)]
fast/css3-text/css3-text-decoration/text-decoration-thickness.html fails on GTK
https://bugs.webkit.org/show_bug.cgi?id=129957

Reviewed by Dean Jackson.

Source/WebCore:

Causes existing tests to pass.

* platform/graphics/cairo/GraphicsContextCG.cpp: Use the now-shared computeLineBoundsAndAntialiasingModeForText.
* platform/graphics/cairo/GraphicsContextCairo.cpp: Align the Cairo version of text underline drawing with the CG version.
* platform/graphics/GraphicsContext.h: Add computeLineBoundsAndAntialiasingModeForText.
* platform/graphics/GraphicsContext.cpp: Ditto.

LayoutTests:

Unskipped tests and modified one test to use the platform-independent Ahem font.

* fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-tall-underlines.html: We
need to use Ahem because Helvetica is not a platform-independent font.
* platform/gtk/TestExpectations: Unskipped tests.

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

8 years agoWeb Inspector: test helper files should be under LayoutTests/http/tests/inspector/
burg@cs.washington.edu [Tue, 8 Apr 2014 00:56:37 +0000 (00:56 +0000)]
Web Inspector: test helper files should be under LayoutTests/http/tests/inspector/
https://bugs.webkit.org/show_bug.cgi?id=131324

Reviewed by Joseph Pecoraro.

Rearrange helper files used by full inspector tests. In their previous placement,
they were outside the http server root and couldn't be loaded from http tests.

* http/tests/inspector/debugger/debugger-test.js: Renamed from LayoutTests/inspector/debugger/debugger-test.js.
* http/tests/inspector/dom/shapes-test.js: Renamed from LayoutTests/inspector/dom/shapes-test.js.
* http/tests/inspector/inspector-test.js: Renamed from LayoutTests/inspector/inspector-test.js.
* http/tests/inspector/replay/replay-test.js: Renamed from LayoutTests/inspector/replay/replay-test.js.
* inspector/debugger/probe-manager-add-remove-actions.html:
* inspector/dom/content-flow-content-nodes.html:
* inspector/dom/content-flow-content-removal.html:
* inspector/dom/content-flow-list.html:
* inspector/dom/content-node-region-info.html:
* inspector/dom/highlight-shape-outside-margin.html:
* inspector/dom/highlight-shape-outside.html:
* inspector/page/main-frame-resource.html:
* inspector/replay/javascript-date-now.html:
* inspector/replay/javascript-random-seed.html:
* inspector/test-harness-trivially-works.html:

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

8 years agoAdd bundle client function corresponding to startAssistingNode
mitz@apple.com [Tue, 8 Apr 2014 00:39:55 +0000 (00:39 +0000)]
Add bundle client function corresponding to startAssistingNode
https://bugs.webkit.org/show_bug.cgi?id=131332

Reviewed by Anders Carlsson.

* UIProcess/PageClient.h: Added userData parameter to startAssistingNode.

* UIProcess/WebPageProxy.h: Added message decoder parameter to startAssistingNode.
* UIProcess/WebPageProxy.messages.in: Added message decoder parameter to StartAssistingNode.

* UIProcess/ios/PageClientImplIOS.h: Updated startAssistingNode override.
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::startAssistingNode): Decode the user data into an NSObject and pass
it on to the content view.

* UIProcess/ios/WKContentViewInteraction.h: Added userObject parameter to
-_startAssitingNode:.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _startAssistingNode:userObject:]): Added userObject parameter. We will pass
it to a future delegate method.

* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::startAssistingNode): Decode the user data and pass it to the client.

* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Declared new
delegate method.
* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
(-[WKWebProcessPlugInBrowserContextController _setFormDelegate:]): Added an implementation
of API::InjectedBundle::FormClient::willBeginInputSession which calls the new delegate
method, and encodes the user object into userData.

* WebProcess/InjectedBundle/APIInjectedBundleFormClient.h:
(API::InjectedBundle::FormClient::willBeginInputSession): Added willBeginInputSession.

* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::elementDidFocus): Call willBeginInputSession and send the user data along
with the StartAssistingNode message to the UI process.

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

8 years agoUnreviewed. Fixing the EFL build.
jinwoo7.song@samsung.com [Tue, 8 Apr 2014 00:24:45 +0000 (00:24 +0000)]
Unreviewed. Fixing the EFL build.

* WebProcess/WebPage/CoordinatedGraphics/WebPageCoordinatedGraphics.cpp: Include the Document header from WebCore
to avoid operating on an incomplete type.

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

8 years agobmalloc: Fixed a leak in the per-thread cache
ggaren@apple.com [Tue, 8 Apr 2014 00:23:38 +0000 (00:23 +0000)]
bmalloc: Fixed a leak in the per-thread cache
https://bugs.webkit.org/show_bug.cgi?id=131330

Reviewed by Andreas Kling.

Remember to deallocate our line caches upon thread exit.

* bmalloc/Deallocator.cpp:
(bmalloc::Deallocator::~Deallocator):

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

8 years agobmalloc: rolled out the tryLock experiment
ggaren@apple.com [Tue, 8 Apr 2014 00:12:16 +0000 (00:12 +0000)]
bmalloc: rolled out the tryLock experiment
https://bugs.webkit.org/show_bug.cgi?id=131328

Reviewed by Andreas Kling.

It wasn't a speedup.

* bmalloc.xcodeproj/project.pbxproj:
* bmalloc/Allocator.cpp:
(bmalloc::Allocator::processSmallAllocatorLog):
(bmalloc::Allocator::processMediumAllocatorLog):
* bmalloc/Deallocator.cpp:
(bmalloc::Deallocator::processObjectLog):
(bmalloc::Deallocator::deallocateSlowCase):
(bmalloc::Deallocator::deallocateSmallLine):
(bmalloc::Deallocator::deallocateMediumLine):
* bmalloc/Deallocator.h:
(bmalloc::Deallocator::deallocateFastCase):
* bmalloc/Heap.h:
(bmalloc::Heap::deallocateSmallLine):
(bmalloc::Heap::deallocateMediumLine):
* bmalloc/Line.h:
(bmalloc::Line<Traits>::deref):
* bmalloc/Page.h:
(bmalloc::Page<Traits>::deref):

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

8 years ago[iOS WebKit2] WKPDFView fades in tiles, PDFs load very flashily
timothy_horton@apple.com [Tue, 8 Apr 2014 00:07:45 +0000 (00:07 +0000)]
[iOS WebKit2] WKPDFView fades in tiles, PDFs load very flashily
https://bugs.webkit.org/show_bug.cgi?id=131325
<rdar://problem/16382960>

Reviewed by Anders Carlsson.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView scrollViewDidScroll:]):
Forward scroll events to the current custom content provider.

* UIProcess/Cocoa/WKWebViewContentProvider.h:
Make content providers UIScrollViewDelegates (though we only forward didScroll for now).

* UIProcess/ios/WKPDFView.mm:
(-[WKPDFView web_setContentProviderData:suggestedFilename:]):
(-[WKPDFView web_setMinimumSize:]):
(-[WKPDFView web_setScrollView:]):
(-[WKPDFView scrollViewDidScroll:]):
(-[WKPDFView _revalidateViews]):
(-[WKPDFView _computePageAndDocumentFrames]):
(-[WKPDFView layoutViews]): Deleted.
Keep track of each UIPDFPage, UIPDFPageView, and its frame (in unscaled/document coordinates).
Compute all the rects up front (and re-compute upon rotation, loading, etc.).
When scrolling, find all the pages that intersect the view (inflated by 1.5x in each
vertical direction), and ensure that pages that are inside that rect have
UIPDFPageViews installed, and ones that are outside that rect do not.
Use setUseBackingLayer to ensure that we have a low-resolution layer behind the
tiled layer to avoid flashiness.

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

8 years agoREGRESSION (r163194-r163227): Garbage tiles in overflow of RTL page with
bdakin@apple.com [Tue, 8 Apr 2014 00:04:20 +0000 (00:04 +0000)]
REGRESSION (r163194-r163227): Garbage tiles in overflow of RTL page with
background image
https://bugs.webkit.org/show_bug.cgi?id=131323
-and corresponding-
<rdar://problem/16402013>

Reviewed by Tim Horton.

Returning the TiledBacking::bounds() for the
FrameView::extendedBackgroundRectForPainting() in convenient for ltr pages, but it
is simply incorrect in rtl. There is no easy way to map the rect into the right
coordinate space, so this patch re-works the code to use computations in
RenderView to get the right rect.

Call RenderView::unextendedBackgroundRect() and expand and move it based on the
TiledBacking’s margins.
* page/FrameView.cpp:
(WebCore::FrameView::extendedBackgroundRectForPainting):

The logic that used to be in backgroundRect() has been moved to
unextendedBackgroundRect().
* rendering/RenderView.cpp:
(WebCore::RenderView::unextendedBackgroundRect):
(WebCore::RenderView::backgroundRect):
* rendering/RenderView.h:

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

8 years ago[CSS Shapes] inset complex calc() args vanish in serialized computed style
zoltan@webkit.org [Tue, 8 Apr 2014 00:01:56 +0000 (00:01 +0000)]
[CSS Shapes] inset complex calc() args vanish in serialized computed style
https://bugs.webkit.org/show_bug.cgi?id=129838

Reviewed by Bem Jones-Bey.

Source/WebCore:

We didn't pass the style parameter when setting the width members of CSSBasicShapeInset,
which lead to a 'should never reach asserttion' in CSSPrimitiveValue::init. This patch
adds the missing parameters to the call sites.

Extended existing parsing test script.

* css/BasicShapeFunctions.cpp:
(WebCore::valueForBasicShape):

LayoutTests:

* fast/shapes/parsing/parsing-shape-outside-expected.txt:
* fast/shapes/parsing/parsing-test-utils.js:

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

8 years agobmalloc
ggaren@apple.com [Mon, 7 Apr 2014 23:54:11 +0000 (23:54 +0000)]
bmalloc
https://bugs.webkit.org/show_bug.cgi?id=131170

Reviewed by Andreas Kling.

Initial commit.

* bmalloc: Added.
* bmalloc.xcodeproj: Added.
* bmalloc.xcodeproj/project.pbxproj: Added.
* bmalloc/Algorithm.h: Added.
(bmalloc::max):
(bmalloc::min):
(bmalloc::mask):
(bmalloc::test):
(bmalloc::roundUpToMultipleOf):
(bmalloc::roundDownToMultipleOf):
(bmalloc::sizeOf):
(bmalloc::bitCount):
(bmalloc::isPowerOfTwo):
* bmalloc/Allocator.cpp: Added.
(bmalloc::Allocator::Allocator):
(bmalloc::Allocator::~Allocator):
(bmalloc::Allocator::log):
(bmalloc::Allocator::processSmallAllocatorLog):
(bmalloc::Allocator::processMediumAllocatorLog):
(bmalloc::Allocator::allocateLarge):
(bmalloc::Allocator::allocateXLarge):
(bmalloc::Allocator::allocateMedium):
(bmalloc::Allocator::allocateSlowCase):
* bmalloc/Allocator.h: Added.
(bmalloc::Allocator::smallAllocatorFor):
(bmalloc::Allocator::allocateFastCase):
(bmalloc::Allocator::allocate):
* bmalloc/AsyncTask.cpp: Added.
(bmalloc::AsyncTask<Function>::runSlowCase):
(bmalloc::AsyncTask<Function>::pthreadEntryPoint):
(bmalloc::AsyncTask<Function>::entryPoint):
* bmalloc/AsyncTask.h: Added.
(bmalloc::Function>::AsyncTask):
(bmalloc::Function>::join):
(bmalloc::Function>::run):
(bmalloc::Function>::runSlowCase):
(bmalloc::Function>::pthreadEntryPoint):
(bmalloc::Function>::entryPoint):
* bmalloc/BAssert.h: Added.
* bmalloc/BeginTag.h: Added.
(bmalloc::BeginTag::isInFreeList):
* bmalloc/BoundaryTag.h: Added.
(bmalloc::BoundaryTag::isXLarge):
(bmalloc::BoundaryTag::setXLarge):
(bmalloc::BoundaryTag::isFree):
(bmalloc::BoundaryTag::setFree):
(bmalloc::BoundaryTag::isEnd):
(bmalloc::BoundaryTag::setEnd):
(bmalloc::BoundaryTag::hasPhysicalPages):
(bmalloc::BoundaryTag::setHasPhysicalPages):
(bmalloc::BoundaryTag::isNull):
(bmalloc::BoundaryTag::clear):
(bmalloc::BoundaryTag::size):
(bmalloc::BoundaryTag::setSize):
(bmalloc::BoundaryTag::prev):
(bmalloc::BoundaryTag::next):
* bmalloc/BoundaryTagInlines.h: Added.
(bmalloc::validate):
(bmalloc::validatePrev):
(bmalloc::validateNext):
(bmalloc::BoundaryTag::init):
(bmalloc::BoundaryTag::mergeLargeLeft):
(bmalloc::BoundaryTag::mergeLargeRight):
(bmalloc::BoundaryTag::mergeLarge):
(bmalloc::BoundaryTag::deallocate):
(bmalloc::BoundaryTag::splitLarge):
(bmalloc::BoundaryTag::allocate):
* bmalloc/Cache.cpp: Added.
(bmalloc::Cache::operator new):
(bmalloc::Cache::operator delete):
(bmalloc::Cache::Cache):
(bmalloc::Cache::allocateSlowCase):
(bmalloc::Cache::allocateSlowCaseNullCache):
(bmalloc::Cache::deallocateSlowCase):
(bmalloc::Cache::deallocateSlowCaseNullCache):
* bmalloc/Cache.h: Added.
(bmalloc::Cache::allocator):
(bmalloc::Cache::deallocator):
(bmalloc::Cache::allocateFastCase):
(bmalloc::Cache::deallocateFastCase):
(bmalloc::Cache::allocate):
(bmalloc::Cache::deallocate):
* bmalloc/Chunk.h: Added.
(bmalloc::Chunk::begin):
(bmalloc::Chunk::end):
(bmalloc::Chunk::lines):
(bmalloc::Chunk::pages):
* bmalloc/Deallocator.cpp: Added.
(bmalloc::Deallocator::Deallocator):
(bmalloc::Deallocator::~Deallocator):
(bmalloc::Deallocator::deallocateLarge):
(bmalloc::Deallocator::deallocateXLarge):
(bmalloc::Deallocator::processObjectLog):
(bmalloc::Deallocator::deallocateSlowCase):
(bmalloc::Deallocator::deallocateSmallLine):
(bmalloc::Deallocator::allocateSmallLine):
(bmalloc::Deallocator::deallocateMediumLine):
(bmalloc::Deallocator::allocateMediumLine):
* bmalloc/Deallocator.h: Added.
(bmalloc::Deallocator::deallocateFastCase):
(bmalloc::Deallocator::deallocate):
* bmalloc/EndTag.h: Added.
(bmalloc::EndTag::operator=):
* bmalloc/FixedVector.h: Added.
(bmalloc::FixedVector::begin):
(bmalloc::FixedVector::end):
(bmalloc::FixedVector::size):
(bmalloc::FixedVector::capacity):
(bmalloc::FixedVector::clear):
(bmalloc::FixedVector::isEmpty):
(bmalloc::Capacity>::FixedVector):
(bmalloc::Capacity>::operator):
(bmalloc::Capacity>::push):
(bmalloc::Capacity>::pop):
(bmalloc::Capacity>::shrink):
* bmalloc/Heap.cpp: Added.
(bmalloc::sleep):
(bmalloc::Heap::Heap):
(bmalloc::Heap::concurrentScavenge):
(bmalloc::Heap::scavengeSmallPages):
(bmalloc::Heap::scavengeMediumPages):
(bmalloc::Heap::scavengeLargeRanges):
(bmalloc::Heap::allocateSmallLineSlowCase):
(bmalloc::Heap::allocateMediumLineSlowCase):
(bmalloc::Heap::allocateXLarge):
(bmalloc::Heap::deallocateXLarge):
(bmalloc::Heap::allocateLarge):
(bmalloc::Heap::deallocateLarge):
* bmalloc/Heap.h: Added.
(bmalloc::Heap::deallocateSmallLine):
(bmalloc::Heap::allocateSmallLine):
(bmalloc::Heap::deallocateMediumLine):
(bmalloc::Heap::allocateMediumLine):
* bmalloc/Inline.h: Added.
* bmalloc/LargeChunk.h: Added.
(bmalloc::LargeChunk::begin):
(bmalloc::LargeChunk::end):
(bmalloc::LargeChunk::create):
(bmalloc::LargeChunk::get):
(bmalloc::LargeChunk::beginTag):
(bmalloc::LargeChunk::endTag):
* bmalloc/Line.h: Added.
(bmalloc::Line<Traits>::begin):
(bmalloc::Line<Traits>::end):
(bmalloc::Line<Traits>::concurrentRef):
(bmalloc::Line<Traits>::deref):
* bmalloc/MediumAllocator.h: Added.
(bmalloc::MediumAllocator::isNull):
(bmalloc::MediumAllocator::MediumAllocator):
(bmalloc::MediumAllocator::line):
(bmalloc::MediumAllocator::allocate):
(bmalloc::MediumAllocator::derefCount):
(bmalloc::MediumAllocator::refill):
* bmalloc/MediumChunk.h: Added.
* bmalloc/MediumLine.h: Added.
* bmalloc/MediumPage.h: Added.
* bmalloc/MediumTraits.h: Added.
* bmalloc/Mutex.cpp: Added.
(bmalloc::Mutex::lockSlowCase):
* bmalloc/Mutex.h: Added.
(bmalloc::Mutex::Mutex):
(bmalloc::Mutex::try_lock):
(bmalloc::Mutex::lock):
(bmalloc::Mutex::unlock):
* bmalloc/ObjectType.cpp: Added.
(bmalloc::objectType):
* bmalloc/ObjectType.h: Added.
(bmalloc::isSmallOrMedium):
(bmalloc::isSmall):
* bmalloc/Page.h: Added.
(bmalloc::Page<Traits>::ref):
(bmalloc::Page<Traits>::deref):
(bmalloc::Page<Traits>::refCount):
* bmalloc/PerProcess.h: Added.
(bmalloc::PerProcess::mutex):
(bmalloc::PerProcess<T>::getFastCase):
(bmalloc::PerProcess<T>::get):
(bmalloc::PerProcess<T>::getSlowCase):
* bmalloc/PerThread.h: Added.
(bmalloc::PerThreadStorage<Cache>::get):
(bmalloc::PerThreadStorage<Cache>::init):
(bmalloc::PerThreadStorage::get):
(bmalloc::PerThreadStorage::init):
(bmalloc::PerThread<T>::getFastCase):
(bmalloc::PerThread<T>::get):
(bmalloc::PerThread<T>::destructor):
(bmalloc::PerThread<T>::getSlowCase):
* bmalloc/Range.h: Added.
(bmalloc::Range::Range):
(bmalloc::Range::begin):
(bmalloc::Range::end):
(bmalloc::Range::size):
(bmalloc::Range::operator!):
(bmalloc::Range::operator<):
* bmalloc/SegregatedFreeList.cpp: Added.
(bmalloc::SegregatedFreeList::SegregatedFreeList):
(bmalloc::SegregatedFreeList::insert):
(bmalloc::SegregatedFreeList::takeGreedy):
(bmalloc::SegregatedFreeList::take):
* bmalloc/SegregatedFreeList.h: Added.
* bmalloc/Sizes.h: Added.
* bmalloc/SmallAllocator.h: Added.
(bmalloc::SmallAllocator::isNull):
(bmalloc::SmallAllocator::canAllocate):
(bmalloc::SmallAllocator::SmallAllocator):
(bmalloc::SmallAllocator::line):
(bmalloc::SmallAllocator::allocate):
(bmalloc::SmallAllocator::objectCount):
(bmalloc::SmallAllocator::derefCount):
(bmalloc::SmallAllocator::refill):
* bmalloc/SmallChunk.h: Added.
* bmalloc/SmallLine.h: Added.
* bmalloc/SmallPage.h: Added.
* bmalloc/SmallTraits.h: Added.
* bmalloc/Syscall.h: Added.
* bmalloc/VMAllocate.h: Added.
(bmalloc::vmSize):
(bmalloc::vmValidate):
(bmalloc::vmAllocate):
(bmalloc::vmDeallocate):
(bmalloc::vmDeallocatePhysicalPages):
(bmalloc::vmAllocatePhysicalPages):
(bmalloc::vmDeallocatePhysicalPagesSloppy):
(bmalloc::vmAllocatePhysicalPagesSloppy):
* bmalloc/VMHeap.cpp: Added.
(bmalloc::VMHeap::VMHeap):
(bmalloc::VMHeap::allocateSmallChunk):
(bmalloc::VMHeap::allocateMediumChunk):
(bmalloc::VMHeap::allocateLargeChunk):
* bmalloc/VMHeap.h: Added.
(bmalloc::VMHeap::allocateSmallPage):
(bmalloc::VMHeap::allocateMediumPage):
(bmalloc::VMHeap::allocateLargeRange):
(bmalloc::VMHeap::deallocateSmallPage):
(bmalloc::VMHeap::deallocateMediumPage):
(bmalloc::VMHeap::deallocateLargeRange):
* bmalloc/Vector.h: Added.
(bmalloc::Vector::begin):
(bmalloc::Vector::end):
(bmalloc::Vector::size):
(bmalloc::Vector::capacity):
(bmalloc::Vector::last):
(bmalloc::Vector::pop):
(bmalloc::Vector<T>::Vector):
(bmalloc::Vector<T>::~Vector):
(bmalloc::Vector<T>::operator):
(bmalloc::Vector<T>::push):
(bmalloc::Vector<T>::pop):
(bmalloc::Vector<T>::shrink):
(bmalloc::Vector<T>::reallocateBuffer):
(bmalloc::Vector<T>::shrinkCapacity):
(bmalloc::Vector<T>::growCapacity):
* bmalloc/XLargeChunk.h: Added.
(bmalloc::XLargeChunk::get):
(bmalloc::XLargeChunk::begin):
(bmalloc::XLargeChunk::XLargeChunk):
(bmalloc::XLargeChunk::create):
(bmalloc::XLargeChunk::destroy):
(bmalloc::XLargeChunk::range):
(bmalloc::XLargeChunk::size):
* bmalloc/bmalloc.h: Added.
(bmalloc::api::malloc):
(bmalloc::api::free):
(bmalloc::api::realloc):
* bmalloc/mbmalloc.cpp: Added.

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

8 years ago[iOS] MediaDocument should allow autoplay
eric.carlson@apple.com [Mon, 7 Apr 2014 23:51:08 +0000 (23:51 +0000)]
[iOS] MediaDocument should allow autoplay
https://bugs.webkit.org/show_bug.cgi?id=131301

Reviewed by Jer Noble.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::HTMLMediaElement): Don't add the RequireUserGestureForRateChange
    behavior restriction when in a MediaDocument.

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

8 years agoWeb Inspector: Hang in debuggable application after receiving WIRPermissionDenied
commit-queue@webkit.org [Mon, 7 Apr 2014 23:45:19 +0000 (23:45 +0000)]
Web Inspector: Hang in debuggable application after receiving WIRPermissionDenied
https://bugs.webkit.org/show_bug.cgi?id=131321

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2014-04-07
Reviewed by Mark Rowe.

* inspector/remote/RemoteInspector.mm:
(Inspector::RemoteInspector::xpcConnectionReceivedMessage):
Avoid attempting to take the same lock twice. Move the received message
lock grab after the WIRPermissionDenied branch, which takes the lock
inside RemoteInspector::stop.

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

8 years agoAdd API::InjectedBundle::FormClient
mitz@apple.com [Mon, 7 Apr 2014 23:00:04 +0000 (23:00 +0000)]
Add API::InjectedBundle::FormClient
https://bugs.webkit.org/show_bug.cgi?id=131317

Reviewed by Anders Carlsson.

* WebKit2.xcodeproj/project.pbxproj: Added reference to new file.

* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
(WKBundlePageSetFormClient):
* WebProcess/InjectedBundle/API/c/WKBundlePageFormClient.h:
* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
(-[WKWebProcessPlugInBrowserContextController _setFormDelegate:]): Changed to define and
create a FormClient (which derives from API::InjectedBundle::FormClient and messages a
delegate), and set it as the form client.
(didFocusTextField): Deleted.
(willSubmitForm): Deleted.
(setUpFormClient): Deleted.

* WebProcess/InjectedBundle/APIInjectedBundleFormClient.h: Added.
(API::InjectedBundle::FormClient::~FormClient):
(API::InjectedBundle::FormClient::didFocusTextField):
(API::InjectedBundle::FormClient::textFieldDidBeginEditing):
(API::InjectedBundle::FormClient::textFieldDidEndEditing):
(API::InjectedBundle::FormClient::textDidChangeInTextField):
(API::InjectedBundle::FormClient::textDidChangeInTextArea):
(API::InjectedBundle::FormClient::shouldPerformActionInTextField):
(API::InjectedBundle::FormClient::willSubmitForm):
(API::InjectedBundle::FormClient::willSendSubmitEvent):
(API::InjectedBundle::FormClient::didAssociateFormControls):
(API::InjectedBundle::FormClient::shouldNotifyOnFormChanges):

* WebProcess/InjectedBundle/InjectedBundlePageFormClient.cpp:
(WebKit::InjectedBundlePageFormClient::InjectedBundlePageFormClient): Added a constructor
from WKBundlePageFormClientBase.
(WebKit::toWKInputFieldActionType): Added helper to convert from internal enum to C SPI
enum.
(WebKit::InjectedBundlePageFormClient::shouldPerformActionInTextField): Use helper.
* WebProcess/InjectedBundle/InjectedBundlePageFormClient.h: Added inheritance from
API::InjectedBundle::FormClient, marked overrides as such.

* WebProcess/InjectedBundle/InjectedBundlePageUIClient.h: Removed unused forward
declarations.

* WebProcess/WebCoreSupport/WebEditorClient.cpp:
(WebKit::toInputFieldAction): Added helper to convert from C SPI enum to internal enum.
(WebKit::WebEditorClient::doTextFieldCommandFromEvent): Use helper.
(WebKit::WebEditorClient::textWillBeDeletedInTextField): Ditto.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage): Initialize m_formClient member.
(WebKit::WebPage::setInjectedBundleFormClient): Added. Updates m_formClient.
(WebKit::WebPage::close): Updated code to clear m_formClient.
(WebKit::WebPage::initializeInjectedBundleFormClient): Deleted.
* WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::injectedBundleFormClient): Updated return type.

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

8 years agoMove to using std::unique_ptr for opengl, texmap, transforms and efl in WebCore/platf...
commit-queue@webkit.org [Mon, 7 Apr 2014 22:21:58 +0000 (22:21 +0000)]
Move to using std::unique_ptr for opengl, texmap, transforms and efl in WebCore/platform/graphics.
https://bugs.webkit.org/show_bug.cgi?id=131276

Patch by Hyowon Kim <hw1008.kim@samsung.com> on 2014-04-07
Reviewed by Darin Adler.

Source/WebCore:

Replace uses of OwnPtr and PassOwnPtr in code under WebCore/platform/graphics/
opengl, texmap, transforms and efl with std::unique_ptr.

* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::initializeNewContext):
* platform/graphics/GraphicsContext3D.h:
* platform/graphics/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::create): Deleted.
* platform/graphics/GraphicsContext3DPrivate.h:
* platform/graphics/cairo/GraphicsContext3DCairo.cpp:
(WebCore::GraphicsContext3D::GraphicsContext3D):
(WebCore::GraphicsContext3D::setContextLostCallback):
(WebCore::GraphicsContext3D::setErrorMessageCallback):
* platform/graphics/efl/EvasGLContext.h:
* platform/graphics/efl/EvasGLSurface.h:
* platform/graphics/efl/GraphicsContext3DEfl.cpp:
(WebCore::GraphicsContext3D::setContextLostCallback):
(WebCore::GraphicsContext3D::setErrorMessageCallback):
* platform/graphics/efl/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::create):
(WebCore::GraphicsContext3DPrivate::setContextLostCallback):
* platform/graphics/efl/GraphicsContext3DPrivate.h:
* platform/graphics/mac/GraphicsContext3DMac.mm:
(WebCore::GraphicsContext3D::GraphicsContext3D):
(WebCore::GraphicsContext3D::setContextLostCallback):
(WebCore::GraphicsContext3D::setErrorMessageCallback):
* platform/graphics/opengl/Extensions3DOpenGLES.cpp:
(WebCore::Extensions3DOpenGLES::setEXTContextLostCallback):
* platform/graphics/opengl/Extensions3DOpenGLES.h:
* platform/graphics/opengl/GLPlatformContext.cpp:
(WebCore::createOffScreenContext):
(WebCore::GLPlatformContext::createContext):
* platform/graphics/opengl/GLPlatformContext.h:
* platform/graphics/opengl/GLPlatformSurface.cpp:
(WebCore::GLPlatformSurface::createOffScreenSurface):
* platform/graphics/opengl/GLPlatformSurface.h:
* platform/graphics/surfaces/efl/GraphicsSurfaceCommon.cpp:
* platform/graphics/surfaces/egl/EGLSurface.cpp:
(WebCore::EGLOffScreenSurface::createOffScreenSurface):
* platform/graphics/surfaces/egl/EGLSurface.h:
* platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
(WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
* platform/graphics/texmap/GraphicsLayerTextureMapper.h:
* platform/graphics/texmap/TextureMapper.cpp:
(WebCore::TextureMapper::create):
(WebCore::TextureMapper::TextureMapper):
* platform/graphics/texmap/TextureMapper.h:
(WebCore::TextureMapper::platformCreateAccelerated):
* platform/graphics/texmap/TextureMapperGL.cpp:
(WebCore::TextureMapper::platformCreateAccelerated):
* platform/graphics/texmap/TextureMapperGL.h:
(WebCore::TextureMapperGL::create): Deleted.
* platform/graphics/texmap/TextureMapperImageBuffer.h:
(WebCore::TextureMapperImageBuffer::TextureMapperImageBuffer):
(WebCore::TextureMapperImageBuffer::create): Deleted.
* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
(WebCore::CoordinatedGraphicsScene::purgeGLResources):
* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
* platform/graphics/transforms/TransformState.cpp:
(WebCore::TransformState::operator=):
(WebCore::TransformState::applyTransform):
* platform/graphics/transforms/TransformState.h:
* platform/graphics/win/GraphicsContext3DWin.cpp:
(WebCore::GraphicsContext3D::GraphicsContext3D):
(WebCore::GraphicsContext3D::setContextLostCallback):
(WebCore::GraphicsContext3D::setErrorMessageCallback):

Source/WebKit/efl:

Replace uses of OwnPtr for TextureMapper in AcceleratedCompositingContextEfl with std::unique_ptr.

* WebCoreSupport/AcceleratedCompositingContextEfl.h:

Source/WebKit/gtk:

Replace uses of OwnPtr for TextureMapper in AcceleratedCompositingContext with std::unique_ptr.

* WebCoreSupport/AcceleratedCompositingContext.h:

Source/WebKit2:

Replace uses of OwnPtr for TextureMapper in LayerTreeHostGtk with std::unique_ptr.

* WebProcess/WebPage/gtk/LayerTreeHostGtk.h:

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

8 years agoMake Mac only parts of TelephoneNumberOverlayController PLATFORM(MAC).
joepeck@webkit.org [Mon, 7 Apr 2014 22:11:16 +0000 (22:11 +0000)]
Make Mac only parts of TelephoneNumberOverlayController PLATFORM(MAC).

Unreviewed build fix for r166881.

* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/mac/WebPageProxyMac.mm:
(WebKit::WebPageProxy::showTelephoneNumberMenu): Deleted.
* WebProcess/WebPage/TelephoneNumberOverlayController.cpp:
(WebKit::TelephoneNumberOverlayController::drawRect):
(WebKit::TelephoneNumberOverlayController::mouseEvent):
* WebProcess/WebPage/TelephoneNumberOverlayController.h:
* WebProcess/WebPage/mac/TelephoneNumberOverlayControllerMac.mm:

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

8 years agoUnreviewed. Fixing the GTK build.
zandobersek@gmail.com [Mon, 7 Apr 2014 21:55:33 +0000 (21:55 +0000)]
Unreviewed. Fixing the GTK build.

* WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp: Include the Document header from WebCore
to avoid operating on an incomplete type.
* WebProcess/WebPage/TapHighlightController.cpp: Include the RenderElement instead of RenderObject
to make the RenderObject::style() inline accessible.
* WebProcess/WebPage/atk/WebPageAccessibilityObjectAtk.cpp: Include the Document header from WebCore

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

8 years ago[iOS WebKit2] Make back-buffers purgeable when possible
timothy_horton@apple.com [Mon, 7 Apr 2014 21:23:03 +0000 (21:23 +0000)]
[iOS WebKit2] Make back-buffers purgeable when possible
https://bugs.webkit.org/show_bug.cgi?id=131213
<rdar://problem/15373906>

Reviewed by Simon Fraser.

We should make back-buffers volatile when their owning
layer falls out of use (either stops being repainted or
is unparented), as they are inherently recreatable.

* Shared/mac/RemoteLayerBackingStore.h:
(WebKit::RemoteLayerBackingStore::volatility):
(WebKit::RemoteLayerBackingStore::lastDisplayTime):
Add storage and a getter for the backing store's last paint time.
Add setter/getter for volatility of backing store.
Add RemoteLayerTreeContext param to constructor.

* Shared/mac/RemoteLayerBackingStore.mm:
(WebKit::RemoteLayerBackingStore::RemoteLayerBackingStore):
(WebKit::RemoteLayerBackingStore::~RemoteLayerBackingStore):
Inform the RemoteLayerTreeContext when backing store
is created and destroyed. Since we only have a Context in
the Web process, this will only happen there.

(WebKit::RemoteLayerBackingStore::encode):
(WebKit::RemoteLayerBackingStore::decode):
Move some assertions out of #else blocks which are preceded by returns.

(WebKit::RemoteLayerBackingStore::display):
Update the last display time.
If the backing store was volatile, make it non-volatile.

(WebKit::RemoteLayerBackingStore::setVolatility):
Mark the relevant surfaces as volatile or not.
setVolatility:
    - fails and returns false if any surfaces weren't marked
      volatile because they were in use
    - marks the whole backing store for repaint if the front
      surface was purged

* Shared/mac/RemoteLayerTreeTransaction.mm:
(WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
(WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
Make it possible to remove the RemoteLayerBackingStore on layers
that went from drawing contents to not drawing contents.

* UIProcess/ios/ViewGestureControllerIOS.mm:
(WebKit::ViewGestureController::beginSwipeGesture):
(WebKit::ViewGestureController::removeSwipeSnapshot):
* UIProcess/mac/ViewGestureControllerMac.mm:
(WebKit::ViewGestureController::beginSwipeGesture):
(WebKit::ViewGestureController::removeSwipeSnapshot):
* UIProcess/mac/ViewSnapshotStore.mm:
(WebKit::ViewSnapshotStore::recordSnapshot):
Adopt the new names from WebCore.

* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(WebKit::PlatformCALayerRemote::recursiveBuildTransaction):
Clear the backing store if the layer doesn't want to draw contents anymore.

(WebKit::PlatformCALayerRemote::ensureBackingStore):

* WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
(WebKit::RemoteLayerTreeContext::backingStoreCollection):
* WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
(WebKit::RemoteLayerTreeContext::RemoteLayerTreeContext):
(WebKit::RemoteLayerTreeContext::backingStoreWasCreated):
(WebKit::RemoteLayerTreeContext::backingStoreWillBeDestroyed):
Keep a RemoteLayerBackingStoreCollection, which just keeps track
of all backing store (even unparented) created for layers in a
particular context. Forward backing store creation/deletion to it.
Remove a unused m_rootLayer member.

* WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
(WebKit::RemoteLayerTreeDrawingArea::flushLayers):
If any layers had backing store changes, start the timer
on the RemoteLayerBackingStoreCollection that will mark them
purgeable once they are no longer needed.

* Shared/mac/RemoteLayerBackingStoreCollection.mm:
* Shared/mac/RemoteLayerBackingStoreCollection.h:
Keep track of all backing store for our context.
When the timer fires, run through the backing store, finding
backing store that was last painted more than 1 second ago,
and mark them purgeable. If there was more recently-painted
backing store, let the timer fire again in another second;
otherwise, stop it.

* WebCore.exp.in:
* platform/graphics/cg/IOSurfacePool.cpp:
(WebCore::IOSurfacePool::takeSurface):
(WebCore::IOSurfacePool::markOlderSurfacesPurgeable):
(WebCore::IOSurfacePool::showPoolStatistics):
* platform/graphics/cocoa/IOSurface.h:
* platform/graphics/cocoa/IOSurface.mm:
(IOSurface::isVolatile):
(IOSurface::setIsVolatile):
Rename purgeability functions to match the system
and reduce confusion between purgeable memory
and volatile vs. non-volatile memory.

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

8 years agoMake it possible to disable some of the FTL's more interesting features
fpizlo@apple.com [Mon, 7 Apr 2014 20:45:58 +0000 (20:45 +0000)]
Make it possible to disable some of the FTL's more interesting features
https://bugs.webkit.org/show_bug.cgi?id=131312

Reviewed by Mark Hahnenberg.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::handleGetById):
(JSC::DFG::ByteCodeParser::handlePutById):
(JSC::DFG::ByteCodeParser::parse):
* runtime/Options.h:

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

8 years agoAnother build fix after r166879.
rniwa@webkit.org [Mon, 7 Apr 2014 20:34:53 +0000 (20:34 +0000)]
Another build fix after r166879.

* WebProcess/WebPage/mac/WebPageMac.mm:

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

8 years agoSplit CSS Selectors pseudo class and pseudo elements
benjamin@webkit.org [Mon, 7 Apr 2014 20:26:44 +0000 (20:26 +0000)]
Split CSS Selectors pseudo class and pseudo elements
https://bugs.webkit.org/show_bug.cgi?id=131295

Reviewed by Andreas Kling.

Split pseudo class and pseudo element to make it clearer what pseudo types
are possible for a given match type.

Pseudo Element types are separated and Pseudo Class are left in place. The Pseudo Class
will have to be renamed too but that will be done separately to make this change smaller.

* css/CSSGrammar.y.in:
* css/CSSParser.cpp:
(WebCore::CSSParser::rewriteSpecifiersWithElementName):
(WebCore::CSSParser::rewriteSpecifiers):
Use a method isPseudoElementCueFunction() to abstract the #ifdef out of the parser.

* css/CSSParserValues.cpp:
(WebCore::CSSParserSelector::parsePseudoElementSelector):

(WebCore::CSSParserSelector::parsePseudoElementCueFunctionSelector):
Rename to specify this is for the pseudo element cue function, not the pseudo element cue.

(WebCore::CSSParserSelector::parsePseudoClassAndCompatibilityElementSelector):
(WebCore::CSSParserSelector::parsePseudoCueFunctionSelector): Deleted.
* css/CSSParserValues.h:
(WebCore::CSSParserSelector::isPseudoElementCueFunction):
* css/CSSSelector.cpp:
(WebCore::CSSSelector::specificityForOneSelector):
(WebCore::CSSSelector::pseudoId):
(WebCore::CSSSelector::parsePseudoElementType):
(WebCore::CSSSelector::operator==):
* css/CSSSelector.h:
(WebCore::CSSSelector::pseudoType):
(WebCore::CSSSelector::setPseudoElementType):
(WebCore::CSSSelector::pseudoElementType):
(WebCore::CSSSelector::isUnknownPseudoElement):
(WebCore::CSSSelector::isCustomPseudoElement):
(WebCore::pseudoClassIsRelativeToSiblings):
(WebCore::CSSSelector::isSiblingSelector):
* css/RuleFeature.cpp:
(WebCore::RuleFeatureSet::collectFeaturesFromSelector):
* css/RuleSet.cpp:
(WebCore::determinePropertyWhitelistType):
(WebCore::RuleSet::findBestRuleSetAndAdd):
* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::matchRecursively):
(WebCore::SelectorChecker::checkOne):
(WebCore::SelectorChecker::checkScrollbarPseudoClass):
(WebCore::SelectorChecker::determineLinkMatchType):
* css/SelectorPseudoClassAndCompatibilityElementMap.in:
* css/SelectorPseudoElementTypeMap.in:
* css/SelectorPseudoTypeMap.h:
* css/makeSelectorPseudoClassAndCompatibilityElementMap.py:
* css/makeSelectorPseudoElementsMap.py:
(enumerablePseudoType):
* page/DOMWindow.cpp:
(WebCore::DOMWindow::getMatchedCSSRules):

* rendering/style/RenderStyleConstants.h:
All the fullscreen pseudo types are pseudo class selectors. They should not have a pseudo ID.

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

8 years agoTried to fix the Mac build.
mitz@apple.com [Mon, 7 Apr 2014 20:20:28 +0000 (20:20 +0000)]
Tried to fix the Mac build.

* WebProcess/Plugins/PDF/PDFPlugin.mm:

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

8 years agoHandle clicks on DataDetectors UI for scanned phone numbers
beidson@apple.com [Mon, 7 Apr 2014 20:05:06 +0000 (20:05 +0000)]
Handle clicks on DataDetectors UI for scanned phone numbers
<rdar://problem/16379588> and https://bugs.webkit.org/show_bug.cgi?id=131309

Reviewed by Tim Horton.

WebContextMenuItemDatas never need to know about a ContextMenu, so remove that concept.
Also add the concept of a selection handler for UIProcess-native menu items.
* Shared/WebContextMenuItemData.cpp:
(WebKit::WebContextMenuItemData::WebContextMenuItemData):
(WebKit::WebContextMenuItemData::encode):
(WebKit::kitItems):
(WebKit::WebContextMenuItemData::decode):
* Shared/WebContextMenuItemData.h:
(WebKit::WebContextMenuItemData::selectionHandler):

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::showContextMenu):
(WebKit::WebPageProxy::internalShowContextMenu): Make the decoder argument optional. Make consulting the client optional.
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/mac/WebPageProxyMac.mm:
(WebKit::WebPageProxy::showTelephoneNumberMenu):

* UIProcess/mac/WebContextMenuProxyMac.mm:
(-[WKSelectionHandlerWrapper initWithSelectionHandler:std::]):
(-[WKSelectionHandlerWrapper executeSelectionHandler]):
(-[WKMenuTarget forwardContextMenuAction:]):
(WebKit::nsMenuItemVector):
(WebKit::WebContextMenuProxyMac::contextMenuItemSelected): If the represented object is a WKSelectionHandlerWrapper,
  execute the selection handler. Do nothing else.

Instead of getting rects from ranges, creating highlights, and storing those highlights,
work in terms of a TelephoneNumberData object that wraps both a range and a highlight.
This makes it easier to track where the mouse is down and to know what phone number we should act on when clicked.
* WebProcess/WebPage/TelephoneNumberOverlayController.cpp:
(WebKit::TelephoneNumberOverlayController::rectsForDrawing): Deleted.
* WebProcess/WebPage/TelephoneNumberOverlayController.h:
(WebKit::TelephoneNumberData::create):
(WebKit::TelephoneNumberData::range):
(WebKit::TelephoneNumberData::highlight):
(WebKit::TelephoneNumberData::TelephoneNumberData):
* WebProcess/WebPage/mac/TelephoneNumberOverlayControllerMac.mm:
(WebKit::TelephoneNumberOverlayController::drawRect):
(WebKit::TelephoneNumberOverlayController::handleTelephoneClick): Pass the phone number text and the point to WebPage.
(WebKit::TelephoneNumberOverlayController::mouseEvent):
(WebKit::TelephoneNumberOverlayController::clearMouseDownInformation):
(WebKit::TelephoneNumberOverlayController::clearHighlights):

* WebProcess/WebPage/WebContextMenu.cpp:
(WebKit::WebContextMenu::menuItemsWithUserData):

* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::handleTelephoneNumberClick): Message the phone number and coordinate to the UIProcess.

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

8 years agoWeb Replay: detect possible replay divergence from unexpected DOM event dispatches
burg@cs.washington.edu [Mon, 7 Apr 2014 19:58:07 +0000 (19:58 +0000)]
Web Replay: detect possible replay divergence from unexpected DOM event dispatches
https://bugs.webkit.org/show_bug.cgi?id=131193

Reviewed by Andreas Kling.

Add assertions to catch potential nondeterministic behavior.

The assertion added by this patch catches dispatched DOM events
that are triggered by nondeterministic event loop cycles. If we
did not capture an event loop input in the current event loop
cycle nor are we manually simulating an event loop input during
playback, then DOM events fired during the unordered cycle could
run JavaScript and diverge the execution.

During playback, we can assert that EventLoopInputDispatcher is dispatching
when a DOM event is be dispatched to a document that is being replayed.

During capturing, event loop inputs are captured rather than
dispatched, so we add some accounting to track what caused a DOM
event. To approximate the extent of computation triggered by an
event loop input, we add RAII helpers to call sites where event
loop inputs are captured.

The assertions are disabled by default until the most common
sources of nondeterminism are handled and playback errors are
gracefully surfaced to the user. <https://webkit.org/b/131279>

No new tests. This patch adds extra assertions for debugging purposes.

* WebCore.xcodeproj/project.pbxproj:
* inspector/InspectorInstrumentation.cpp: Notify ReplayAgent of dispatched DOM event.
(WebCore::InspectorInstrumentation::willDispatchEventImpl):
(WebCore::InspectorInstrumentation::willDispatchEventOnWindowImpl):
* inspector/InspectorReplayAgent.cpp: Forward dispatched DOM events to ReplayController.
(WebCore::InspectorReplayAgent::willDispatchEvent): Added.
* inspector/InspectorReplayAgent.h:
* replay/CapturingInputCursor.cpp:
(WebCore::CapturingInputCursor::CapturingInputCursor):
(WebCore::CapturingInputCursor::setWithinEventLoopInputExtent): Added.
* replay/CapturingInputCursor.h:
* replay/EventLoopInput.cpp: Added.
(WebCore::EventLoopInputExtent::EventLoopInputExtent): Added.
(WebCore::EventLoopInputExtent::~EventLoopInputExtent): Added.
* replay/EventLoopInput.h:
* replay/EventLoopInputDispatcher.h:
(WebCore::EventLoopInputDispatcher::isDispatching): Add a getter.
* replay/ReplayController.cpp:
(WebCore::logDispatchedDOMEvent): Added. This is useful for understanding script-visible events.
(WebCore::ReplayController::willDispatchEvent): Added.
* replay/ReplayController.h:
* replay/UserInputBridge.cpp: Add extent helpers to call sites that capture inputs.
(WebCore::UserInputBridge::handleMousePressEvent):
(WebCore::UserInputBridge::handleMouseReleaseEvent):
(WebCore::UserInputBridge::handleMouseMoveEvent):
(WebCore::UserInputBridge::handleMouseMoveOnScrollbarEvent):
(WebCore::UserInputBridge::handleKeyEvent):
(WebCore::UserInputBridge::handleWheelEvent):
(WebCore::UserInputBridge::scrollRecursively):
(WebCore::UserInputBridge::logicalScrollRecursively):

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

8 years agoIntroduce API::InjectedBundle::PageUIClient
mitz@apple.com [Mon, 7 Apr 2014 19:44:06 +0000 (19:44 +0000)]
Introduce API::InjectedBundle::PageUIClient
https://bugs.webkit.org/show_bug.cgi?id=131310

Reviewed by Anders Carlsson.

* WebKit2.xcodeproj/project.pbxproj: Added references to new files.

* WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp: Added #include that
became necessary.

* WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h: Added.
(API::InjectedBundle::PageUIClient::~PageUIClient):
(API::InjectedBundle::PageUIClient::willAddMessageToConsole):
(API::InjectedBundle::PageUIClient::willSetStatusbarText):
(API::InjectedBundle::PageUIClient::willRunJavaScriptAlert):
(API::InjectedBundle::PageUIClient::willRunJavaScriptConfirm):
(API::InjectedBundle::PageUIClient::willRunJavaScriptPrompt):
(API::InjectedBundle::PageUIClient::mouseDidMoveOverElement):
(API::InjectedBundle::PageUIClient::pageDidScroll):
(API::InjectedBundle::PageUIClient::shouldGenerateFileForUpload):
(API::InjectedBundle::PageUIClient::generateFileForUpload):
(API::InjectedBundle::PageUIClient::statusBarIsVisible):
(API::InjectedBundle::PageUIClient::menuBarIsVisible):
(API::InjectedBundle::PageUIClient::toolbarsAreVisible):
(API::InjectedBundle::PageUIClient::didReachApplicationCacheOriginQuota):
(API::InjectedBundle::PageUIClient::didExceedDatabaseQuota):
(API::InjectedBundle::PageUIClient::plugInStartLabelTitle):
(API::InjectedBundle::PageUIClient::plugInStartLabelSubtitle):
(API::InjectedBundle::PageUIClient::plugInExtraStyleSheet):
(API::InjectedBundle::PageUIClient::plugInExtraScript):

* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
(WKBundlePageSetUIClient): Changed to create an InjectedBundlePageUIClient and set it on
the WebPage.

* WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp:
(WebKit::InjectedBundlePageUIClient::InjectedBundlePageUIClient): Added constructor from
WKBundlePageUIClient.
(WebKit::toUIElementVisibility): Added helper to convert from C SPI enum to internal enum.
(WebKit::InjectedBundlePageUIClient::statusBarIsVisible): Changed to use the above.
(WebKit::InjectedBundlePageUIClient::menuBarIsVisible): Ditto.
(WebKit::InjectedBundlePageUIClient::toolbarsAreVisible): Ditto.
* WebProcess/InjectedBundle/InjectedBundlePageUIClient.h: Added inheritance from
API::InjectedBundle::PageUIClient, marked overrides as such.

* WebProcess/Storage/StorageAreaMap.cpp: Added #include that became necessary.
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::toolbarsVisible): Updated to use new internal enum.
(WebKit::WebChromeClient::statusbarVisible): Ditto.
(WebKit::WebChromeClient::menubarVisible): Ditto.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage): Initialized m_uiClient member.
(WebKit::WebPage::setInjectedBundleUIClient): Added. Updates m_uiClient.
(WebKit::WebPage::close): Updated for change in m_uiClient.
(WebKit::WebPage::pageDidScroll): Ditto.
(WebKit::WebPage::initializeInjectedBundleUIClient): Deleted.
* WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::injectedBundleUIClient): Updated return type.

* WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.mm: Added #include that became
necessary.

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

8 years agoRemove copy of combine-javascript-resources.pl that isn't used anymore
timothy@apple.com [Mon, 7 Apr 2014 19:37:14 +0000 (19:37 +0000)]
Remove copy of combine-javascript-resources.pl that isn't used anymore
https://bugs.webkit.org/show_bug.cgi?id=131307

Reviewed by Joseph Pecoraro.

* WebCore.xcodeproj/project.pbxproj:
* inspector/combine-javascript-resources.pl: Removed.

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

8 years agoMove slow JSRegress tests out of the way so that they don't show up in run-jsc-benchm...
fpizlo@apple.com [Mon, 7 Apr 2014 18:45:22 +0000 (18:45 +0000)]
Move slow JSRegress tests out of the way so that they don't show up in run-jsc-benchmarks runs and also skip tests that are extremely long-running
https://bugs.webkit.org/show_bug.cgi?id=130951

Reviewed by Geoffrey Garen.

Tools:

* Scripts/run-javascriptcore-tests:

LayoutTests:

* js/regress/ArrayBuffer-DataView-alloc-large-long-lived.html:
* js/regress/ArrayBuffer-DataView-alloc-long-lived.html:
* js/regress/ArrayBuffer-Int32Array-byteOffset.html:
* js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived-expected.txt: Removed.
* js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived.html: Removed.
* js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented-expected.txt: Removed.
* js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.html: Removed.
* js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived.html:
* js/regress/ArrayBuffer-Int8Array-alloc-long-lived-buffer.html:
* js/regress/ArrayBuffer-Int8Array-alloc-long-lived.html:
* js/regress/ArrayBuffer-Int8Array-alloc.html:
* js/regress/DataView-custom-properties.html:
* js/regress/Float32Array-matrix-mult.html:
* js/regress/Float32Array-to-Float64Array-set.html:
* js/regress/Float64Array-alloc-long-lived.html:
* js/regress/Float64Array-to-Int16Array-set.html:
* js/regress/HashMap-put-get-iterate-keys.html:
* js/regress/HashMap-put-get-iterate.html:
* js/regress/HashMap-string-put-get-iterate.html:
* js/regress/Int16Array-alloc-long-lived.html:
* js/regress/Int16Array-bubble-sort-with-byteLength.html:
* js/regress/Int16Array-bubble-sort.html:
* js/regress/Int16Array-load-int-mul.html:
* js/regress/Int16Array-to-Int32Array-set.html:
* js/regress/Int32Array-Int8Array-view-alloc.html:
* js/regress/Int32Array-alloc-huge-expected.txt: Removed.
* js/regress/Int32Array-alloc-huge-long-lived-expected.txt: Removed.
* js/regress/Int32Array-alloc-huge-long-lived.html: Removed.
* js/regress/Int32Array-alloc-huge.html: Removed.
* js/regress/Int32Array-alloc-large-long-lived-expected.txt: Removed.
* js/regress/Int32Array-alloc-large-long-lived.html: Removed.
* js/regress/Int32Array-alloc-large.html:
* js/regress/Int32Array-alloc-long-lived.html:
* js/regress/Int32Array-alloc.html:
* js/regress/Int8Array-alloc-long-lived.html:
* js/regress/Int8Array-load-with-byteLength.html:
* js/regress/Int8Array-load.html:
* js/regress/adapt-to-double-divide.html:
* js/regress/aliased-arguments-getbyval.html:
* js/regress/allocate-big-object.html:
* js/regress/arity-mismatch-inlining.html:
* js/regress/array-access-polymorphic-structure.html:
* js/regress/array-nonarray-polymorhpic-access.html:
* js/regress/array-nonarray-polymorphic-access.html:
* js/regress/array-prototype-every.html:
* js/regress/array-prototype-filter-expected.txt: Removed.
* js/regress/array-prototype-filter.html: Removed.
* js/regress/array-prototype-forEach.html:
* js/regress/array-prototype-map.html:
* js/regress/array-prototype-some.html:
* js/regress/array-with-double-add.html:
* js/regress/array-with-double-increment.html:
* js/regress/array-with-double-mul-add.html:
* js/regress/array-with-double-sum.html:
* js/regress/array-with-int32-add-sub.html:
* js/regress/array-with-int32-or-double-sum.html:
* js/regress/asmjs_bool_bug.html:
* js/regress/assign-custom-setter-polymorphic.html:
* js/regress/assign-custom-setter.html:
* js/regress/basic-set.html:
* js/regress/big-int-mul.html:
* js/regress/boolean-test.html:
* js/regress/branch-fold.html:
* js/regress/by-val-generic.html:
* js/regress/call-spread-apply.html:
* js/regress/call-spread-call.html:
* js/regress/call-spread-expected.txt: Removed.
* js/regress/call-spread.html: Removed.
* js/regress/captured-assignments.html:
* js/regress/cast-int-to-double.html:
* js/regress/cell-argument.html:
* js/regress/cfg-simplify.html:
* js/regress/chain-custom-getter-expected.txt: Removed.
* js/regress/chain-custom-getter.html: Removed.
* js/regress/chain-getter-access.html:
* js/regress/cmpeq-obj-to-obj-other.html:
* js/regress/constant-test.html:
* js/regress/delay-tear-off-arguments-strictmode.html:
* js/regress/destructuring-arguments-length-expected.txt: Removed.
* js/regress/destructuring-arguments-length.html: Removed.
* js/regress/destructuring-arguments.html:
* js/regress/destructuring-swap.html:
* js/regress/direct-arguments-getbyval.html:
* js/regress/double-get-by-val-out-of-bounds.html:
* js/regress/double-pollution-getbyval.html:
* js/regress/double-pollution-putbyoffset.html:
* js/regress/double-to-int32-typed-array-no-inline.html:
* js/regress/double-to-int32-typed-array.html:
* js/regress/double-to-uint32-typed-array-no-inline.html:
* js/regress/double-to-uint32-typed-array.html:
* js/regress/empty-string-plus-int.html:
* js/regress/emscripten-cube2hash.html:
* js/regress/emscripten-memops-expected.txt: Removed.
* js/regress/emscripten-memops.html: Removed.
* js/regress/external-arguments-getbyval.html:
* js/regress/external-arguments-putbyval.html:
* js/regress/fixed-typed-array-storage-var-index.html:
* js/regress/fixed-typed-array-storage.html:
* js/regress/fold-double-to-int.html:
* js/regress/fold-strict-eq-expected.txt: Removed.
* js/regress/fold-strict-eq.html: Removed.
* js/regress/for-of-iterate-array-entries.html:
* js/regress/for-of-iterate-array-keys.html:
* js/regress/for-of-iterate-array-values.html:
* js/regress/function-dot-apply.html:
* js/regress/function-test.html:
* js/regress/function-with-eval.html:
* js/regress/get-by-id-chain-from-try-block.html:
* js/regress/get-by-id-proto-or-self.html:
* js/regress/get-by-id-self-or-proto.html:
* js/regress/get-by-val-out-of-bounds.html:
* js/regress/get_callee_monomorphic.html:
* js/regress/get_callee_polymorphic.html:
* js/regress/getter.html:
* js/regress/global-var-const-infer-fire-from-opt.html:
* js/regress/global-var-const-infer.html:
* js/regress/imul-double-only.html:
* js/regress/imul-int-only.html:
* js/regress/imul-mixed.html:
* js/regress/in-four-cases.html:
* js/regress/in-one-case-false.html:
* js/regress/in-one-case-true.html:
* js/regress/in-two-cases.html:
* js/regress/indexed-properties-in-objects.html:
* js/regress/infer-closure-const-then-mov-no-inline.html:
* js/regress/infer-closure-const-then-mov.html:
* js/regress/infer-closure-const-then-put-to-scope-no-inline.html:
* js/regress/infer-closure-const-then-put-to-scope.html:
* js/regress/infer-closure-const-then-reenter-no-inline.html:
* js/regress/infer-closure-const-then-reenter.html:
* js/regress/infer-one-time-closure-ten-vars.html:
* js/regress/infer-one-time-closure-two-vars.html:
* js/regress/infer-one-time-closure.html:
* js/regress/infer-one-time-deep-closure.html:
* js/regress/inline-arguments-access.html:
* js/regress/inline-arguments-aliased-access.html:
* js/regress/inline-arguments-local-escape.html:
* js/regress/inline-get-scoped-var.html:
* js/regress/inlined-put-by-id-transition.html:
* js/regress/int-or-other-abs-then-get-by-val.html:
* js/regress/int-or-other-abs-zero-then-get-by-val.html:
* js/regress/int-or-other-add-then-get-by-val.html:
* js/regress/int-or-other-add.html:
* js/regress/int-or-other-div-then-get-by-val.html:
* js/regress/int-or-other-max-then-get-by-val.html:
* js/regress/int-or-other-min-then-get-by-val.html:
* js/regress/int-or-other-mod-then-get-by-val.html:
* js/regress/int-or-other-mul-then-get-by-val.html:
* js/regress/int-or-other-neg-then-get-by-val.html:
* js/regress/int-or-other-neg-zero-then-get-by-val.html:
* js/regress/int-or-other-sub-then-get-by-val.html:
* js/regress/int-or-other-sub.html:
* js/regress/int-overflow-local.html:
* js/regress/int52-spill.html:
* js/regress/integer-divide.html:
* js/regress/integer-modulo.html:
* js/regress/large-int-captured.html:
* js/regress/large-int-neg.html:
* js/regress/large-int.html:
* js/regress/logical-not.html:
* js/regress/lots-of-fields.html:
* js/regress/make-indexed-storage.html:
* js/regress/make-rope-cse.html:
* js/regress/marsaglia-expected.txt: Removed.
* js/regress/marsaglia-larger-ints.html:
* js/regress/marsaglia-osr-entry.html:
* js/regress/marsaglia.html: Removed.
* js/regress/method-on-number.html:
* js/regress/misc-strict-eq.html:
* js/regress/negative-zero-divide.html:
* js/regress/negative-zero-modulo.html:
* js/regress/negative-zero-negate.html:
* js/regress/nested-function-parsing-random-expected.txt: Removed.
* js/regress/nested-function-parsing-random.html: Removed.
* js/regress/nested-function-parsing.html:
* js/regress/new-array-buffer-dead.html:
* js/regress/new-array-buffer-push.html:
* js/regress/new-array-dead.html:
* js/regress/new-array-push.html:
* js/regress/new-spread-expected.txt: Removed.
* js/regress/new-spread.html: Removed.
* js/regress/number-test.html:
* js/regress/object-closure-call.html:
* js/regress/object-test.html:
* js/regress/poly-stricteq.html:
* js/regress/polymorphic-get-by-id.html:
* js/regress/polymorphic-put-by-id.html:
* js/regress/polymorphic-structure.html:
* js/regress/polyvariant-monomorphic-get-by-id.html:
* js/regress/proto-custom-getter-expected.txt: Removed.
* js/regress/proto-custom-getter.html: Removed.
* js/regress/proto-getter-access.html:
* js/regress/put-by-id.html:
* js/regress/put-by-val-large-index-blank-indexing-type.html:
* js/regress/put-by-val-machine-int.html:
* js/regress/rare-osr-exit-on-local.html:
* js/regress/register-pressure-from-osr.html:
* js/regress/resources/regress-post.js: Removed.
* js/regress/resources/regress-pre.js: Removed.
* js/regress/script-tests/ArrayBuffer-Int8Array-alloc-huge-long-lived.js: Removed.
* js/regress/script-tests/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.js: Removed.
* js/regress/script-tests/Int32Array-alloc-huge-long-lived.js: Removed.
* js/regress/script-tests/Int32Array-alloc-huge.js: Removed.
* js/regress/script-tests/Int32Array-alloc-large-long-lived.js: Removed.
* js/regress/script-tests/array-prototype-filter.js: Removed.
* js/regress/script-tests/call-spread.js: Removed.
* js/regress/script-tests/chain-custom-getter.js: Removed.
* js/regress/script-tests/destructuring-arguments-length.js: Removed.
* js/regress/script-tests/emscripten-memops.js: Removed.
* js/regress/script-tests/fold-strict-eq.js: Removed.
* js/regress/script-tests/marsaglia.js: Removed.
* js/regress/script-tests/nested-function-parsing-random.js: Removed.
* js/regress/script-tests/new-spread.js: Removed.
* js/regress/script-tests/proto-custom-getter.js: Removed.
* js/regress/script-tests/simple-custom-getter.js: Removed.
* js/regress/script-tests/variadic-closure-call.js: Removed.
* js/regress/simple-activation-demo.html:
* js/regress/simple-custom-getter-expected.txt: Removed.
* js/regress/simple-custom-getter.html: Removed.
* js/regress/simple-getter-access.html:
* js/regress/slow-array-profile-convergence.html:
* js/regress/slow-convergence.html:
* js/regress/sparse-conditional.html:
* js/regress/splice-to-remove.html:
* js/regress/string-char-code-at.html:
* js/regress/string-concat-object.html:
* js/regress/string-concat-pair-object.html:
* js/regress/string-concat-pair-simple.html:
* js/regress/string-concat-simple.html:
* js/regress/string-cons-repeat.html:
* js/regress/string-cons-tower.html:
* js/regress/string-equality.html:
* js/regress/string-get-by-val-big-char.html:
* js/regress/string-get-by-val-out-of-bounds-insane.html:
* js/regress/string-get-by-val-out-of-bounds.html:
* js/regress/string-get-by-val.html:
* js/regress/string-hash.html:
* js/regress/string-long-ident-equality.html:
* js/regress/string-repeat-arith.html:
* js/regress/string-sub.html:
* js/regress/string-test.html:
* js/regress/string-var-equality.html:
* js/regress/structure-hoist-over-transitions.html:
* js/regress/switch-char-constant.html:
* js/regress/switch-char.html:
* js/regress/switch-constant.html:
* js/regress/switch-string-basic-big-var.html:
* js/regress/switch-string-basic-big.html:
* js/regress/switch-string-basic-var.html:
* js/regress/switch-string-basic.html:
* js/regress/switch-string-big-length-tower-var.html:
* js/regress/switch-string-length-tower-var.html:
* js/regress/switch-string-length-tower.html:
* js/regress/switch-string-short.html:
* js/regress/switch.html:
* js/regress/tear-off-arguments-simple.html:
* js/regress/tear-off-arguments.html:
* js/regress/temporal-structure.html:
* js/regress/to-int32-boolean.html:
* js/regress/undefined-test.html:
* js/regress/unprofiled-licm.html:
* js/regress/variadic-closure-call-expected.txt: Removed.
* js/regress/variadic-closure-call.html: Removed.
* js/regress/weird-inlining-const-prop.html:
* js/slow-stress: Added.
* js/slow-stress/ArrayBuffer-Int8Array-alloc-huge-long-lived-expected.txt: Copied from LayoutTests/js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived-expected.txt.
* js/slow-stress/ArrayBuffer-Int8Array-alloc-huge-long-lived.html: Copied from LayoutTests/js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived.html.
* js/slow-stress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented-expected.txt: Copied from LayoutTests/js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented-expected.txt.
* js/slow-stress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.html: Copied from LayoutTests/js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.html.
* js/slow-stress/Int32Array-alloc-huge-expected.txt: Copied from LayoutTests/js/regress/Int32Array-alloc-huge-expected.txt.
* js/slow-stress/Int32Array-alloc-huge-long-lived-expected.txt: Copied from LayoutTests/js/regress/Int32Array-alloc-huge-long-lived-expected.txt.
* js/slow-stress/Int32Array-alloc-huge-long-lived.html: Copied from LayoutTests/js/regress/Int32Array-alloc-huge-long-lived.html.
* js/slow-stress/Int32Array-alloc-huge.html: Copied from LayoutTests/js/regress/Int32Array-alloc-huge.html.
* js/slow-stress/Int32Array-alloc-large-long-lived-expected.txt: Copied from LayoutTests/js/regress/Int32Array-alloc-large-long-lived-expected.txt.
* js/slow-stress/Int32Array-alloc-large-long-lived.html: Copied from LayoutTests/js/regress/Int32Array-alloc-large-long-lived.html.
* js/slow-stress/array-prototype-filter-expected.txt: Copied from LayoutTests/js/regress/array-prototype-filter-expected.txt.
* js/slow-stress/array-prototype-filter.html: Copied from LayoutTests/js/regress/array-prototype-filter.html.
* js/slow-stress/call-spread-expected.txt: Copied from LayoutTests/js/regress/call-spread-expected.txt.
* js/slow-stress/call-spread.html: Copied from LayoutTests/js/regress/call-spread.html.
* js/slow-stress/chain-custom-getter-expected.txt: Copied from LayoutTests/js/regress/chain-custom-getter-expected.txt.
* js/slow-stress/chain-custom-getter.html: Copied from LayoutTests/js/regress/chain-custom-getter.html.
* js/slow-stress/destructuring-arguments-length-expected.txt: Copied from LayoutTests/js/regress/destructuring-arguments-length-expected.txt.
* js/slow-stress/destructuring-arguments-length.html: Copied from LayoutTests/js/regress/destructuring-arguments-length.html.
* js/slow-stress/emscripten-memops-expected.txt: Copied from LayoutTests/js/regress/emscripten-memops-expected.txt.
* js/slow-stress/emscripten-memops.html: Copied from LayoutTests/js/regress/emscripten-memops.html.
* js/slow-stress/fold-strict-eq-expected.txt: Copied from LayoutTests/js/regress/fold-strict-eq-expected.txt.
* js/slow-stress/fold-strict-eq.html: Copied from LayoutTests/js/regress/fold-strict-eq.html.
* js/slow-stress/marsaglia-expected.txt: Copied from LayoutTests/js/regress/marsaglia-expected.txt.
* js/slow-stress/marsaglia.html: Copied from LayoutTests/js/regress/marsaglia.html.
* js/slow-stress/nested-function-parsing-random-expected.txt: Copied from LayoutTests/js/regress/nested-function-parsing-random-expected.txt.
* js/slow-stress/nested-function-parsing-random.html: Copied from LayoutTests/js/regress/nested-function-parsing-random.html.
* js/slow-stress/new-spread-expected.txt: Copied from LayoutTests/js/regress/new-spread-expected.txt.
* js/slow-stress/new-spread.html: Copied from LayoutTests/js/regress/new-spread.html.
* js/slow-stress/proto-custom-getter-expected.txt: Copied from LayoutTests/js/regress/proto-custom-getter-expected.txt.
* js/slow-stress/proto-custom-getter.html: Copied from LayoutTests/js/regress/proto-custom-getter.html.
* js/slow-stress/script-tests: Added.
* js/slow-stress/script-tests/ArrayBuffer-Int8Array-alloc-huge-long-lived.js: Copied from LayoutTests/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-huge-long-lived.js.
* js/slow-stress/script-tests/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.js: Copied from LayoutTests/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-large-long-lived-fragmented.js.
* js/slow-stress/script-tests/Int32Array-alloc-huge-long-lived.js: Copied from LayoutTests/js/regress/script-tests/Int32Array-alloc-huge-long-lived.js.
* js/slow-stress/script-tests/Int32Array-alloc-huge.js: Copied from LayoutTests/js/regress/script-tests/Int32Array-alloc-huge.js.
* js/slow-stress/script-tests/Int32Array-alloc-large-long-lived.js: Copied from LayoutTests/js/regress/script-tests/Int32Array-alloc-large-long-lived.js.
* js/slow-stress/script-tests/array-prototype-filter.js: Copied from LayoutTests/js/regress/script-tests/array-prototype-filter.js.
* js/slow-stress/script-tests/call-spread.js: Copied from LayoutTests/js/regress/script-tests/call-spread.js.
* js/slow-stress/script-tests/chain-custom-getter.js: Copied from LayoutTests/js/regress/script-tests/chain-custom-getter.js.
* js/slow-stress/script-tests/destructuring-arguments-length.js: Copied from LayoutTests/js/regress/script-tests/destructuring-arguments-length.js.
* js/slow-stress/script-tests/emscripten-memops.js: Copied from LayoutTests/js/regress/script-tests/emscripten-memops.js.
* js/slow-stress/script-tests/fold-strict-eq.js: Copied from LayoutTests/js/regress/script-tests/fold-strict-eq.js.
* js/slow-stress/script-tests/marsaglia.js: Copied from LayoutTests/js/regress/script-tests/marsaglia.js.
* js/slow-stress/script-tests/nested-function-parsing-random.js: Copied from LayoutTests/js/regress/script-tests/nested-function-parsing-random.js.
* js/slow-stress/script-tests/new-spread.js: Copied from LayoutTests/js/regress/script-tests/new-spread.js.
* js/slow-stress/script-tests/proto-custom-getter.js: Copied from LayoutTests/js/regress/script-tests/proto-custom-getter.js.
* js/slow-stress/script-tests/simple-custom-getter.js: Copied from LayoutTests/js/regress/script-tests/simple-custom-getter.js.
* js/slow-stress/script-tests/variadic-closure-call.js: Copied from LayoutTests/js/regress/script-tests/variadic-closure-call.js.
* js/slow-stress/simple-custom-getter-expected.txt: Copied from LayoutTests/js/regress/simple-custom-getter-expected.txt.
* js/slow-stress/simple-custom-getter.html: Copied from LayoutTests/js/regress/simple-custom-getter.html.
* js/slow-stress/variadic-closure-call-expected.txt: Copied from LayoutTests/js/regress/variadic-closure-call-expected.txt.
* js/slow-stress/variadic-closure-call.html: Copied from LayoutTests/js/regress/variadic-closure-call.html.
* resources/regress-post.js: Copied from LayoutTests/js/regress/resources/regress-post.js.
* resources/regress-pre.js: Copied from LayoutTests/js/regress/resources/regress-pre.js.

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

8 years agoDate object needs to check for ES5 15.9.1.14 TimeClip limit.
mark.lam@apple.com [Mon, 7 Apr 2014 18:24:31 +0000 (18:24 +0000)]
Date object needs to check for ES5 15.9.1.14 TimeClip limit.
<https://webkit.org/b/131248>

Reviewed by Mark Hahnenberg.

Source/JavaScriptCore:

The current Date object code does not adequately check for the ES5
15.9.1.14 TimeClip limit.  As a result, some calculations can underflow
/ overflow and produce unexpected results.

For example, we were getting an assertion failure in
WTF::equivalentYearForDST() due int underflows in this function, which
in turn were due to an int overflow in WTF::msToYear().

This patch adds the needed checks, and adds some assertions to ensure
that the used values are sane.

The changes have no noticeable impact on benchmark results.

* runtime/DateConstructor.cpp:
(JSC::callDate):
* runtime/JSDateMath.cpp:
(JSC::localTimeOffset):
(JSC::gregorianDateTimeToMS):
(JSC::msToGregorianDateTime):
(JSC::parseDateFromNullTerminatedCharacters):
(JSC::parseDate):
* runtime/JSDateMath.h:
- parseDateFromNullTerminatedCharacters() does not need to be public.
  Made it a static function.
* runtime/VM.cpp:
(JSC::VM::resetDateCache):
- Changed cachedDateStringValue to use std::numeric_limits<double>::quiet_NaN()
  to be consistent with other Date code.

Source/WTF:

* wtf/DateMath.cpp:
- Moved the definition of maxECMAScriptTime to the .h file so that we
  can use it in other files as well.
(WTF::msToYear):
- Removed a stale comment for parseDateFromNullTerminatedCharacters().
* wtf/DateMath.h:

LayoutTests:

* js/regress-131248-expected.txt: Added.
* js/regress-131248.html: Added.
* js/script-tests/regress-131248.js: Added.
(testDateFromSetDateAdjustement):
(testDateFromSetTimeWithMilliseconds):
(testDateFromString):

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

8 years agoUnreviewed gardening for GTK.
svillar@igalia.com [Mon, 7 Apr 2014 17:33:16 +0000 (17:33 +0000)]
Unreviewed gardening for GTK.

Removed tests that have been actually passing in both release and
debug bots for some time.

* platform/gtk-wk2/TestExpectations:
* platform/gtk/TestExpectations:

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

8 years ago[CSS Shapes] Clean up invalid FIXME
zoltan@webkit.org [Mon, 7 Apr 2014 17:15:31 +0000 (17:15 +0000)]
[CSS Shapes] Clean up invalid FIXME
https://bugs.webkit.org/show_bug.cgi?id=131304

Reviewed by Andreas Kling.

No new tests, no behavior change.

* page/animation/CSSPropertyAnimation.cpp:
(WebCore::blendFunc):

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

8 years agoUnreviewed update of GTK expectations.
svillar@igalia.com [Mon, 7 Apr 2014 16:30:53 +0000 (16:30 +0000)]
Unreviewed update of GTK expectations.

Canvas composite tests with alpha are not working.

* platform/gtk/TestExpectations:

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

8 years ago[EFL] Turn on ENABLE_MEDIA_CONTROLS_SCRIPT
ryuan.choi@samsung.com [Mon, 7 Apr 2014 12:34:25 +0000 (12:34 +0000)]
[EFL] Turn on ENABLE_MEDIA_CONTROLS_SCRIPT
https://bugs.webkit.org/show_bug.cgi?id=131257

Reviewed by Gyuyoung Kim.

.:

* Source/cmake/OptionsEfl.cmake: Enable MEDIA_CONTROLS_SCRIPT

Source/WebCore:

no new tests. just rebased exisiting tests.

* PlatformEfl.cmake: Added the media controls script associated files.
* css/mediaControlsEfl.css: Removed.
* css/mediaControlsEflFullscreen.css: Removed.
* platform/efl/DefaultTheme/CMakeLists.txt:
* platform/efl/DefaultTheme/default.edc:
* platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/enterfullscreenbutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/exitfullscreenbutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/fullscreen_button.edc: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/mute_button.edc: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/mutebutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/unmutebutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/pausebutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/playbutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/playpause_button.edc: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/seekbackwardbutton/seekbackward_button.edc: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/seekbackwardbutton/seekbackwardbutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/seekforwardbutton/seekforward_button.edc: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/seekforwardbutton/seekforwardbutton.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/closedcaption.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/closedcaption_disabled.png: Removed.
* platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/toggle_captions_button.edc: Removed.
* platform/efl/RenderThemeEfl.cpp:
(WebCore::toEdjeGroup):
(WebCore::RenderThemeEfl::RenderThemeEfl):
(WebCore::RenderThemeEfl::adjustSliderThumbSize):
(WebCore::RenderThemeEfl::mediaControlsStyleSheet): Modified to load bundle style sheet.
(WebCore::RenderThemeEfl::mediaControlsScript): Added to load bundle scripts.
(WebCore::RenderThemeEfl::emitMediaButtonSignal): Deleted.
(WebCore::RenderThemeEfl::extraMediaControlsStyleSheet): Deleted.
(WebCore::RenderThemeEfl::extraFullScreenStyleSheet): Deleted.
(WebCore::RenderThemeEfl::formatMediaControlsCurrentTime): Deleted.
(WebCore::RenderThemeEfl::hasOwnDisabledStateHandlingFor): Deleted.
(WebCore::RenderThemeEfl::paintMediaFullscreenButton): Deleted.
(WebCore::RenderThemeEfl::paintMediaMuteButton): Deleted.
(WebCore::RenderThemeEfl::paintMediaPlayButton): Deleted.
(WebCore::RenderThemeEfl::paintMediaSeekBackButton): Deleted.
(WebCore::RenderThemeEfl::paintMediaSeekForwardButton): Deleted.
(WebCore::RenderThemeEfl::paintMediaSliderTrack): Deleted.
(WebCore::RenderThemeEfl::paintMediaSliderThumb): Deleted.
(WebCore::RenderThemeEfl::paintMediaVolumeSliderContainer): Deleted.
(WebCore::RenderThemeEfl::paintMediaVolumeSliderTrack): Deleted.
(WebCore::RenderThemeEfl::paintMediaVolumeSliderThumb): Deleted.
(WebCore::RenderThemeEfl::paintMediaCurrentTime): Deleted.
(WebCore::RenderThemeEfl::supportsClosedCaptioning): Deleted.
(WebCore::RenderThemeEfl::paintMediaToggleClosedCaptionsButton): Deleted.
* platform/efl/RenderThemeEfl.h:

LayoutTests:

Rebased tests.

* platform/efl/TestExpectations:
* platform/efl/media/audio-controls-rendering-expected.png:
* platform/efl/media/audio-controls-rendering-expected.txt:
* platform/efl/media/controls-after-reload-expected.png:
* platform/efl/media/controls-after-reload-expected.txt:
* platform/efl/media/controls-strict-expected.png:
* platform/efl/media/controls-strict-expected.txt:
* platform/efl/media/controls-styling-expected.png:
* platform/efl/media/controls-styling-expected.txt:
* platform/efl/media/controls-without-preload-expected.png:
* platform/efl/media/controls-without-preload-expected.txt:

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

8 years agoUnreviewed gardening.
svillar@igalia.com [Mon, 7 Apr 2014 09:14:40 +0000 (09:14 +0000)]
Unreviewed gardening.

Updated expectations for GTK. Added some more failing AX tests.

* platform/gtk-wk2/TestExpectations:

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

8 years agoCSS JIT: change the node flags directly instead of using function calls when possible
benjamin@webkit.org [Mon, 7 Apr 2014 08:52:45 +0000 (08:52 +0000)]
CSS JIT: change the node flags directly instead of using function calls when possible
https://bugs.webkit.org/show_bug.cgi?id=131292

Reviewed by Andreas Kling.

For historical reasons, changing the node flags was always done with function calls.
This patch changes those calls to modify the nodes directly.

* cssjit/SelectorCompiler.cpp:
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
(WebCore::SelectorCompiler::setNodeFlag):
(WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
(WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByLastChildRules): Deleted.
(WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByFirstChildAndLastChildRules): Deleted.
* dom/Element.cpp:
(WebCore::Element::setChildrenAffectedByFirstChildRules): Deleted.
(WebCore::Element::setChildrenAffectedByDirectAdjacentRules): Deleted.
* dom/Element.h:
* dom/Node.h:
(WebCore::Node::flagChildrenAffectedByFirstChildRulesFlag):
(WebCore::Node::flagChildrenAffectedByLastChildRulesFlag):
(WebCore::Node::flagChildrenAffectedByDirectAdjacentRulesFlag):

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

8 years agoRemove unused header from PlatformSpeechSynthesizer.h
k.czech@samsung.com [Mon, 7 Apr 2014 08:18:36 +0000 (08:18 +0000)]
Remove unused header from PlatformSpeechSynthesizer.h
https://bugs.webkit.org/show_bug.cgi?id=131103

Reviewed by Anders Carlsson.

Since WebSpeech has switched to use std::unique_ptr, we do not need to include PassOwnPtr.

No new tests. No behaviour change, just quick fix.

* platform/PlatformSpeechSynthesizer.h:

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

8 years agoUnreviewed gardening.
svillar@igalia.com [Mon, 7 Apr 2014 07:55:22 +0000 (07:55 +0000)]
Unreviewed gardening.

Updated expectations for GTK. Added some failing AX tests.

* platform/gtk-wk2/TestExpectations:

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

8 years ago[CSSRegions] Use RenderRegion::isValid() before using a region
mihnea@adobe.com [Mon, 7 Apr 2014 06:38:03 +0000 (06:38 +0000)]
[CSSRegions] Use RenderRegion::isValid() before using a region
https://bugs.webkit.org/show_bug.cgi?id=131232

Reviewed by Andreas Kling.

Source/WebCore:

RenderRegion method isValid() should be used to test whether a region
is good to use instead of a mix between isValid() and flowThread().
When the region is designed to fragment content from a parent flow thread,
the m_flowThread is not nullified anymore, thus ensuring the same treatment for all invalid
regions.
Covered by existing regions tests.

* inspector/InspectorOverlay.cpp:
(WebCore::buildObjectForElementInfo):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::layoutOverflowRectForPropagation):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::updateLayerPositions):
(WebCore::RenderLayer::paintLayer):
(WebCore::RenderLayer::hitTestLayer):
(WebCore::RenderLayer::calculateClipRects):
* rendering/RenderNamedFlowFragment.cpp:
(WebCore::RenderNamedFlowFragment::pageLogicalHeight):
(WebCore::RenderNamedFlowFragment::maxPageLogicalHeight):
* rendering/RenderNamedFlowThread.cpp:
(WebCore::RenderNamedFlowThread::getRanges):
(WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
(WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::RenderRegion):
(WebCore::RenderRegion::positionForPoint):
(WebCore::RenderRegion::pageLogicalWidth):
(WebCore::RenderRegion::pageLogicalHeight):
(WebCore::RenderRegion::styleDidChange):
(WebCore::RenderRegion::installFlowThread):
(WebCore::RenderRegion::attachRegion):
(WebCore::RenderRegion::detachRegion):
(WebCore::RenderRegion::ensureOverflowForBox):
(WebCore::RenderRegion::renderBoxRegionInfo):

LayoutTests:

Adjust test expectation now that an invalid region is not unnecessary repainted.

* fast/regions/repaint/invalid-region-repaint-crash-expected.txt:

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

8 years ago[EFL][WK1] Apply std::unique_ptr<> to NavigatorContentUtilsClientEfl
gyuyoung.kim@samsung.com [Mon, 7 Apr 2014 05:24:42 +0000 (05:24 +0000)]
[EFL][WK1] Apply std::unique_ptr<> to NavigatorContentUtilsClientEfl
https://bugs.webkit.org/show_bug.cgi?id=130958

Reviewed by Darin Adler.

As a step of replacing OwnPtr with std::unique_ptr, this patch replaces
OwnPtr with the std::unique_ptr for NavigatorContentUtilsClientEfl.

* WebCoreSupport/NavigatorContentUtilsClientEfl.cpp:
(WebCore::NavigatorContentUtilsClientEfl::create): Deleted.
* WebCoreSupport/NavigatorContentUtilsClientEfl.h:
* ewk/ewk_view.cpp:
(_ewk_view_priv_new):

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

8 years agoFix the debug bots after r166863
benjamin@webkit.org [Mon, 7 Apr 2014 05:07:52 +0000 (05:07 +0000)]
Fix the debug bots after r166863

* css/PageRuleCollector.cpp:
(WebCore::checkPageSelectorComponents): I forgot to update one call site for PagePseudoClass.

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

8 years agoMake some bindings improvements, with smaller code size for error message generation
darin@apple.com [Mon, 7 Apr 2014 03:43:40 +0000 (03:43 +0000)]
Make some bindings improvements, with smaller code size for error message generation
https://bugs.webkit.org/show_bug.cgi?id=131285

Reviewed by Andreas Kling.

Source/WebCore:

* WebCore.exp.in: Updated to remove old and add new functions, for use by the Internals
JavaScript bindings.

* bindings/js/JSDOMBinding.cpp:
(WebCore::makeDOMBindingsTypeErrorStringInternal): Deleted.
(WebCore::throwTypeError): Added. Helper to avoid repeating throwVMError/createTypeError.
(WebCore::appendArgumentMustBe): Added. Helper for building up argument error strings.
(WebCore::reportDeprecatedGetterError): Added. For bindings to use.
(WebCore::throwArgumentMustBeEnumError): Ditto.
(WebCore::throwArgumentMustBeFunctionError): Ditto.
(WebCore::throwArgumentTypeError): Ditto.
(WebCore::throwArrayElementTypeError): Ditto.
(WebCore::throwAttributeTypeError): Ditto.
(WebCore::throwConstructorDocumentUnavailableError): Ditto.
(WebCore::throwGetterTypeError): Ditto.
(WebCore::throwSequenceTypeError): Ditto.
(WebCore::throwSetterTypeError): Ditto.
(WebCore::throwThisTypeError): Ditto.

* bindings/js/JSDOMBinding.h: Added declarations for new functions. Removed forward
declarations for things not used in this file. Use nullptr instead of 0. Format
templates consistently. Use a better for loop in the jsArray function. Removed
unused HasMemoryCostMemberFunction, makeDOMBindingsTypeErrorString, and
makeDOMBindingsTypeErrorStringInternal.

* bindings/js/JSNavigatorCustom.cpp: Fixed a hand-written binding that was using
makeDOMBindingsTypeErrorString to make a string.

* bindings/js/ScriptController.h: Updated forward declarations.

* bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation): Cut down on use of UNUSED_PARAM. Use the new functions
for errors, keeping the code in the generated file to a minimum.
(GenerateParametersCheck): Ditto.
(GenerateConstructorDefinition): Ditto.

* bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
* bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
* bindings/scripts/test/JS/JSTestEventConstructor.cpp:
* bindings/scripts/test/JS/JSTestEventTarget.cpp:
* bindings/scripts/test/JS/JSTestException.cpp:
* bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
* bindings/scripts/test/JS/JSTestInterface.cpp:
* bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
* bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
* bindings/scripts/test/JS/JSTestNode.cpp:
* bindings/scripts/test/JS/JSTestObj.cpp:
* bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
* bindings/scripts/test/JS/JSTestTypedefs.cpp:
* bindings/scripts/test/JS/JSattribute.cpp:
* bindings/scripts/test/JS/JSreadonly.cpp:
Updated expected results for changes above.

Source/WebKit:

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Updated for
changes in JavaScript binding functions.

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

8 years agoMove the PseudoPageClass types out of the pseudo element/class mix
benjamin@webkit.org [Mon, 7 Apr 2014 02:28:54 +0000 (02:28 +0000)]
Move the PseudoPageClass types out of the pseudo element/class mix
https://bugs.webkit.org/show_bug.cgi?id=131284

Reviewed by Darin Adler.

Some more cleanup of Selector's pseudo types. This patch moves the page pseudo
class types into their own enumeration (PagePseudoClassType).

* css/CSSParserValues.cpp:
(WebCore::CSSParserSelector::parsePagePseudoSelector):
* css/CSSSelector.cpp:
(WebCore::CSSSelector::specificityForPage):
(WebCore::CSSSelector::pseudoId):
(WebCore::CSSSelector::selectorText):
* css/CSSSelector.h:
(WebCore::CSSSelector::setPagePseudoType):
(WebCore::CSSSelector::pagePseudoClassType):
* css/PageRuleCollector.cpp:
(WebCore::checkPageSelectorComponents):
* cssjit/SelectorCompiler.cpp:
(WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):

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

8 years agoCSS JIT: add support for :last-child and :only-child
benjamin@webkit.org [Mon, 7 Apr 2014 02:25:19 +0000 (02:25 +0000)]
CSS JIT: add support for :last-child and :only-child
https://bugs.webkit.org/show_bug.cgi?id=131283

Reviewed by Andreas Kling.

This is the straightforward implementation of :last-child and :only-child.

Both are extremely similar to :first-child. There are only minor differences:
-:last-child has an additional check for the flag IsParsingChildrenFinished.
-:only-child is like :first-child + :last-child but with combined marking.

* cssjit/SelectorCompiler.cpp:
(WebCore::SelectorCompiler::addPseudoType):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToNextAdjacentElement):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
(WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoPreviousAdjacentElement):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
(WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoNextAdjacentElement):
(WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByLastChildRules):
(WebCore::SelectorCompiler::setLastChildState):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
(WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByFirstChildAndLastChildRules):
(WebCore::SelectorCompiler::setOnlyChildState):
(WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
* dom/Node.h:
(WebCore::Node::nextSiblingMemoryOffset):
(WebCore::Node::flagIsParsingChildrenFinished):
* rendering/style/RenderStyle.h:
Removed the unused flags, I will add them back later as needed.

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

8 years agoClean up WKGestureTypes.h
mitz@apple.com [Mon, 7 Apr 2014 00:54:14 +0000 (00:54 +0000)]
Clean up WKGestureTypes.h
https://bugs.webkit.org/show_bug.cgi?id=131286

Reviewed by Sam Weinig.

Renamed WKGestureTypes.h to GestureTypes.h, dropped the useless “WK” prefixes and changed
into scoped enums, with the exception of SelectionFlags.

* Shared/ios/GestureTypes.h: Copied from Source/WebKit2/Shared/ios/WKGestureTypes.h.
* Shared/ios/WKGestureTypes.h: Removed.
* UIProcess/API/Cocoa/_WKElementAction.mm:
(copyElement):
(saveImage):
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::didUpdateBlockSelectionWithTouch):
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _performAction:]):
(toGestureType):
(toUIWKGestureType):
(toSelectionTouch):
(toUIWKSelectionTouch):
(toGestureRecognizerState):
(toUIGestureRecognizerState):
(toUIWKSelectionFlags):
(toSelectionHandlePosition):
(selectionChangedWithGesture):
(selectionChangedWithTouch):
(-[WKContentView _didUpdateBlockSelectionWithTouch:withFlags:growThreshold:shrinkThreshold:]):
(-[WKContentView changeSelectionWithGestureAt:withGesture:withState:]):
(-[WKContentView changeSelectionWithTouchAt:withSelectionTouch:baseIsStart:]):
(-[WKContentView changeSelectionWithTouchesFrom:to:withGesture:withState:]):
(-[WKContentView changeBlockSelectionWithTouchAt:withSelectionTouch:forHandle:]):
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::rangeForWebSelectionAtPosition):
(WebKit::WebPage::selectWithGesture):
(WebKit::distanceBetweenRectsForPosition):
(WebKit::computeEdgeCenter):
(WebKit::WebPage::expandedRangeFromHandle):
(WebKit::WebPage::contractedRangeFromHandle):
(WebKit::WebPage::computeExpandAndShrinkThresholdsForHandle):
(WebKit::shouldExpand):
(WebKit::WebPage::changeBlockSelection):
(WebKit::WebPage::updateBlockSelectionWithTouch):
(WebKit::WebPage::updateSelectionWithTouches):
(WebKit::WebPage::performActionOnElement):

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

8 years agoSource/WebCore: Rework CSS calc logic, fixing some reference count mistakes in Length
darin@apple.com [Mon, 7 Apr 2014 00:16:35 +0000 (00:16 +0000)]
Source/WebCore: Rework CSS calc logic, fixing some reference count mistakes in Length
https://bugs.webkit.org/show_bug.cgi?id=131280
rdar://problem/16400823

Reviewed by Andreas Kling.

New unit test in TestWebKitAPI.

Changed the classes related to CSS "calc" to make the code a bit easier to read by
moving code out of class definitions. Also used final some more, made more things private,
used references instead of pointers, and other such changes. Biggest change, though, is to
Length, which had a broken system for managing reference counted calculated objects.
There were multiple bugs including a basic design mistake of not having a reference count
and trying to use the reference count in the object itself. Fixed and covered by the unit
test now; test found multiple problems in both the old and new implementations.

* WebCore.exp.in: Updated exports, including symbols to make the unit test practical.

* WebCore.xcodeproj/project.pbxproj: Made CalculationValue.h a Private file so it can
be used in a unit test. Also let Xcode update the file type for a gperf file.

* css/CSSCalculationValue.cpp:
(WebCore::CSSCalcValue::equals): Updated since m_expression is a Ref now.
(WebCore::CSSCalcValue::clampToPermittedRange): Marked inline and updated for data member
name change.
(WebCore::isIntegerResult): Changed argument order to put the operator first and use
references instead of pointers. Also marked inline.
(WebCore::createBlendHalf): Added. Helper to make the other functions more readable.
(WebCore::createExpressionNode): Made non-member function private to this file. Also made
many small improvements.
(WebCore::CSSCalcValue::create): Updated so both of these call the same constructor.

* css/CSSCalculationValue.h: Cut down CSSCalcValue class by making more things private
and deleting unneeded things. Also use Ref instead of RefPtr.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::getPositionOffsetValue): Use isFixed function instead of type function.

* css/CSSGradientValue.cpp:
(WebCore::CSSGradientValue::addStops): Updated code since toCalcValue now returns PassRef
instead of PassRefPtr. Unfortunately the new code is a bit more verbose.
(WebCore::positionFromValue): Ditto.

* css/CSSParser.cpp:
(WebCore::CSSParser::parseCalculation):

* css/CSSPrimitiveValue.cpp:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Updated to pass reference rather than pointer.
(WebCore::CSSPrimitiveValue::init): Ditto.

* css/CSSToStyleMap.h: Removed unneeded include of LengthBox.h.

* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyLength::applyValue): Updated for function name change.
(WebCore::ApplyPropertyBorderRadius::applyValue): Removed extra parentheses.
(WebCore::ApplyPropertyFontSize::applyValue): Ditto. Also updated since toCalcValue returns Ref.

* css/LengthFunctions.cpp:
(WebCore::floatValueForLength): Updated to call value instead of getFloatValue; both are the same.

* css/StyleResolver.cpp:
(WebCore::addIntrinsicMargins): Updated for function name change.
(WebCore::createGridTrackBreadth): Ditto.

* platform/CalculationValue.cpp:
(WebCore::CalculationValue::create): Changed to return PassRef.
(WebCore::CalcExpressionNumber::evaluate): Moved this function out of the header, since it's
virtual and not really going to be inlined.
(WebCore::CalcExpressionNumber::operator==): Ditto.
(WebCore::CalculationValue::evaluate): Ditto.
(WebCore::CalcExpressionBinaryOperation::operator==): Ditto.
(WebCore::CalcExpressionLength::evaluate): Ditto.
(WebCore::CalcExpressionLength::operator==): Ditto.
(WebCore::CalcExpressionBlendLength::evaluate): Ditto.
(WebCore::CalcExpressionBlendLength::operator==): Ditto.

* platform/CalculationValue.h: Moved most functions out of the class bodies so the classes are
easier to see. Made all the == operator functions non-member ones except for the polymorphic
one from the base class. Changed the casting functions to work on references instead of pointers.
Tweaked name of some members.

* platform/Length.cpp: Reworked the CalculationValueMap (formerly CalculationValueHandleMap) to
use unsigned instead of int, and store reference counts in the map rather than trying to share the
reference count of the underlying CalculationValue object, which can lead to storage leaks where
handles end up in the map permanently.
(WebCore::calculationValues): Use NeverDestroyed instead of DEPRECATED_DEFINE_STATIC_LOCAL.
(WebCore::Length::Length): Updated some data member names.
(WebCore::Length::calculationValue): Updated to return a reference instead of a PassRefPtr.
(WebCore::Length::ref): Renamed and updated for new interface to the map.
(WebCore::Length::deref): Ditto.
(WebCore::Length::nonNanCalculatedValue): Updated to use a reference instead of a pointer.
(WebCore::Length::isCalculatedEqual): Updated since this is now only called if both objects are
known to be calculated values.

* platform/Length.h: Moved most functions out of the class definition to make the class definition
easier to read. Reworked the constructors and assignment operators to handle the reference counting
correctly. Added various FIXMEs and assertions. Removed some unused functions, made others private.

* platform/LengthBox.h: Renamed some one-letter arguments to use words instead.

* rendering/AutoTableLayout.cpp:
(WebCore::AutoTableLayout::recalcColumn): Updated for change to Length::setValue.
* rendering/FixedTableLayout.cpp:
(WebCore::FixedTableLayout::calcWidthArray): Ditto.

* rendering/style/FillLayer.h:
(WebCore::FillLayer::initialFillXPosition): Updated to not convert a double to a float at runtime.
(WebCore::FillLayer::initialFillYPosition): Ditto.

* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::setWordSpacing): Removed a bogus FALLTHROUGH that was clearly wrong, but
harmless. Updated for changes to Length.

* rendering/style/RenderStyle.h: Updated for name changes and to avoid converting doubles to floats
at runtime.

Tools: Rework CSS calc logic, fixing some reference count mistakes in Length
https://bugs.webkit.org/show_bug.cgi?id=131280

Reviewed by Andreas Kling.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: Added CalculationValue.cpp.
* TestWebKitAPI/Tests/WebCore/CalculationValue.cpp: Added.

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

8 years agoSource/WebKit/mac: Document user content related APIs
weinig@apple.com [Sun, 6 Apr 2014 23:41:10 +0000 (23:41 +0000)]
Source/WebKit/mac: Document user content related APIs

Reviewed by Anders Carlsson.

* MigrateHeaders.make:

Source/WebKit2: Document user content related APIs..

Reviewed by Anders Carlsson.

- Also demote WKScriptWorld to SPI.

* UIProcess/API/Cocoa/WKScriptMessage.h:
* UIProcess/API/Cocoa/WKScriptMessage.mm:
(-[WKScriptMessage _scriptWorld]):
(-[WKScriptMessage scriptWorld]): Deleted.
* UIProcess/API/Cocoa/WKScriptMessageHandler.h:
* UIProcess/API/Cocoa/WKScriptMessagePrivate.h: Added.
* UIProcess/API/Cocoa/WKScriptWorld.h: Removed.
* UIProcess/API/Cocoa/WKScriptWorld.mm: Removed.
* UIProcess/API/Cocoa/WKUserContentController.h:
* UIProcess/API/Cocoa/WKUserContentController.mm:
(-[WKUserContentController addScriptMessageHandler:name:]):
(-[WKUserContentController removeScriptMessageHandlerForName:]):
(-[WKUserContentController _addScriptMessageHandler:name:world:]):
(-[WKUserContentController _removeScriptMessageHandlerForName:world:]):
(-[WKUserContentController addScriptMessageHandler:name:world:]): Deleted.
(-[WKUserContentController removeScriptMessageHandlerForName:world:]): Deleted.
* UIProcess/API/Cocoa/WKUserContentControllerPrivate.h: Added.
* UIProcess/API/Cocoa/_WKScriptWorld.h: Copied from WebKit2/UIProcess/API/Cocoa/WKScriptWorld.h.
* UIProcess/API/Cocoa/_WKScriptWorld.mm: Copied from WebKit2/UIProcess/API/Cocoa/WKScriptWorld.mm.
(+[_WKScriptWorld defaultWorld]):
(+[WKScriptWorld defaultWorld]): Deleted.
* WebKit2.xcodeproj/project.pbxproj:

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

8 years agoHonor System-Level User Preferences for Caption Display
bfulgham@apple.com [Sun, 6 Apr 2014 23:21:46 +0000 (23:21 +0000)]
Honor System-Level User Preferences for Caption Display
https://bugs.webkit.org/show_bug.cgi?id=131258

Reviewed by Eric Carlson.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::setSelectedTextTrack): Allow preferenced change to fully dispatch
so we can properly deal with captions being turned off.
(WebCore::HTMLMediaElement::captionPreferencesChanged): Use 'webkit' variant of the
setWebKitClosedCaptionsVisible method so we properly adjust settings needed for the JS API call.
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlTextTrackContainerElement::updateDisplay): When captions are turned off, e.g.
because the user turned off the preference, don't inadvertently turn them back on just bacause there
was an existing track that was not in a 'hidden' state.

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

8 years agoUnreviewed speculative 32-bit buildfix after r166837.
ossy@webkit.org [Sun, 6 Apr 2014 22:12:09 +0000 (22:12 +0000)]
Unreviewed speculative 32-bit buildfix after r166837.

* heap/Heap.cpp:
(JSC::Heap::updateObjectCounts):

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

8 years agoWeb Replay: add methods to encode a frame's index based on its FrameTree position
burg@cs.washington.edu [Sun, 6 Apr 2014 21:51:34 +0000 (21:51 +0000)]
Web Replay: add methods to encode a frame's index based on its FrameTree position
https://bugs.webkit.org/show_bug.cgi?id=131281

Reviewed by Timothy Hatcher.

Given a frame, its encoded index is computed by traversing the frame tree
and saving how many nodes have been traversed to reach a given frame.

This is used to disambiguate frames when dispatching frame-specific event
loop inputs during replay, such as timers and resource loaders.

* replay/SerializationMethods.cpp:
(WebCore::frameIndexFromDocument): Added.
(WebCore::frameIndexFromFrame): Added.
(WebCore::documentFromFrameIndex): Added.
(WebCore::frameFromFrameIndex): Added.
* replay/SerializationMethods.h:

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

8 years agoiOS build fix.
ap@apple.com [Sun, 6 Apr 2014 21:48:04 +0000 (21:48 +0000)]
iOS build fix.

* WebCore.exp.in: Move newly exported function to a right section of this file.

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

8 years agoFix change log dates and a small editing mistake in last patch
darin@apple.com [Sun, 6 Apr 2014 21:14:00 +0000 (21:14 +0000)]
Fix change log dates and a small editing mistake in last patch

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

8 years agoRefactor post-attach and HTMLObjectElement-related code
darin@apple.com [Sun, 6 Apr 2014 20:27:07 +0000 (20:27 +0000)]
Refactor post-attach and HTMLObjectElement-related code
https://bugs.webkit.org/show_bug.cgi?id=131282

Reviewed by Antti Koivisto.

Source/WebCore:

* dom/ContainerNode.cpp: Moved the post-attach callback code from here to
StyleResolveTree.h/cpp.
* dom/ContainerNode.h: Ditto.

* dom/Document.cpp:
(WebCore::Document::recalcStyle): Use Style::PostResolutionCallbackDisabler instead of
PostAttachCallbackDisabler.

* dom/Element.h: Moved the post-attach callback code from here to StyleResolveTree.h/cpp.

* html/HTMLEmbedElement.cpp:
(WebCore::HTMLEmbedElement::parseAttribute): Simplified the code for typeAttr, turning
it into a 1-liner. Added a FIXME in codeAttr about the fact that it does not have the
code to trigger image loads.

* html/HTMLFormControlElement.cpp:
(WebCore::HTMLFormControlElement::didAttachRenderers): Updated to use
Style::queuePostResolutionCallback and use a lambda instead of a function.
(WebCore::HTMLFormControlElement::didRecalcStyle): Ditto. Also added RefPtr instead
of just using wishful thinking to keep the object alive.
* html/HTMLFrameOwnerElement.cpp:
(WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc): Ditto.

* html/HTMLObjectElement.cpp:
(WebCore::HTMLObjectElement::parseAttribute):: Simplified the code for typeAttr, turning
it into a 1-liner. Made dataAttr call setNeedsWidgetUpdate(true) unconditionally after
checking carefully to see that's harmless if there is no renderer. Changed classidAttr
to call setNeedsWidgetUpdate(true) unconditionally and not set m_classId.
(WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Use fastGetAttribute
instead of classId and descendantsOfType instead of getElementsByTagName.
(WebCore::HTMLObjectElement::hasValidClassId): Use fastGetAttribute instead of classId.
(WebCore::HTMLObjectElement::renderFallbackContent): Use imageLoader instead of m_imageLoader.

* html/HTMLObjectElement.h: Removed classId, since there is no reason to cache that
attribute in a data member. Rearranged header, making more private, and fixing some typos,
and doing a "using" instead of a function to disambiguate the inherited form functions.

* html/HTMLPlugInImageElement.cpp:
(WebCore::HTMLPlugInImageElement::createElementRenderer): Fixed some code that assumed the
first child of the shadow root is guaranteed to be an element.
(WebCore::HTMLPlugInImageElement::didMoveToNewDocument): Removed null check on oldDocument,
since m_needsDocumentActivationCallbacks can't be true if the old document was null.
(WebCore::is100Percent): Added helper to make function below more readable.
(WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Restructured the code a
bit. The part that attracted my attention was the local variable of type RenderBox, which
was named renderEmbeddedObject. Turns out the caller guarantees to only call this if there
is a renderer of type RenderEmbeddedObject, so depend on that.

* html/HTMLPlugInImageElement.h: Trimmed includes a bit. Made more members private.
Marked more function members final. Made a protected imageLoader function so that
m_imageLoader can be private eventually. Made m_imageLoader be std::unique_ptr.

* style/StyleResolveTree.cpp:
(WebCore::Style::needsPseudoElement): Fixed spelling error in the name of this function.
(WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded): Updated for name change.
(WebCore::Style::attachRenderTree): Update for new name of PostResolutionCallbackDisabler.
(WebCore::Style::updateBeforeOrAfterPseudoElement): Updated for name change.
(WebCore::Style::postResolutionCallbackQueue): Added.
(WebCore::Style::queuePostResolutionCallback): Added.
(WebCore::Style::suspendMemoryCacheClientCalls): Added. This is a side effect of the original
PostAttachCallbackDisabler that is now done in a cleaner way, using the callback queue, instead
of as a special case. It should not work for multiple documents across multiple pages instead of
only the outermost one.
(WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Added.
Calls suspendMemoryCacheClientCalls, but a FIXME tries to point out why that isn't so great.
(WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Added.
(WebCore::Style::postResolutionCallbacksAreSuspended): Added.

* style/StyleResolveTree.h: Added queuePostResolutionCallback and
postResolutionCallbacksAreSuspended. Also added PostResolutionCallbackDisabler, which should
eventually become a private implementation detail.

Source/WebKit/mac:

* WebCoreSupport/WebFrameLoaderClient.mm: Call toHTMLPlugInImageElement instead of
doing a static_cast.

LayoutTests:

* svg/custom/object-no-size-attributes-expected.txt: Removed expectation of an empty text
renderer from the render tree.
* svg/custom/object-no-size-attributes.xhtml: Restructured the source so there is no text
to render. Without this, we were seeing two text renderers due to the loading timing change.

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

8 years ago32-bit build fix.
mitz@apple.com [Sun, 6 Apr 2014 20:20:12 +0000 (20:20 +0000)]
32-bit build fix.

* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::setInputCursor):

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

8 years agoEnable WEB_REPLAY for PLATFORM(MAC)
burg@cs.washington.edu [Sun, 6 Apr 2014 17:28:20 +0000 (17:28 +0000)]
Enable WEB_REPLAY for PLATFORM(MAC)
https://bugs.webkit.org/show_bug.cgi?id=130700

Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Switch on WEB_REPLAY feature flag for non-production builds.

* Configurations/FeatureDefines.xcconfig:
* replay/ReplayInputDispatchMethods.cpp: Fix the ENABLE(WEB_REPLAY) build.
It was broken by the bool to enum refactoring in r166684.
(WebCore::InitialNavigation::dispatch):

Source/WebInspectorUI:

If the ReplayAgent is available, then add an option to toggle between the
replay interface and normal Timeline interface from the timeline
sidebar panel. The option is available through a context menu item on the
sidebar panel's top navigation bar.

If web replay not available, just show the non-replay interface.

* Localizations/en.lproj/localizedStrings.js:
* UserInterface/Base/Main.js: Add WebInspector.showReplayInterfaceSetting.
(WebInspector.loaded):

* UserInterface/Views/TimelineSidebarPanel.js: Unconditionally create the replay
interface elements, but only show them if showReplayInterfaceSetting is enabled.
(WebInspector.TimelineSidebarPanel.prototype._updateReplayInterfaceVisibility): Added
(WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar.toggleReplayInterface): Added.
(WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar): Added.

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

Tools:

* Scripts/webkitperl/FeatureList.pm: Set the default for WEB_REPLAY for OS X engineering builds.

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