⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Dec 3, 2015:

11:45 PM Changeset in webkit [193412] by Carlos Garcia Campos
  • 2 edits in trunk/Tools

[GTK] Test /webkit2/WebKitWebResource/get-data is flaky
https://bugs.webkit.org/show_bug.cgi?id=151797

Reviewed by Martin Robinson.

Since we switched to use the network process to run the unit tests
the test /webkit2/WebKitWebResource/get-data sometimes fails and
sometimes passes. We are now also getting the notification for the
css image. Since we wait for 3 resources, sometimes the css image
is loaded before and then checkResourceData is called for it, but
not handled. When the css image is the last one loaded the test
passes. So, we just need to wait for the 4 resources.

  • TestWebKitAPI/Tests/WebKit2Gtk/TestResources.cpp:

(testWebResourceGetData):

10:40 PM Changeset in webkit [193411] by beidson@apple.com
  • 4 edits
    3 deletes in trunk/LayoutTests

Modern IDB: Fix up tests that refer to non-standard IDBVersionChangeEvent.dataLoss.
https://bugs.webkit.org/show_bug.cgi?id=151850

Reviewed by Andy Estes.

  • platform/mac-wk1/TestExpectations:
  • storage/indexeddb/data-corruption-expected.txt: Removed.
  • storage/indexeddb/data-corruption.html: Removed.
  • storage/indexeddb/resources/data-corruption.js: Removed.
  • storage/indexeddb/events-expected.txt:
  • storage/indexeddb/resources/events.js:
9:55 PM Changeset in webkit [193410] by beidson@apple.com
  • 4 edits in trunk

Modern IDB: storage/indexeddb/cursor-index-delete.html fails.
https://bugs.webkit.org/show_bug.cgi?id=151847

Reviewed by Andy Estes.

Source/WebCore:

No new tests (At least one failing test now passes).

  • Modules/indexeddb/server/MemoryIndexCursor.cpp:

(WebCore::IDBServer::MemoryIndexCursor::MemoryIndexCursor):
(WebCore::IDBServer::MemoryIndexCursor::currentData):

LayoutTests:

  • platform/mac-wk1/TestExpectations:
9:24 PM Changeset in webkit [193409] by ddkilzer@apple.com
  • 2 edits in trunk/Tools

DumpRenderTree: Use-after-free in createBitmapContext() in PixelDumpSupportMac.mm
<http://webkit.org/b/151845>

Reviewed by Simon Fraser.

Fixes the following static analyzer warning:

DumpRenderTree/mac/PixelDumpSupportMac.mm:67:9: warning: Use of memory after it is freed

WTFLogAlways("DumpRenderTree: CGBitmapContextCreate(%p, %llu, %llu, 8, %llu, %p, 0x%x) failed\n", buffer, pixelsHigh, pixelsWide, rowBytes, colorSpace.get(), kCGImageAlphaPremultipliedFirst | kCGBitmapByteOrder32Host);

  • DumpRenderTree/mac/PixelDumpSupportMac.mm:

(createBitmapContext): Free 'buffer' after using it in logging
to fix the use-after-free. Assign a value of nullptr to buffer
so we don't return with it set to a freed address.

9:21 PM Changeset in webkit [193408] by Gyuyoung Kim
  • 11 edits in trunk/Source/WebCore

Reduce uses of PassRefPtr in DOM - 1
https://bugs.webkit.org/show_bug.cgi?id=149788

Reviewed by Darin Adler.

As a step to purge PassRefPtr, this patch reduces the uses in WebCore/dom.

  • dom/ChildListMutationScope.cpp:

(WebCore::ChildListMutationAccumulator::getOrCreate):

  • dom/ChildListMutationScope.h:
  • dom/ClipboardEvent.cpp:

(WebCore::ClipboardEvent::ClipboardEvent):

  • dom/ClipboardEvent.h:
  • dom/CompositionEvent.cpp:

(WebCore::CompositionEvent::CompositionEvent):
(WebCore::CompositionEvent::initCompositionEvent):

  • dom/CompositionEvent.h:
  • dom/DOMNamedFlowCollection.cpp:

(WebCore::DOMNamedFlowCollection::item):

  • dom/DOMNamedFlowCollection.h:
  • dom/DOMStringList.h:
  • dom/DeviceMotionController.cpp:

(WebCore::DeviceMotionController::getLastEvent):

  • dom/DeviceMotionController.h:
  • dom/DeviceOrientationController.cpp:

(WebCore::DeviceOrientationController::getLastEvent):

  • dom/DeviceOrientationController.h:
  • editing/Editor.cpp:

(WebCore::Editor::dispatchCPPEvent):

  • page/DeviceController.h:

(WebCore::DeviceController::getLastEvent):

8:51 PM Changeset in webkit [193407] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Allow index.html indexes again.

  • .htaccess:
8:48 PM Changeset in webkit [193406] by timothy@apple.com
  • 1 edit
    121 deletes in trunk/Websites/webkit.org

Remove the old site files.

  • asking_questions.html: Removed.
  • building/active-scheme-xcode4.png: Removed.
  • building/build-settings-tab-xcode4.png: Removed.
  • building/build.html: Removed.
  • building/checkout.html: Removed.
  • building/custom-executable-xcode4.png: Removed.
  • building/cygwin-downloader.zip: Removed.
  • building/debug-mac-uiprocess.html: Removed.
  • building/debug.html: Removed.
  • building/launch-debugger-vs2010-small.png: Removed.
  • building/launch-debugger-vs2010.png: Removed.
  • building/run-xcode4.png: Removed.
  • building/run.html: Removed.
  • building/set-as-startup-project-vs2010.png: Removed.
  • building/set-debugging-properties-vs2010-small.png: Removed.
  • building/set-debugging-properties-vs2010.png: Removed.
  • building/tools.html: Removed.
  • coding/RefPtr.html: Removed.
  • coding/adding-features.html: Removed.
  • coding/assertion-guidelines.html: Removed.
  • coding/bsd-license.html: Removed.
  • coding/coding-style.html: Removed.
  • coding/commit-review-policy.html: Removed.
  • coding/contributing.html: Removed.
  • coding/dom-element-attach.html: Removed.
  • coding/images/contribute_add_attachment.png: Removed.
  • coding/images/contribute_mark_review.png: Removed.
  • coding/images/dom-element-attach-large.png: Removed.
  • coding/images/dom-element-attach-small.png: Removed.
  • coding/images/dom-element-attach.graffle: Removed.
  • coding/lgpl-license.html: Removed.
  • coding/major-objects.html: Removed.
  • coding/scripts.html: Removed.
  • coding/technical-articles.html: Removed.
  • contact.html: Removed.
  • css/blue.css: Removed.
  • css/gray.css: Removed.
  • css/green.css: Removed.
  • css/ie.css: Removed.
  • css/main.css: Removed.
  • css/pink.css: Removed.
  • css/purple.css: Removed.
  • css/yellow.css: Removed.
  • demos/index.html: Removed.
  • footer.inc: Removed.
  • header.inc: Removed.
  • images/DroseraPic.png: Removed.
  • images/blank.png: Removed.
  • images/blue-background.png: Removed.
  • images/blue-bullet.png: Removed.
  • images/download.png: Removed.
  • images/end.png: Removed.
  • images/gray-background.png: Removed.
  • images/green-background.png: Removed.
  • images/green-bullet.png: Removed.
  • images/icon-gold.png: Removed.
  • images/icon.png: Removed.
  • images/ie-nav.png: Removed.
  • images/middle.png: Removed.
  • images/nav.png: Removed.
  • images/pink-background.png: Removed.
  • images/pink-bullet.png: Removed.
  • images/purple-background.png: Removed.
  • images/purple-bullet.png: Removed.
  • images/surfin-safari.icns: Removed.
  • images/yellow-background.png: Removed.
  • images/yellow-bullet.png: Removed.
  • index.html: Removed.
  • nav.inc: Removed.
  • pngbehavior.htc: Removed.
  • projects/accessibility/index.html: Removed.
  • projects/cleanup/index.html: Removed.
  • projects/compat/index.html: Removed.
  • projects/css/index.html: Removed.
  • projects/documentation/index.html: Removed.
  • projects/dom/index.html: Removed.
  • projects/editing/index.html: Removed.
  • projects/forms/image-usemap.png: Removed.
  • projects/forms/image1.png: Removed.
  • projects/forms/image10.png: Removed.
  • projects/forms/image16.png: Removed.
  • projects/forms/index.html: Removed.
  • projects/forms/survey.html: Removed.
  • projects/goals.html: Removed.
  • projects/html/index.html: Removed.
  • projects/index.html: Removed.
  • projects/javascript/index.html: Removed.
  • projects/layout/index.html: Removed.
  • projects/mathml/index.html: Removed.
  • projects/performance/index.html: Removed.
  • projects/plugins/index.html: Removed.
  • projects/portability/index.html: Removed.
  • projects/printing/index.html: Removed.
  • projects/svg/index.html: Removed.
  • projects/svg/status.xml: Removed.
  • projects/svg/svg-status.css: Removed.
  • projects/svg/svg-status.xsl: Removed.
  • projects/webkit/index.html: Removed.
  • projects/xml/index.html: Removed.
  • projects/xslt/index.html: Removed.
  • quality/.htaccess: Removed.
  • quality/Ahem.ttf: Removed.
  • quality/bugpriorities.html: Removed.
  • quality/bugwriting.html: Removed.
  • quality/bugzilla.html: Removed.
  • quality/crashlogs.html: Removed.
  • quality/leakhunting.html: Removed.
  • quality/lifecycle.html: Removed.
  • quality/mac_reportbox.jpg: Removed.
  • quality/mac_viewtrace.jpg: Removed.
  • quality/reduction.html: Removed.
  • quality/reporting.html: Removed.
  • quality/testing.html: Removed.
  • quality/testwriting.html: Removed.
  • quality/win_installwatson.jpg: Removed.
  • quality/win_watsongui.jpg: Removed.
  • quality/win_watsoninstalled.jpg: Removed.
  • security/index.html: Removed.
  • security/security-group-members.html: Removed.
  • status.html: Removed.
  • team.html: Removed.
8:39 PM Changeset in webkit [193405] by timothy@apple.com
  • 2 edits
    1434 deletes in trunk/Websites/webkit.org

Yet another attempt to fix the http blog redirects.

Removing the blog folder should do it.

  • .htaccess:
  • blog: Removed.
8:30 PM Changeset in webkit [193404] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Another attempt to fix the http blog redirects.

  • .htaccess:
8:20 PM Changeset in webkit [193403] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Attempt to fix the http blog redirects.

  • .htaccess:
8:18 PM Changeset in webkit [193402] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Another attempt to fix the https redirect.

  • .htaccess:
8:16 PM Changeset in webkit [193401] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Attempt to fix the https redirect.

  • .htaccess:
8:13 PM Changeset in webkit [193400] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Fix blog.webkit.org redirects.

  • .htaccess:
7:58 PM Changeset in webkit [193399] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Add redirects for the demos folder.

  • .htaccess:
7:52 PM Changeset in webkit [193398] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Remove duplicate redirect.

  • .htaccess:
7:46 PM Changeset in webkit [193397] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

One more attempt to clean up redirects.

  • .htaccess:
7:37 PM Changeset in webkit [193396] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Avoid double slashes after redirect for directories.

  • .htaccess:
7:35 PM Changeset in webkit [193395] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Fix directory redirects some more.

  • .htaccess:
7:30 PM Changeset in webkit [193394] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Fix directory redirect ordering.

  • .htaccess:
7:29 PM Changeset in webkit [193393] by fpizlo@apple.com
  • 19 edits in trunk/Source/JavaScriptCore

B3 Patchpoint and Check opcodes should be able to specify WarmAny, ColdAny, and LateColdAny
https://bugs.webkit.org/show_bug.cgi?id=151335

Reviewed by Geoffrey Garen.

This removes ValueRep::Any and replaces it with ValueRep::WarmAny, ValueRep::ColdAny, and
ValueRep::LateColdAny. I think that conceptually the most obvious users of patchpoints are inline
caches, which would use WarmAny for their non-OSR inputs. For this reason, I make WarmAny the
default.

However, the StackmapValue optimization that provides a default ValueRep for any that are missing
was meant for OSR. So, this optimization now uses ColdAny.

This patch wires this change through the whole compiler and adds some tests.

  • b3/B3CheckSpecial.cpp:

(JSC::B3::CheckSpecial::Key::Key):
(JSC::B3::CheckSpecial::Key::dump):
(JSC::B3::CheckSpecial::CheckSpecial):

  • b3/B3CheckSpecial.h:

(JSC::B3::CheckSpecial::Key::Key):
(JSC::B3::CheckSpecial::Key::opcode):
(JSC::B3::CheckSpecial::Key::numArgs):
(JSC::B3::CheckSpecial::Key::stackmapRole):

  • b3/B3CheckValue.cpp:

(JSC::B3::CheckValue::CheckValue):

  • b3/B3ConstrainedValue.h:

(JSC::B3::ConstrainedValue::ConstrainedValue):

  • b3/B3LowerToAir.cpp:

(JSC::B3::Air::LowerToAir::fillStackmap):
(JSC::B3::Air::LowerToAir::lower):

  • b3/B3MoveConstants.cpp:
  • b3/B3PatchpointSpecial.cpp:

(JSC::B3::PatchpointSpecial::forEachArg):
(JSC::B3::PatchpointSpecial::isValid):
(JSC::B3::PatchpointSpecial::admitsStack):

  • b3/B3PatchpointValue.cpp:

(JSC::B3::PatchpointValue::PatchpointValue):

  • b3/B3PatchpointValue.h:
  • b3/B3StackmapSpecial.cpp:

(JSC::B3::StackmapSpecial::forEachArgImpl):
(JSC::B3::StackmapSpecial::admitsStackImpl):
(JSC::B3::StackmapSpecial::isArgValidForRep):
(WTF::printInternal):

  • b3/B3StackmapSpecial.h:
  • b3/B3StackmapValue.cpp:

(JSC::B3::StackmapValue::append):
(JSC::B3::StackmapValue::setConstraint):

  • b3/B3StackmapValue.h:
  • b3/B3Validate.cpp:
  • b3/B3ValueRep.cpp:

(JSC::B3::ValueRep::dump):
(WTF::printInternal):

  • b3/B3ValueRep.h:

(JSC::B3::ValueRep::ValueRep):
(JSC::B3::ValueRep::reg):
(JSC::B3::ValueRep::operator!=):
(JSC::B3::ValueRep::operator bool):
(JSC::B3::ValueRep::isAny):
(JSC::B3::ValueRep::isSomeRegister):

  • b3/testb3.cpp:

(JSC::B3::compileAndRun):
(JSC::B3::add32):
(JSC::B3::test42):
(JSC::B3::testSimplePatchpoint):
(JSC::B3::testPatchpointWithEarlyClobber):
(JSC::B3::testPatchpointFixedRegister):
(JSC::B3::testPatchpointAny):
(JSC::B3::testPatchpointLotsOfLateAnys):
(JSC::B3::testPatchpointAnyImm):
(JSC::B3::testPatchpointManyImms):
(JSC::B3::testPatchpointWithRegisterResult):
(JSC::B3::testPatchpointWithAnyResult):
(JSC::B3::run):

  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::blessSpeculation):

7:15 PM Changeset in webkit [193392] by Jon Davis
  • 2 edits in trunk/Websites/webkit.org

Fixed cache logic so download data is correctly available.

  • wp-content/themes/webkit/nightly.php:
7:06 PM Changeset in webkit [193391] by timothy@apple.com
  • 2 edits in trunk/Websites/webkit.org

Add some missing redirects for directories of the old site.

  • .htaccess:
4:49 PM Changeset in webkit [193390] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Remove the use of GraphicsContextStateSaver from RenderLayer::paintLayerByApplyingTransform
https://bugs.webkit.org/show_bug.cgi?id=151829

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2015-12-03
Reviewed by Simon Fraser.

Set the CTM of the GraphicsContext to its original value before changing
it. This is a lot cheaper than using GraphicsContextStateSaver to save the
whole state of the GraphicsContext and restore it back;

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::paintLayerByApplyingTransform):

4:34 PM Changeset in webkit [193389] by eric.carlson@apple.com
  • 21 edits
    2 adds
    10 deletes in trunk

[MediaStream] Update MediaStreamTrack.getCapabilities
https://bugs.webkit.org/show_bug.cgi?id=151728

Reviewed by Jer Noble.

Source/WebCore:

Test: fast/mediastream/MediaStreamTrack-getCapabilities.html

  • CMakeLists.txt: Remove files deleted from the repository.
  • DerivedSources.make: Ditto.
  • Modules/mediastream/AllAudioCapabilities.h: Removed.
  • Modules/mediastream/AllAudioCapabilities.idl: Removed.
  • Modules/mediastream/AllVideoCapabilities.h: Removed.
  • Modules/mediastream/AllVideoCapabilities.idl: Removed.
  • Modules/mediastream/CapabilityRange.cpp: Removed.
  • Modules/mediastream/CapabilityRange.h: Removed.
  • Modules/mediastream/CapabilityRange.idl: Removed.
  • Modules/mediastream/MediaSourceSettings.h:

(WebCore::MediaSourceSettings::supportsVolume): Volume is a double.
(WebCore::MediaSourceSettings::volume): Double.

  • Modules/mediastream/MediaStreamCapabilities.cpp: Removed.
  • Modules/mediastream/MediaStreamCapabilities.h: Removed.
  • Modules/mediastream/MediaStreamCapabilities.idl: Removed.
  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::getCapabilities): MediaStreamCapabilities is gone, return a RealtimeMediaSourceCapabilities.

  • Modules/mediastream/MediaStreamTrack.h:
  • Modules/mediastream/MediaStreamTrack.idl:
  • WebCore.xcodeproj/project.pbxproj: Remove files deleted from the repository.
  • bindings/js/JSMediaStreamTrackCustom.cpp:

(WebCore::capabilityValue):
(WebCore::JSMediaStreamTrack::getCapabilities): Create and return a dictionary of capatilities.

  • platform/mediastream/RealtimeMediaSourceCapabilities.h:

(WebCore::CapabilityValueOrRange::type):
(WebCore::CapabilityValueOrRange::CapabilityValueOrRange):
(WebCore::CapabilityValueOrRange::rangeMin):
(WebCore::CapabilityValueOrRange::rangeMax):
(WebCore::CapabilityValueOrRange::value):
(WebCore::RealtimeMediaSourceCapabilities::create):
(WebCore::RealtimeMediaSourceCapabilities::~RealtimeMediaSourceCapabilities):
(WebCore::RealtimeMediaSourceCapabilities::supportsWidth):
(WebCore::RealtimeMediaSourceCapabilities::width):
(WebCore::RealtimeMediaSourceCapabilities::setWidth):
(WebCore::RealtimeMediaSourceCapabilities::supportsHeight):
(WebCore::RealtimeMediaSourceCapabilities::height):
(WebCore::RealtimeMediaSourceCapabilities::setHeight):
(WebCore::RealtimeMediaSourceCapabilities::supportsFrameRate):
(WebCore::RealtimeMediaSourceCapabilities::frameRate):
(WebCore::RealtimeMediaSourceCapabilities::setFrameRate):
(WebCore::RealtimeMediaSourceCapabilities::supportsFacingMode):
(WebCore::RealtimeMediaSourceCapabilities::facingMode):
(WebCore::RealtimeMediaSourceCapabilities::addFacingMode):
(WebCore::RealtimeMediaSourceCapabilities::supportsAspectRatio):
(WebCore::RealtimeMediaSourceCapabilities::aspectRatio):
(WebCore::RealtimeMediaSourceCapabilities::setAspectRatio):
(WebCore::RealtimeMediaSourceCapabilities::supportsVolume):
(WebCore::RealtimeMediaSourceCapabilities::volume):
(WebCore::RealtimeMediaSourceCapabilities::setVolume):
(WebCore::RealtimeMediaSourceCapabilities::supportsSampleRate):
(WebCore::RealtimeMediaSourceCapabilities::sampleRate):
(WebCore::RealtimeMediaSourceCapabilities::setSampleRate):
(WebCore::RealtimeMediaSourceCapabilities::supportsSampleSize):
(WebCore::RealtimeMediaSourceCapabilities::sampleSize):
(WebCore::RealtimeMediaSourceCapabilities::setSampleSize):
(WebCore::RealtimeMediaSourceCapabilities::supportsEchoCancellation):
(WebCore::RealtimeMediaSourceCapabilities::echoCancellation):
(WebCore::RealtimeMediaSourceCapabilities::setEchoCancellation):
(WebCore::RealtimeMediaSourceCapabilities::supportsDeviceId):
(WebCore::RealtimeMediaSourceCapabilities::deviceId):
(WebCore::RealtimeMediaSourceCapabilities::setDeviceId):
(WebCore::RealtimeMediaSourceCapabilities::supportsGroupId):
(WebCore::RealtimeMediaSourceCapabilities::groupId):
(WebCore::RealtimeMediaSourceCapabilities::setGroupId):
(WebCore::RealtimeMediaSourceCapabilities::RealtimeMediaSourceCapabilities):
(WebCore::RealtimeMediaSourceCapabilityRange::RealtimeMediaSourceCapabilityRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilityRange::min): Deleted.
(WebCore::RealtimeMediaSourceCapabilityRange::max): Deleted.
(WebCore::RealtimeMediaSourceCapabilityRange::type): Deleted.
(WebCore::RealtimeMediaSourceCapabilityRange::supported): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::sourceId): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setSourceId): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::facingModes): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setWidthRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setHeightRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setFrameRateRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setAspectRatioRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setVolumeRange): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::hasVideoSource): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setHasVideoSource): Deleted.

  • platform/mediastream/RealtimeMediaSourceSettings.h:

(WebCore::RealtimeMediaSourceSettings::volume): Volume is a double.
(WebCore::RealtimeMediaSourceSettings::setVolume): Ditt.

  • platform/mediastream/mac/AVAudioCaptureSource.mm:

(WebCore::AVAudioCaptureSource::initializeCapabilities): Initialize volume capability.

  • platform/mediastream/mac/AVMediaCaptureSource.mm:

(WebCore::AVMediaCaptureSource::capabilities): RealtimeMediaSourceCapabilities constructor takes

supportedConstraints. sourceId -> deviceId.

  • platform/mediastream/mac/AVVideoCaptureSource.mm:

(WebCore::AVVideoCaptureSource::initializeCapabilities): DeviceId is set by the base class.

  • platform/mediastream/mac/WebAudioSourceProviderAVFObjC.mm: Drive-by cleanup, remove unused code.
  • platform/mock/MockRealtimeAudioSource.cpp:

(WebCore::MockRealtimeAudioSource::initializeCapabilities): Updated.
(WebCore::MockRealtimeAudioSource::initializeSupportedConstraints): Ditto.

  • platform/mock/MockRealtimeMediaSource.cpp:

(WebCore::MockRealtimeMediaSource::capabilities): sourceId -> deviceId.

  • platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::initializeCapabilities): Updated.
(WebCore::MockRealtimeVideoSource::initializeSupportedConstraints): Ditto.

LayoutTests:

  • fast/mediastream/MediaStreamTrack-getCapabilities-expected.txt: Added.
  • fast/mediastream/MediaStreamTrack-getCapabilities.html: Added.
  • fast/mediastream/MediaStreamTrack-getSettings-expected.txt:
  • fast/mediastream/MediaStreamTrack-getSettings.html:
4:29 PM Changeset in webkit [193388] by matthew_hanson@apple.com
  • 1 copy in tags/Safari-601.1.46.83

New Tag.

4:23 PM Changeset in webkit [193387] by Jon Davis
  • 4 edits in trunk/Websites/webkit.org

Fixed transient behavior when the cache plugin is enabled.

  • wp-content/themes/webkit/functions.php:
  • wp-content/themes/webkit/includes.php:
  • wp-content/themes/webkit/nightly.php:
4:11 PM Changeset in webkit [193386] by fpizlo@apple.com
  • 13 edits in trunk/Source/JavaScriptCore

B3 patchpoints should allow specifying output constraints
https://bugs.webkit.org/show_bug.cgi?id=151809

Reviewed by Benjamin Poulain.

JS call patchpoints should put their result into the result register, while most other patchpoints
should put their results into some register. I think that it's best if we just allow arbitrary
constraints on the result of a patchpoint. And by "arbitrary" I mean allowing the same kinds of
constraints as we allow on the stackmap children.

This also adds a large comment in B3StackmapValue.h that lays out the philosophy of our stackmaps
and patchpoints. I found it useful to write down the plan since it's pretty subtle.

  • b3/B3LowerToAir.cpp:

(JSC::B3::Air::LowerToAir::lower):

  • b3/B3PatchpointSpecial.cpp:

(JSC::B3::PatchpointSpecial::isValid):
(JSC::B3::PatchpointSpecial::admitsStack):

  • b3/B3PatchpointValue.cpp:

(JSC::B3::PatchpointValue::~PatchpointValue):
(JSC::B3::PatchpointValue::dumpMeta):
(JSC::B3::PatchpointValue::PatchpointValue):

  • b3/B3PatchpointValue.h:

(JSC::B3::PatchpointValue::accepts):

  • b3/B3Procedure.h:

(JSC::B3::Procedure::code):

  • b3/B3StackmapSpecial.cpp:

(JSC::B3::StackmapSpecial::isValidImpl):
(JSC::B3::StackmapSpecial::appendRepsImpl):
(JSC::B3::StackmapSpecial::isArgValidForValue):
(JSC::B3::StackmapSpecial::isArgValidForRep):
(JSC::B3::StackmapSpecial::repForArg):

  • b3/B3StackmapSpecial.h:
  • b3/B3StackmapValue.h:
  • b3/B3Validate.cpp:
  • b3/B3ValueRep.h:

(JSC::B3::ValueRep::doubleValue):

  • b3/testb3.cpp:

(JSC::B3::testPatchpointManyImms):
(JSC::B3::testPatchpointWithRegisterResult):
(JSC::B3::testPatchpointWithStackArgumentResult):
(JSC::B3::testPatchpointWithAnyResult):
(JSC::B3::testSimpleCheck):
(JSC::B3::run):

  • jit/RegisterSet.h:
3:59 PM Changeset in webkit [193385] by bshafiei@apple.com
  • 5 edits in branches/safari-601-branch/Source

Versioning.

3:57 PM Changeset in webkit [193384] by bshafiei@apple.com
  • 1 copy in tags/Safari-601.5.2

New tag.

3:54 PM Changeset in webkit [193383] by bshafiei@apple.com
  • 1 copy in tags/Safari-601.5.1

New tag.

3:44 PM Changeset in webkit [193382] by Simon Fraser
  • 8 edits in trunk/Source

Have layer memory use consult the backing store format
https://bugs.webkit.org/show_bug.cgi?id=151827
rdar://problem/23746497

Reviewed by Dean Jackson.
Source/WebCore:

When computing the backing store memory size, take the pixel format into account,
rather than assuming 4 bytes per pixel.

  • platform/graphics/ca/GraphicsLayerCA.cpp:
  • platform/graphics/ca/PlatformCALayer.h:

Source/WebKit2:

When computing the backing store memory size, take the pixel format into account,
rather than assuming 4 bytes per pixel.

  • Shared/mac/RemoteLayerBackingStore.h:
  • Shared/mac/RemoteLayerBackingStore.mm:

(WebKit::RemoteLayerBackingStore::bytesPerPixel):

  • WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:

(WebKit::PlatformCALayerRemote::backingStoreBytesPerPixel):

  • WebProcess/WebPage/mac/PlatformCALayerRemote.h:
3:39 PM Changeset in webkit [193381] by jer.noble@apple.com
  • 14 edits in trunk

Expose WebCore's InvisibleAutoplayNotPermitted setting to WebKit & WebKit2
https://bugs.webkit.org/show_bug.cgi?id=151830

Reviewed by Anders Carlsson.

Source/WebKit/mac:

Add a new WebPreferences property invisibleAutoplayNotPermitted.

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(-[WebPreferences invisibleAutoplayNotPermitted]):
(-[WebPreferences setInvisibleAutoplayNotPermitted:]):

  • WebView/WebPreferencesPrivate.h:
  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKit2:

Add a new, private WKWebViewConfiguration property _invisibleAutoplayNotPermitted.

  • Shared/WebPreferencesDefinitions.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView initWithFrame:configuration:]):

  • UIProcess/API/Cocoa/WKWebViewConfiguration.mm:

(-[WKWebViewConfiguration init]):
(-[WKWebViewConfiguration copyWithZone:]):
(-[WKWebViewConfiguration _invisibleAutoplayNotPermitted]):
(-[WKWebViewConfiguration _setInvisibleAutoplayNotPermitted:]):

  • UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

Tools:

Set invisibleAutoplayNotPermitted to NO by default both in WKTR and DRT.

  • DumpRenderTree/mac/DumpRenderTree.mm:

(resetWebPreferencesToConsistentValues):

  • WebKitTestRunner/cocoa/TestControllerCocoa.mm:

(WTR::initializeWebViewConfiguration):

2:54 PM Changeset in webkit [193380] by weinig@apple.com
  • 2 edits in trunk/Source/WebKit2

It should be possible to use version 6 of the WKPageUIClient without adopting the new createNewPage
https://bugs.webkit.org/show_bug.cgi?id=151826

Reviewed by Anders Carlsson.

  • UIProcess/API/C/WKPage.cpp:

(WKPageSetPageUIClient):
Pick which variant of createNewPage to use based on which function pointer is available,
not the version number.

2:47 PM Changeset in webkit [193379] by Jon Davis
  • 5 edits in trunk/Websites/webkit.org

Add sub-section anchors to code style guidelines
https://bugs.webkit.org/show_bug.cgi?id=151770

Reviewed by Timothy Hatcher.

  • code-style.md:
  • wp-content/plugins/table-of-contents.php:
  • wp-content/themes/webkit/includes.php:
  • wp-content/themes/webkit/style.css:

(a[name]):
(p > a[name]::before):
(a[name]:hover):
(h6 a[name]):
(.admin-bar a[name]):
(.admin-bar p > a[name]::before):
(.screen-reader-text):
(.table-of-contents ul li > ul):
(#post-4132 pre:nth-child(-n+10)):
(#post-4132 pre:nth-child(-n+8)): Deleted.

2:41 PM Changeset in webkit [193378] by andersca@apple.com
  • 76 edits in trunk

Remove Objective-C GC support
https://bugs.webkit.org/show_bug.cgi?id=151819
rdar://problem/23746991

Reviewed by Dan Bernstein.

Source/bmalloc:

  • Configurations/Base.xcconfig:

Source/JavaScriptCore:

  • Configurations/Base.xcconfig:
  • Configurations/ToolExecutable.xcconfig:

Source/ThirdParty/ANGLE:

  • Configurations/Base.xcconfig:

Source/WebCore:

  • Configurations/Base.xcconfig:
  • bindings/objc/WebScriptObject.mm:

(+[WebScriptObject initialize]): Deleted.
(-[WebScriptObject finalize]): Deleted.

  • bindings/scripts/CodeGeneratorObjC.pm:

(GenerateImplementation):

  • bindings/scripts/test/ObjC/DOMTestActiveDOMObject.mm:

(-[DOMTestActiveDOMObject finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestCallback.mm:

(-[DOMTestCallback finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestCallbackFunction.mm:

(-[DOMTestCallbackFunction finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestCustomConstructorWithNoInterfaceObject.mm:

(-[DOMTestCustomConstructorWithNoInterfaceObject finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestCustomNamedGetter.mm:

(-[DOMTestCustomNamedGetter finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestEventConstructor.mm:

(-[DOMTestEventConstructor finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestEventTarget.mm:

(-[DOMTestEventTarget finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestException.mm:

(-[DOMTestException finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestGenerateIsReachable.mm:

(-[DOMTestGenerateIsReachable finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestInterface.mm:

(-[DOMTestInterface finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm:

(-[DOMTestJSBuiltinConstructor finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestMediaQueryListListener.mm:

(-[DOMTestMediaQueryListListener finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestNamedConstructor.mm:

(-[DOMTestNamedConstructor finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestNondeterministic.mm:

(-[DOMTestNondeterministic finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestObj.mm:

(-[DOMTestObj finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestOverloadedConstructors.mm:

(-[DOMTestOverloadedConstructors finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestOverrideBuiltins.mm:

(-[DOMTestOverrideBuiltins finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterface.mm:

(-[DOMTestSerializedScriptValueInterface finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMTestTypedefs.mm:

(-[DOMTestTypedefs finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMattribute.mm:

(-[DOMattribute finalize]): Deleted.

  • bindings/scripts/test/ObjC/DOMreadonly.mm:

(-[DOMreadonly finalize]): Deleted.

  • bridge/objc/objc_instance.mm:

(ObjcInstance::virtualBegin):
(allocateAutoReleasePool): Deleted.

  • platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
  • platform/mac/SharedBufferMac.mm:

(+[WebCoreSharedBufferData initialize]): Deleted.
(-[WebCoreSharedBufferData finalize]): Deleted.

  • platform/mac/WebCoreObjCExtras.h:

(WebCoreObjCFinalizeOnMainThread): Deleted.

Source/WebInspectorUI:

  • Configurations/Base.xcconfig:

Source/WebKit/mac:

  • Carbon/CarbonWindowAdapter.mm:

(+[CarbonWindowAdapter initialize]): Deleted.
(-[CarbonWindowAdapter finalize]): Deleted.

  • Configurations/Base.xcconfig:
  • History/WebBackForwardList.mm:

(+[WebBackForwardList initialize]): Deleted.
(-[WebBackForwardList finalize]): Deleted.

  • History/WebHistory.mm:

(-[WebHistoryPrivate finalize]): Deleted.
(-[WebHistory finalize]): Deleted.

  • History/WebHistoryItem.mm:

(+[WebHistoryItem initialize]): Deleted.
(-[WebHistoryItem finalize]): Deleted.

  • Misc/WebElementDictionary.mm:

(+[WebElementDictionary initialize]): Deleted.
(-[WebElementDictionary finalize]): Deleted.

  • Plugins/Hosted/WebHostedNetscapePluginView.mm:

(+[WebHostedNetscapePluginView initialize]): Deleted.

  • Plugins/WebBaseNetscapePluginView.mm:

(-[WebBaseNetscapePluginView finalize]): Deleted.

  • Plugins/WebBasePluginPackage.mm:

(-[WebBasePluginPackage finalize]): Deleted.

  • Plugins/WebNetscapePluginView.mm:

(+[WebNetscapePluginView initialize]): Deleted.
(-[WebNetscapePluginView finalize]): Deleted.

  • Plugins/WebPluginContainerCheck.mm:

(-[WebPluginContainerCheck finalize]): Deleted.

  • WebCoreSupport/WebEditorClient.mm:

(+[WebUndoStep initialize]): Deleted.
(-[WebUndoStep finalize]): Deleted.

  • WebCoreSupport/WebFrameLoaderClient.mm:
  • WebCoreSupport/WebOpenPanelResultListener.mm:

(-[WebOpenPanelResultListener finalize]): Deleted.

  • WebCoreSupport/WebSecurityOrigin.mm:

(-[WebSecurityOrigin finalize]): Deleted.

  • WebView/WebArchive.mm:

(+[WebArchivePrivate initialize]): Deleted.

  • WebView/WebDataSource.mm:

(+[WebDataSource initialize]): Deleted.
(-[WebDataSource finalize]): Deleted.

  • WebView/WebDynamicScrollBarsView.mm:

(-[WebDynamicScrollBarsView finalize]): Deleted.

  • WebView/WebFrame.mm:

(-[WebFramePrivate setWebFrameView:]):
(-[WebFramePrivate finalize]): Deleted.
(-[WebFrame finalize]): Deleted.

  • WebView/WebFrameView.mm:

(-[WebFrameView finalize]): Deleted.

  • WebView/WebHTMLRepresentation.mm:

(-[WebHTMLRepresentation finalize]): Deleted.

  • WebView/WebHTMLView.mm:

(+[WebHTMLViewPrivate initialize]):
(-[WebHTMLViewPrivate finalize]): Deleted.
(+[WebHTMLView initialize]): Deleted.
(-[WebHTMLView finalize]): Deleted.

  • WebView/WebResource.mm:

(+[WebResourcePrivate initialize]): Deleted.
(-[WebResourcePrivate finalize]): Deleted.

  • WebView/WebTextIterator.mm:

(+[WebTextIteratorPrivate initialize]): Deleted.

  • WebView/WebView.mm:

(-[WebView finalize]): Deleted.

  • WebView/WebViewData.mm:

(+[WebViewPrivate initialize]): Deleted.
(-[WebViewPrivate init]): Deleted.
(-[WebViewPrivate finalize]): Deleted.

Source/WebKit2:

  • Configurations/Base.xcconfig:
  • Configurations/BaseLegacyProcess.xcconfig:
  • Configurations/BaseXPCService.xcconfig:
  • Shared/Cocoa/APIObject.mm:

(API::Object::newObject): Deleted.

Source/WTF:

  • Configurations/Base.xcconfig:
  • wtf/ThreadingPthreads.cpp:

(WTF::initializeCurrentThreadInternal): Deleted.

  • wtf/text/cf/StringImplCF.cpp:

(WTF::StringImpl::createCFString):
(garbageCollectionEnabled): Deleted.
(WTF::StringWrapperCFAllocator::create): Deleted.

Tools:

  • asan/asan.xcconfig:
2:32 PM Changeset in webkit [193377] by benjamin@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

Attempt to fix GTK again after r193125

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-03

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::supportsLZCNT):

2:24 PM Changeset in webkit [193376] by benjamin@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

Attempt to fix GTK after r193125

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-03

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::supportsLZCNT):
GCC is unable to handle EBX correctly when clobbered by inline asm.

2:06 PM Changeset in webkit [193375] by Matt Baker
  • 3 edits in trunk/Source/WebInspectorUI

Uncaught Exception in Web Inspector: TypeError: null is not an object (evaluating 'dataGridNode.element.classList')
https://bugs.webkit.org/show_bug.cgi?id=151790

Reviewed by Timothy Hatcher.

  • UserInterface/Views/DataGrid.js:

(WebInspector.DataGridNode):
(WebInspector.DataGridNode.prototype.get hidden):
(WebInspector.DataGridNode.prototype.set hidden):
Make hidden a property, so it can be set before the grid node's DOM element exists.
(WebInspector.DataGridNode.prototype.get selectable):
(WebInspector.DataGridNode.prototype.get element):
Add hidden style, if needed, when element is created.

  • UserInterface/Views/TreeOutlineDataGridSynchronizer.js:

(WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementVisibilityDidChange):
(WebInspector.TreeOutlineDataGridSynchronizer):
Don't access the grid node's element directly, since it may not exist yet.

1:59 PM Changeset in webkit [193374] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

Simple line layout: Print out simple line layout statistics for the current page from command line.
https://bugs.webkit.org/show_bug.cgi?id=151806

Reviewed Simon Fraser.

com.apple.WebKit.showSimpleLineLayoutCoverage prints out a coverage summary of the current page,
while com.apple.WebKit.showSimpleLineLayoutReasons lists the non-simple line layout blocks including the reasons why
they are not covered.

No change in functionality.

  • rendering/SimpleLineLayout.cpp:

(WebCore::SimpleLineLayout::canUseForText):
(WebCore::SimpleLineLayout::canUseForFontAndText):
(WebCore::SimpleLineLayout::canUseForStyle):
(WebCore::SimpleLineLayout::canUseForWithReason):
(WebCore::SimpleLineLayout::canUseFor):
(WebCore::SimpleLineLayout::printReason):
(WebCore::SimpleLineLayout::printReasons):
(WebCore::SimpleLineLayout::printTextForSubtree):
(WebCore::SimpleLineLayout::textLengthForSubtree):
(WebCore::SimpleLineLayout::collectNonEmptyLeafRenderBlockFlows):
(WebCore::SimpleLineLayout::collectNonEmptyLeafRenderBlockFlowsForCurrentPage):
(WebCore::SimpleLineLayout::printSimpleLineLayoutBlockList):
(WebCore::SimpleLineLayout::printSimpleLineLayoutCoverage):

1:44 PM Changeset in webkit [193373] by msaboff@apple.com
  • 5 edits in trunk/Source/bmalloc

bmalloc: extra large allocations could be more efficient
https://bugs.webkit.org/show_bug.cgi?id=151817

Reviewed by Geoffrey Garen.

Reduced the super chunk size from 4MB to 2MB.

Added path to reallocate() of an extra large object to see if we can extend the allocation.

  • bmalloc/Allocator.cpp:

(bmalloc::Allocator::reallocate):

  • bmalloc/SegregatedFreeList.h:
  • bmalloc/Sizes.h:
  • bmalloc/VMAllocate.h:

(bmalloc::tryVMAllocate):
(bmalloc::tryVMExtend):
(bmalloc::vmAllocate):

1:17 PM Changeset in webkit [193372] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Removing deleted test storage/indexeddb/objectstore-keycursor.html from TestExpectations file
https://bugs.webkit.org/show_bug.cgi?id=151772

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
1:09 PM Changeset in webkit [193371] by sbarati@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

FTL::OSRExitDescriptor should use less memory by having a companion object that dies after compilation
https://bugs.webkit.org/show_bug.cgi?id=151795

Reviewed by Geoffrey Garen.

There were a few fields on FTL::OSRExitDescriptor that are only
needed during compilation. This patch introduces OSRExitDescriptorImpl
which is a struct that we create for each OSRExitDescriptor. The difference is
that OSRExitDescriptorImpl lives off of FTL::State so it dies after we compile.
This way no unnecessary fields persist after the compilation.

  • ftl/FTLCompile.cpp:

(JSC::FTL::mmAllocateDataSection):

  • ftl/FTLExceptionHandlerManager.cpp:

(JSC::FTL::ExceptionHandlerManager::lazySlowPathExceptionTarget):
(JSC::FTL::ExceptionHandlerManager::getCallOSRExitCommon):

  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::compileInvalidationPoint):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExitArgumentsForPatchpointIfWillCatchException):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExitDescriptor):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExit):
(JSC::FTL::DFG::LowerDFGToLLVM::blessSpeculation):
(JSC::FTL::DFG::LowerDFGToLLVM::emitOSRExitCall):
(JSC::FTL::DFG::LowerDFGToLLVM::buildExitArguments):

  • ftl/FTLOSRExit.cpp:

(JSC::FTL::OSRExitDescriptor::OSRExitDescriptor):
(JSC::FTL::OSRExitDescriptor::validateReferences):
(JSC::FTL::OSRExitDescriptor::emitOSRExit):
(JSC::FTL::OSRExitDescriptor::emitOSRExitLater):
(JSC::FTL::OSRExitDescriptor::prepareOSRExitHandle):
(JSC::FTL::OSRExit::OSRExit):
(JSC::FTL::OSRExit::codeLocationForRepatch):
(JSC::FTL::OSRExit::gatherRegistersToSpillForCallIfException):
(JSC::FTL::OSRExit::willArriveAtExitFromIndirectExceptionCheck):
(JSC::FTL::exceptionTypeWillArriveAtOSRExitFromGenericUnwind):
(JSC::FTL::OSRExit::willArriveAtOSRExitFromGenericUnwind):
(JSC::FTL::OSRExit::willArriveAtOSRExitFromCallOperation):
(JSC::FTL::OSRExitDescriptor::isExceptionHandler): Deleted.

  • ftl/FTLOSRExit.h:

(JSC::FTL::OSRExitDescriptorImpl::OSRExitDescriptorImpl):

  • ftl/FTLOSRExitCompiler.cpp:

(JSC::FTL::compileFTLOSRExit):

  • ftl/FTLState.h:
12:57 PM Changeset in webkit [193370] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebKit2

Unreviewed build-fix; fix !HAVE(AVKIT) build after r193340.

  • UIProcess/ios/WebVideoFullscreenManagerProxy.mm:

(WebKit::WebVideoFullscreenManagerProxy::applicationDidBecomeActive):

12:56 PM Changeset in webkit [193369] by Jon Davis
  • 2 edits in trunk/Source/WebCore

Add WebCrypto to status page
https://bugs.webkit.org/show_bug.cgi?id=151760

Reviewed by Timothy Hatcher.

  • features.json:
12:46 PM Changeset in webkit [193368] by commit-queue@webkit.org
  • 6 edits in trunk

[Win] fast/forms/HTMLOptionElement_label03.html failing on win7
https://bugs.webkit.org/show_bug.cgi?id=150909
rdar://problem/23539673

Patch by Keith Rollin <Keith Rollin> on 2015-12-03
Reviewed by Darin Adler.

Source/WebCore:

When returning text to be displayed, an <option> element will return
the value of a label attribute if it exists, or the text content as a
fallback. The failing test concerned the display of a <select>
element when it contained a sole <option> element that had a label
attribute set to a single space. When displayed, various
platform-specific bits of code will strip off the leading and trailing
whitespace. However, when WebKit would use this text to measure how
wide the <select> popup menu button should be, it would not strip off
spaces, leading to the calculated width being wider than necessary.
The approach taken to fix this is to strip whitespace in the label
attribute before it is returned from the <option> element.

No new tests. fast/forms/HTMLOptionElement_label03.html had been
marked as being expected to fail in TestExpectations; that test now
succeeds.

  • html/HTMLOptionElement.cpp:

(WebCore::HTMLOptionElement::label):

LayoutTests:

Mark fast/forms/HTMLOptionElement_label03.html as being expected to
pass. Also update some text in HTMLOptionElement_label02.html and
HTMLOptionElement_label03.html so that it no longer refers to our
trying to match IE (which we are no longer doing).

  • fast/forms/HTMLOptionElement_label02.html:
  • fast/forms/HTMLOptionElement_label03.html:
  • platform/win/TestExpectations:
12:44 PM Changeset in webkit [193367] by weinig@apple.com
  • 2 edits in trunk/Source/WebKit2

Need completionHandler-based WebKit C SPI for alert, confirm, and prompt
<rdar://problem/23320863>
https://bugs.webkit.org/show_bug.cgi?id=151708

(Add missing function definitions)

  • UIProcess/API/C/WKPage.cpp:

(WKPageRunJavaScriptAlertResultListenerGetTypeID):
(WKPageRunJavaScriptAlertResultListenerCall):
(WKPageRunJavaScriptConfirmResultListenerGetTypeID):
(WKPageRunJavaScriptConfirmResultListenerCall):
(WKPageRunJavaScriptPromptResultListenerGetTypeID):
(WKPageRunJavaScriptPromptResultListenerCall):

12:39 PM Changeset in webkit [193366] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

Try to fix the Windows build.

  • bindings/js/JSWorkerGlobalScopeBase.cpp:

(WebCore::JSWorkerGlobalScopeBase::javaScriptRuntimeFlags):
(WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):

12:12 PM Changeset in webkit [193365] by achristensen@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Fix 64-bit Windows build after r193125.
https://bugs.webkit.org/show_bug.cgi?id=151799

Reviewed by Michael Saboff.

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::supportsLZCNT):
Use cpuid intrinsic instead of inline assembly.

12:07 PM Changeset in webkit [193364] by beidson@apple.com
  • 14 edits in trunk

Modern IDB: storage/indexeddb/cursor-advance.html fails.
https://bugs.webkit.org/show_bug.cgi?id=151731

Reviewed by Alex Christensen.

Source/WebCore:

No new tests (At least one failing test now passes).

  • Modules/indexeddb/IDBCursor.h:
  • Modules/indexeddb/IDBCursor.idl:
  • Modules/indexeddb/client/IDBCursorImpl.cpp:

(WebCore::IDBClient::IDBCursor::advance): Return a custom exception message for TypeError.

  • Modules/indexeddb/client/IDBCursorImpl.h:
  • Modules/indexeddb/legacy/LegacyCursor.cpp:

(WebCore::LegacyCursor::advance):

  • Modules/indexeddb/legacy/LegacyCursor.h:
  • bindings/js/JSDOMBinding.cpp:

(WebCore::createDOMException):
(WebCore::setDOMException):

  • bindings/js/JSDOMBinding.h:
  • bindings/scripts/IDLAttributes.txt:
  • inspector/InspectorIndexedDBAgent.cpp:

LayoutTests:

  • platform/mac-wk1/TestExpectations:
  • storage/indexeddb/cursor-advance-expected.txt:
12:06 PM Changeset in webkit [193363] by Brent Fulgham
  • 6 edits
    2 adds in trunk

Allow JavaScript to iterate over plugins for local files
https://bugs.webkit.org/show_bug.cgi?id=151783
<rdar://problem/23692113>

Source/WebCore:

Reviewed by Alexey Proskuryakov.

Test: http/tests/plugins/plugin-javascript-access.html

plugins/plugin-javascript-access.html

  • page/Page.cpp:

(WebCore::Page::showAllPlugins): True if we set the debugging flag to show
all plugins, or if the document's origin is from a local file.

  • page/Page.h:

LayoutTests:

Modify the existing 'local file' plugin tests so that they don't turn on the debugging
flag to allow iterating over all plugins. Then create a new HTTP test (based on the
existing plugin-javascript-access test) to make sure that plugin iteration is blocked
for non-local-file access.

Reviewed by Alexey Proskuryakov.

  • http/tests/plugins/plugin-javascript-access-expected.txt: Added.
  • http/tests/plugins/plugin-javascript-access.html: Added.
  • plugins/plugin-javascript-access.html: Remove unneeded 'internals.setShowAllPlugins' call.
  • plugins/script-tests/navigator-mimeTypes-length.js: Ditto.
12:01 PM Changeset in webkit [193362] by fpizlo@apple.com
  • 29 edits
    2 adds in trunk/Source

FTL B3 should support OSR exit
https://bugs.webkit.org/show_bug.cgi?id=151710

Reviewed by Saam Barati.

Source/JavaScriptCore:

This adds OSR exit support using the same style that I established with lazy slow paths. All of
the work is driven by FTL::LowerDFGToLLVM, and from there any work that needs to be deferred
until after B3 finishes is attached to the stackmap generator. In order to make it easy to port
all of the different forms of OSR exit - invalidation points, exceptions, etc. - the logic for
registering an OSR exit is abstracted behind OSRExitDescriptor and OSRExitHandle.

An issue that I encountered repeatedly in this patch is OSRExitDescriptor being passed as a
reference (&) rather than pointer (*). The new code uses a lot of lambdas that run after the
current frame pops, so the capture list cannot be [&]. I believe that always listing all of the
captured variables is not scalable considering how sophisticated our use of lambdas is. So, it
makes sense to use [=]. But anytime we captured a variable whose type was OSRExitDescriptor&, it
would be captured by value, because that's how references work. One has to be mindful of these
things whenever using [=]. Note that it's not enough to say that we should have listed the
captured variables explicitly - in that case, we still could have made the mistake by forgetting
to put & in front of the variant. The pattern that worked for me to reason about whether I'm
capturing an object or a pointer to an object is to always use pointer types for pointers: either
RefPtr<> when we also want the lambda to prolong the object's life, or * if we are confident that
the object will stay alive. For this reason, this patch changes all code that references
OSRExitDescriptor to use * instead of &. Consistency makes the code easier to grok, and it made
it easier to introduce the required uses of * in places where there were lambdas.

I tested this by running imaging-gaussian-blur, and running some tests that reqiure OSR exit. I'm
not promising that all kinds of exits work, but we have to begin somewhere.

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • b3/B3Compilation.cpp:

(JSC::B3::Compilation::Compilation):
(JSC::B3::Compilation::~Compilation):

  • b3/B3Procedure.cpp:

(JSC::B3::Procedure::addDataSection):
(JSC::B3::Procedure::frameSize):
(JSC::B3::Procedure::calleeSaveRegisters):

  • b3/B3Procedure.h:

(JSC::B3::Procedure::releaseByproducts):
(JSC::B3::Procedure::code):
(JSC::B3::Procedure::takeByproducts): Deleted.

  • b3/air/AirCode.h:

(JSC::B3::Air::Code::setFrameSize):
(JSC::B3::Air::Code::calleeSaveRegisters):

  • b3/air/AirGenerationContext.h:
  • ftl/FTLB3Compile.cpp:

(JSC::FTL::compile):

  • ftl/FTLCompile.cpp:

(JSC::FTL::mmAllocateDataSection):

  • ftl/FTLExceptionHandlerManager.cpp:

(JSC::FTL::ExceptionHandlerManager::lazySlowPathExceptionTarget):
(JSC::FTL::ExceptionHandlerManager::getCallOSRExitCommon):

  • ftl/FTLExitThunkGenerator.cpp:
  • ftl/FTLExitThunkGenerator.h:
  • ftl/FTLJITCode.cpp:

(JSC::FTL::JITCode::JITCode):
(JSC::FTL::JITCode::initializeB3Code):
(JSC::FTL::JITCode::initializeB3Byproducts):
(JSC::FTL::JITCode::initializeExitThunks):
(JSC::FTL::JITCode::validateReferences):
(JSC::FTL::JITCode::liveRegistersToPreserveAtExceptionHandlingCallSite):

  • ftl/FTLJITCode.h:
  • ftl/FTLJITFinalizer.cpp:

(JSC::FTL::JITFinalizer::finalizeFunction):

  • ftl/FTLJITFinalizer.h:
  • ftl/FTLJSCall.cpp:

(JSC::FTL::JSCall::emit):

  • ftl/FTLJSCallBase.cpp:

(JSC::FTL::JSCallBase::emit):

  • ftl/FTLJSTailCall.cpp:

(JSC::FTL::JSTailCall::JSTailCall):
(JSC::FTL::JSTailCall::emit):
(JSC::FTL::DFG::getRegisterWithAddend): Deleted.
(JSC::FTL::m_instructionOffset): Deleted.

  • ftl/FTLJSTailCall.h:

(JSC::FTL::JSTailCall::patchpoint):
(JSC::FTL::JSTailCall::stackmapID):
(JSC::FTL::JSTailCall::estimatedSize):
(JSC::FTL::JSTailCall::operator<):

  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::compileInvalidationPoint):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExitArgumentsForPatchpointIfWillCatchException):
(JSC::FTL::DFG::LowerDFGToLLVM::lowBlock):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExitDescriptor):
(JSC::FTL::DFG::LowerDFGToLLVM::appendOSRExit):
(JSC::FTL::DFG::LowerDFGToLLVM::blessSpeculation):
(JSC::FTL::DFG::LowerDFGToLLVM::emitOSRExitCall):
(JSC::FTL::DFG::LowerDFGToLLVM::buildExitArguments):
(JSC::FTL::DFG::LowerDFGToLLVM::callStackmap):
(JSC::FTL::lowerDFGToLLVM):

  • ftl/FTLOSRExit.cpp:

(JSC::FTL::OSRExitDescriptor::OSRExitDescriptor):
(JSC::FTL::OSRExitDescriptor::validateReferences):
(JSC::FTL::OSRExitDescriptor::appendOSRExit):
(JSC::FTL::OSRExitDescriptor::appendOSRExitLater):
(JSC::FTL::OSRExitDescriptor::prepareOSRExitHandle):
(JSC::FTL::OSRExit::OSRExit):
(JSC::FTL::OSRExit::codeLocationForRepatch):
(JSC::FTL::OSRExit::gatherRegistersToSpillForCallIfException):
(JSC::FTL::OSRExit::spillRegistersToSpillSlot):
(JSC::FTL::OSRExit::recoverRegistersFromSpillSlot):
(JSC::FTL::OSRExit::willArriveAtExitFromIndirectExceptionCheck):

  • ftl/FTLOSRExit.h:

(JSC::FTL::OSRExit::considerAddingAsFrequentExitSite):

  • ftl/FTLOSRExitCompilationInfo.h:

(JSC::FTL::OSRExitCompilationInfo::OSRExitCompilationInfo):

  • ftl/FTLOSRExitCompiler.cpp:

(JSC::FTL::reboxAccordingToFormat):
(JSC::FTL::compileRecovery):
(JSC::FTL::compileStub):
(JSC::FTL::compileFTLOSRExit):

  • ftl/FTLOSRExitHandle.cpp: Added.

(JSC::FTL::OSRExitHandle::emitExitThunk):

  • ftl/FTLOSRExitHandle.h: Added.

(JSC::FTL::OSRExitHandle::OSRExitHandle):

  • ftl/FTLState.cpp:

(JSC::FTL::State::State):
(JSC::FTL::State::~State):

Source/WTF:

Make sure that this has perfect forwarding.

  • wtf/SegmentedVector.h:

(WTF::SegmentedVector::append):
(WTF::SegmentedVector::alloc):

11:56 AM Changeset in webkit [193361] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

Unreviewed build-fix; missing include.

  • html/HTMLVideoElement.cpp:
11:52 AM Changeset in webkit [193360] by beidson@apple.com
  • 5 edits in trunk

Source/WebCore:
Modern IDB: storage/indexeddb/cursor-skip-deleted.html crashes.
https://bugs.webkit.org/show_bug.cgi?id=151794

Reviewed by Alex Christensen.

STL reverse_iterators are a tricky beast.

They are implemented in terms of a normal forward iterator (called the "base" iterator),
and they decrement a copy of that iterator when dereferenced.

So when monitoring deletes from a std::set to check if we should invalidate our current
reverse_iterator, we were incorrectly comparing the deleted key to the value pointed by the
reverse_iterator instead of its base iterator.

Since the iterators in question are bidirectional, anyways, we can just use a single iterator
and either increment or decrement it as needed.

No new tests (At least one failing (crashing) test now passes).

  • Modules/indexeddb/server/MemoryObjectStoreCursor.cpp:

(WebCore::IDBServer::MemoryObjectStoreCursor::objectStoreCleared):
(WebCore::IDBServer::MemoryObjectStoreCursor::keyDeleted):
(WebCore::IDBServer::MemoryObjectStoreCursor::keyAdded):
(WebCore::IDBServer::MemoryObjectStoreCursor::setFirstInRemainingRange):
(WebCore::IDBServer::MemoryObjectStoreCursor::setForwardIteratorFromRemainingRange):
(WebCore::IDBServer::MemoryObjectStoreCursor::setReverseIteratorFromRemainingRange):
(WebCore::IDBServer::MemoryObjectStoreCursor::currentData):
(WebCore::IDBServer::MemoryObjectStoreCursor::incrementForwardIterator):
(WebCore::IDBServer::MemoryObjectStoreCursor::incrementReverseIterator):
(WebCore::IDBServer::MemoryObjectStoreCursor::iterate):
(WebCore::IDBServer::MemoryObjectStoreCursor::firstForwardIteratorInRemainingRange): Deleted.
(WebCore::IDBServer::MemoryObjectStoreCursor::firstReverseIteratorInRemainingRange): Deleted.
(WebCore::IDBServer::MemoryObjectStoreCursor::hasIterators): Deleted.
(WebCore::IDBServer::MemoryObjectStoreCursor::hasValidPosition): Deleted.
(WebCore::IDBServer::MemoryObjectStoreCursor::clearIterators): Deleted.

  • Modules/indexeddb/server/MemoryObjectStoreCursor.h:

LayoutTests:
Modern IDB: storage/indexeddb/cursor-skip-deleted.html fails.
https://bugs.webkit.org/show_bug.cgi?id=151794

Reviewed by Alex Christensen.

  • platform/mac-wk1/TestExpectations:
11:41 AM Changeset in webkit [193359] by matthew_hanson@apple.com
  • 2 edits in branches/safari-601.1.46-branch/Source/WebCore

Merge r192971. rdar://problem/23726466

11:41 AM Changeset in webkit [193358] by matthew_hanson@apple.com
  • 2 edits in branches/safari-601.1.46-branch/Source/WebCore

Merge r192922. rdar://problem/23726466

11:41 AM Changeset in webkit [193357] by matthew_hanson@apple.com
  • 2 edits in branches/safari-601.1.46-branch/Source/WebKit2

Merge r192811. rdar://problem/23730032

11:34 AM Changeset in webkit [193356] by Simon Fraser
  • 3 edits
    4 adds in trunk/PerformanceTests

Add a basic compositing Animometer test
https://bugs.webkit.org/show_bug.cgi?id=151724

Reviewed by Dean Jackson.

Add a "bouncing particles" test that moves composited layers around, optionally with a filter.

This is added under a new "Miscellaneous" category.

Remove the test templates category from the UI.

  • Animometer/runner/resources/tests.js:
  • Animometer/tests/bouncing-particles/resources/bouncing-css-shapes.js:

(BouncingCssShape.prototype.animate):

  • Animometer/tests/misc/compositing-transforms.html: Added.
  • Animometer/tests/misc/resources/compositing-transforms.js: Added.

(BouncingCompositedImage):
(BouncingCompositedImage.prototype._move):
(BouncingCompositedImage.prototype.animate):
(CompositingTransformsStage):
(CompositingTransformsStage.prototype.createParticle):
(CompositingTransformsStage.prototype.particleWillBeRemoved):
(CompositedTransformsBenchmark):
(CompositedTransformsBenchmark.prototype.createStage):
(window.benchmarkClient.create):

11:33 AM Changeset in webkit [193355] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION:(r192753): Remote Web Inspector: RemoteInspector::sendMessageToRemote with null connection
https://bugs.webkit.org/show_bug.cgi?id=151789

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2015-12-03
Reviewed by Timothy Hatcher.

  • inspector/remote/RemoteInspector.mm:

(Inspector::RemoteInspector::sendMessageToRemote):
Bail if the connection is no longer available. It may have
been closed remotely.

11:28 AM Changeset in webkit [193354] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION:(r192753): Remote Web Inspector: Window immediately closes after opening
https://bugs.webkit.org/show_bug.cgi?id=151788

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2015-12-03
Reviewed by Timothy Hatcher.

  • inspector/remote/RemoteInspector.mm:

(Inspector::RemoteInspector::pushListingsNow):
The key at the outer level was not a string. Ensure it is a
string for backwards compatibility. One day we may use
non-numeric page identifiers as listing keys.

11:27 AM Changeset in webkit [193353] by peavo@outlook.com
  • 3 edits in trunk/Source/WebCore

[WinCairo][MediaFoundation] Main thread can block when session is destroyed.
https://bugs.webkit.org/show_bug.cgi?id=151803

Reviewed by Alex Christensen.

Set flag to make sure that the scheduler thread stops when the session ends.

  • platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:

(WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::stopScheduler):
(WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::processSamplesInQueue):
(WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::schedulerThreadProcPrivate):

  • platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:

(WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::stopThread):

11:20 AM Changeset in webkit [193352] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Address warnings from the console.assert stripping phase
for console.assert statements lacking a trailing semicolon.

  • UserInterface/Views/View.js:

(WebInspector.View.prototype.makeRootView):
(WebInspector.View.prototype.didDetach):

11:13 AM Changeset in webkit [193351] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/LayoutTests

Skip Inspector tests because the new test harness does not work on the branch currently.

  • platform/mac/TestExpectations:
11:13 AM Changeset in webkit [193350] by timothy@apple.com
  • 15 edits in branches/safari-601-branch/Source/WebInspectorUI

Convert arrow functions and default parameters to vanilla JS so things work on the branch.

  • UserInterface/Base/Main.js:

(WebInspector.createNewTabWithType):

  • UserInterface/Base/URLUtilities.js:

(WebInspector.truncateURL):

  • UserInterface/Controllers/DOMTreeManager.js:

(WebInspector.DOMTreeManager.prototype._buildHighlightConfig):

  • UserInterface/Controllers/DebuggerManager.js:
  • UserInterface/Views/CookieStorageContentView.js:

(WebInspector.CookieStorageContentView.prototype.update):
(WebInspector.CookieStorageContentView.prototype._filterCookies.resourceMatchesStorageDomain):
(WebInspector.CookieStorageContentView.prototype._filterCookies):

  • UserInterface/Views/FindBanner.js:

(WebInspector.FindBanner):

  • UserInterface/Views/NewTabContentView.js:

(WebInspector.NewTabContentView.prototype._allowableTabTypes):

  • UserInterface/Views/Popover.js:

(WebInspector.Popover.prototype.update):

  • UserInterface/Views/ProbeSetDetailsSection.js:

(WebInspector.ProbeSetDetailsSection.prototype._probeSetHasSamples):
(WebInspector.ProbeSetDetailsSection):

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype.tokenTrackingControllerHighlightedRangeReleased):

  • UserInterface/Views/TabBar.js:

(WebInspector.TabBar.prototype.hasNormalTab):

  • UserInterface/Views/TimelineOverviewGraph.js:

(WebInspector.TimelineOverviewGraph.prototype._needsSelectedRecordLayout):
(WebInspector.TimelineOverviewGraph):

  • UserInterface/Views/TimelineRuler.js:

(WebInspector.TimelineRuler.prototype._needsMarkerLayout):
(WebInspector.TimelineRuler.prototype._needsSelectionLayout):

  • UserInterface/Views/VisualStyleBackgroundPicker.js:

(WebInspector.VisualStyleBackgroundPicker.prototype.parseValue):

11:13 AM Changeset in webkit [193349] by timothy@apple.com
  • 4 edits
    3 adds in branches/safari-601-branch

Merge r192592. rdar://problem/23221163

11:13 AM Changeset in webkit [193348] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebCore

Merge r192585. rdar://problem/23221163

11:13 AM Changeset in webkit [193347] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebCore

Merge r188222. rdar://problem/23221163

11:13 AM Changeset in webkit [193346] by timothy@apple.com
  • 4 edits
    2 adds
    2 deletes in branches/safari-601-branch

Merge r186891. rdar://problem/23221163

11:12 AM Changeset in webkit [193345] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192921. rdar://problem/23221163

11:12 AM Changeset in webkit [193344] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192908. rdar://problem/23221163

11:12 AM Changeset in webkit [193343] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192804. rdar://problem/23221163

11:12 AM Changeset in webkit [193342] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192785. rdar://problem/23221163

11:12 AM Changeset in webkit [193341] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192784. rdar://problem/23221163

11:12 AM Changeset in webkit [193340] by jer.noble@apple.com
  • 17 edits in trunk/Source

[iOS] Fullscreen -> PiP should resume to Fullscreen, not inline
https://bugs.webkit.org/show_bug.cgi?id=150906

Reviewed by Simon Fraser.

Source/WebCore:

When restoring the user interface when exiting PiP, we should return to Fullscreen if that
is where fullscreen was initiated from. Additionally, when we "auto-PiP" by backgrounding the
app in Fullscreen mode, we should "auto-un-PiP" when restoring the application to foreground.

Rather than have a separate method to request exiting fullscreen, entering standard fullscreen,
and switching to & from PiP, add a new method setFullscreenMode() which does all three.

  • html/HTMLVideoElement.cpp:

(WebCore::presentationModeToFullscreenMode):
(WebCore::HTMLVideoElement::webkitSetPresentationMode):
(WebCore::HTMLVideoElement::setFullscreenMode):

  • html/HTMLVideoElement.h:

Add methods to for clients to request a specific fullscreen mode, and to query whether
the page is currently visible.

  • platform/ios/WebVideoFullscreenControllerAVKit.mm:

(WebVideoFullscreenControllerContext::requestFullscreenMode):
(WebVideoFullscreenControllerContext::isVisible):
(WebVideoFullscreenControllerContext::requestExitFullscreen): Deleted.

  • platform/ios/WebVideoFullscreenModel.h:
  • platform/ios/WebVideoFullscreenModelVideoElement.h:
  • platform/ios/WebVideoFullscreenModelVideoElement.mm:

(WebVideoFullscreenModelVideoElement::requestFullscreenMode):
(WebVideoFullscreenModelVideoElement::isVisible):
(WebVideoFullscreenModelVideoElement::requestExitFullscreen): Deleted.

Track whether returning from PiP should enter fullscreen, or whether foregrounding the app
should cause PiP to return to fullscreen.

  • platform/ios/WebVideoFullscreenInterfaceAVKit.h:
  • platform/ios/WebVideoFullscreenInterfaceAVKit.mm:

(-[WebAVPlayerLayer layoutSublayers]): Renamed from -setBounds:. -layoutSublayers is called

more consistently than -setBounds:, including when a sublayer is added to the layer.

(WebAVPlayerLayerView_stopRoutingVideoToPictureInPicturePlayerLayerView): The PiP WebAVPlayerLayer's

modelVideoLayerFrame property may have been modified, so pass it back up to the fullscreen
layer when exiting PiP.

(WebVideoFullscreenInterfaceAVKit::applicationDidBecomeActive): Request fullscreen if we auto-PiPed.
(WebVideoFullscreenInterfaceAVKit::setupFullscreen): Only recreate owned objects if they did not already exist.
(WebVideoFullscreenInterfaceAVKit::enterFullscreenStandard): If we are in PiP mode, enter fullscreen by stopping PiP.
(WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen): requestExitFullscreen() -> requestFullscreenMode().
(WebVideoFullscreenInterfaceAVKit::willStartPictureInPicture): Animate out the fullscreen window, if exiting Fullscreen -> PiP.
(WebVideoFullscreenInterfaceAVKit::didStartPictureInPicture): Set m_shouldReturnToFullscreenAfterEnteringForeground if we auto-PiPed.
(WebVideoFullscreenInterfaceAVKit::failedToStartPictureInPicture): requestExitFullscreen() -> requestFullscreenMode().
(WebVideoFullscreenInterfaceAVKit::willStopPictureInPicture): If we are returning from PiP -> Fullscreen, do not hide the fullscreen window.
(WebVideoFullscreenInterfaceAVKit::didStopPictureInPicture): If we are returning from PiP -> Fullscreen, show the controls and notify clients.
(WebVideoFullscreenInterfaceAVKit::prepareForPictureInPictureStopWithCompletionHandler): Animate in the fullscreen window, if returning from PiP -> Fullscreen.
(WebVideoFullscreenInterfaceAVKit::shouldExitFullscreenWithReason): Set m_shouldReturnToFullscreenWhenStoppingPiP if we are entering PiP from Fullscreen.

  • platform/spi/cocoa/AVKitSPI.h:

Source/WebKit2:

Add methods to pass isVisible(), applicationDidBecomeActive(), and requestFullscreenMode()
to and from models and interfaces.

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::applicationDidBecomeActive): Notify the fullscreen manager, if preset.

  • UIProcess/ios/WebVideoFullscreenManagerProxy.mm:

(WebKit::WebVideoFullscreenModelContext::requestFullscreenMode): Renamed from requestExitFullscreen(); takes a mode enum.
(WebKit::WebVideoFullscreenModelContext::isVisible): Added.
(WebKit::WebVideoFullscreenManagerProxy::applicationDidBecomeActive): Pass to all existing interfaces.
(WebKit::WebVideoFullscreenManagerProxy::setupFullscreenWithID): Do not re-create the view if it already exists.
(WebKit::WebVideoFullscreenManagerProxy::requestFullscreenMode): Renamed from requestExitFullscreen(); takes a mode enum.
(WebKit::WebVideoFullscreenManagerProxy::isVisible): Added. Query Page::isVisible() and Page::isInWindow(), the latter because

PiP will cause Page::isVisible() to be TRUE even when the containing tab is backgrounded.

(WebKit::WebVideoFullscreenModelContext::requestExitFullscreen): Deleted.
(WebKit::WebVideoFullscreenManagerProxy::requestExitFullscreen): Deleted.

  • WebProcess/ios/WebVideoFullscreenManager.mm:

(WebKit::WebVideoFullscreenManager::enterVideoFullscreenForVideoElement): Only resize the view if we are not already in one of

the fullscreen modes.

(WebKit::WebVideoFullscreenManager::requestFullscreenMode): Renamed from requestExitFullscreen().
(WebKit::WebVideoFullscreenManager::requestExitFullscreen): Deleted.

11:12 AM Changeset in webkit [193339] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192771. rdar://problem/23221163

11:12 AM Changeset in webkit [193338] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192764. rdar://problem/23221163

11:12 AM Changeset in webkit [193337] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192757. rdar://problem/23221163

11:12 AM Changeset in webkit [193336] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192755. rdar://problem/23221163

11:12 AM Changeset in webkit [193335] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source

Merge r192745. rdar://problem/23221163

11:11 AM Changeset in webkit [193334] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192735. rdar://problem/23221163

11:11 AM Changeset in webkit [193333] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192719. rdar://problem/23221163

11:11 AM Changeset in webkit [193332] by timothy@apple.com
  • 8 edits
    1 move
    3 adds
    1 delete in branches/safari-601-branch/Source/WebInspectorUI

Merge r192705. rdar://problem/23221163

11:11 AM Changeset in webkit [193331] by timothy@apple.com
  • 13 edits
    2 adds in branches/safari-601-branch/Source

Merge r192662. rdar://problem/23221163

11:11 AM Changeset in webkit [193330] by timothy@apple.com
  • 7 edits
    4 adds in branches/safari-601-branch

Merge r192641. rdar://problem/23221163

11:11 AM Changeset in webkit [193329] by timothy@apple.com
  • 8 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192616. rdar://problem/23221163

11:11 AM Changeset in webkit [193328] by timothy@apple.com
  • 4 edits
    2 adds in branches/safari-601-branch

Merge r192615. rdar://problem/23221163

11:11 AM Changeset in webkit [193327] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192614. rdar://problem/23221163

11:10 AM Changeset in webkit [193326] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192613. rdar://problem/23221163

11:10 AM Changeset in webkit [193325] by timothy@apple.com
  • 9 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192612. rdar://problem/23221163

11:10 AM Changeset in webkit [193324] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192594. rdar://problem/23221163

11:10 AM Changeset in webkit [193323] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192584. rdar://problem/23221163

11:10 AM Changeset in webkit [193322] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192560. rdar://problem/23221163

11:10 AM Changeset in webkit [193321] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192551. rdar://problem/23221163

11:10 AM Changeset in webkit [193320] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192408. rdar://problem/23221163

11:10 AM Changeset in webkit [193319] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192383. rdar://problem/23221163

11:10 AM Changeset in webkit [193318] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192363. rdar://problem/23221163

11:10 AM Changeset in webkit [193317] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192344. rdar://problem/23221163

11:09 AM Changeset in webkit [193316] by timothy@apple.com
  • 8 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192327. rdar://problem/23221163

11:09 AM Changeset in webkit [193315] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192283. rdar://problem/23221163

11:09 AM Changeset in webkit [193314] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192272. rdar://problem/23221163

11:09 AM Changeset in webkit [193313] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192264. rdar://problem/23221163

11:09 AM Changeset in webkit [193312] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192198. rdar://problem/23221163

11:09 AM Changeset in webkit [193311] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192188. rdar://problem/23221163

11:09 AM Changeset in webkit [193310] by timothy@apple.com
  • 6 edits
    3 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r192165. rdar://problem/23221163

11:09 AM Changeset in webkit [193309] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192110. rdar://problem/23221163

11:09 AM Changeset in webkit [193308] by timothy@apple.com
  • 16 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192086. rdar://problem/23221163

11:09 AM Changeset in webkit [193307] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192076. rdar://problem/23221163

11:08 AM Changeset in webkit [193306] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192070. rdar://problem/23221163

11:08 AM Changeset in webkit [193305] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192065. rdar://problem/23221163

11:08 AM Changeset in webkit [193304] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192063. rdar://problem/23221163

11:08 AM Changeset in webkit [193303] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192050. rdar://problem/23221163

11:08 AM Changeset in webkit [193302] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192049. rdar://problem/23221163

11:08 AM Changeset in webkit [193301] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192048. rdar://problem/23221163

11:08 AM Changeset in webkit [193300] by timothy@apple.com
  • 5 edits
    2 adds in branches/safari-601-branch

Merge r192040. rdar://problem/23221163

11:08 AM Changeset in webkit [193299] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r192005. rdar://problem/23221163

11:08 AM Changeset in webkit [193298] by timothy@apple.com
  • 22 edits
    1 add in branches/safari-601-branch/Source/WebInspectorUI

Merge r191976. rdar://problem/23221163

11:07 AM Changeset in webkit [193297] by timothy@apple.com
  • 11 edits in branches/safari-601-branch/Source

Merge r191967. rdar://problem/23221163

11:07 AM Changeset in webkit [193296] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191817. rdar://problem/23221163

11:07 AM Changeset in webkit [193295] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191770. rdar://problem/23221163

11:07 AM Changeset in webkit [193294] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191764. rdar://problem/23221163

11:07 AM Changeset in webkit [193293] by timothy@apple.com
  • 11 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191740. rdar://problem/23221163

11:07 AM Changeset in webkit [193292] by timothy@apple.com
  • 10 edits in branches/safari-601-branch/Source

Merge r191732. rdar://problem/23221163

11:07 AM Changeset in webkit [193291] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191715. rdar://problem/23221163

11:07 AM Changeset in webkit [193290] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191714. rdar://problem/23221163

11:07 AM Changeset in webkit [193289] by timothy@apple.com
  • 9 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191703. rdar://problem/23221163

11:06 AM Changeset in webkit [193288] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191697. rdar://problem/23221163

11:06 AM Changeset in webkit [193287] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191696. rdar://problem/23221163

11:06 AM Changeset in webkit [193286] by weinig@apple.com
  • 13 edits
    2 moves
    4 adds
    2 deletes in trunk

Promise callbacks should be called at microtask checkpoints
https://bugs.webkit.org/show_bug.cgi?id=147933

Reviewed by Chris Dumez.

Source/WebCore:

  • Re-names MicroTaskQueue and MicroTask to MicrotaskQueue and Microtask to match the spec language.
  • Re-implements MicrotaskQueue and Microtask support suspended Microtasks (via the new KeepInQueue result value a Microtask can have when running) and correct behavior when Microtasks are added to the queue during a Microtask checkpoint.
  • MicrotaskQueue now has a mainThreadQueue() static function, replacing the old singleton() function, which can be used for the Document (non-Worker) Microtasks. For Workers, the a MicrotaskQueue can be separately allocated for each WorkerGlobalScope (though this was not done in this change).
  • Adds a helper subclass of Microtask, ActiveDOMCallbackMicrotask, for Microtasks that are per-ScriptExecutationContext, and need to act as ActiveDOMCallbacks.
  • Re-implement Document (non-Worker) Promises on top of ActiveDOMCallbackMicrotask.
  • Re-implement MutationObserver delivery on top of Microtask.

Layout Test:

fast/dom/microtask-promise-mutation-observer-order.html

  • CMakeLists.txt:
  • WebCore.vcxproj/WebCore.vcxproj:
  • WebCore.xcodeproj/project.pbxproj:
  • dom/DOMAllInOne.cpp:

Add new files.

  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::JSDOMWindowBase::queueTaskToEventLoop):
Switch to using ActiveDOMCallbackMicrotask/MicrotaskQueue rather than ScriptExecutionContext's Task mechanism
for JavaScriptCore tasks.

  • bindings/js/JSMainThreadExecState.cpp:

(WebCore::JSMainThreadExecState::didLeaveScriptContext):
Perform a microtask checkpoint rather than calling MutationObserver code explicitly now that mutation observers
use microtasks.

  • dom/ActiveDOMCallbackMicrotask.cpp: Added.

(WebCore::ActiveDOMCallbackMicrotask::ActiveDOMCallbackMicrotask):
(WebCore::ActiveDOMCallbackMicrotask::~ActiveDOMCallbackMicrotask):
(WebCore::ActiveDOMCallbackMicrotask::run):
(WebCore::ActiveDOMCallbackMicrotask::contextDestroyed):

  • dom/ActiveDOMCallbackMicrotask.h: Added.

Add a helper subclass of Microtask which behaves like a ActiveDOMCallback (e.g. supports suspension
and context destruction).

  • dom/MicroTask.cpp: Renamed to Microtasks.cpp.
  • dom/MicroTask.h: Renamed to Microtasks.h.
  • dom/Microtasks.cpp: Renamed from Source/WebCore/dom/MicroTask.cpp.

(WebCore::Microtask::removeSelfFromQueue):
(WebCore::MicrotaskQueue::mainThreadQueue):
(WebCore::MicrotaskQueue::append):
(WebCore::MicrotaskQueue::remove):
(WebCore::MicrotaskQueue::performMicrotaskCheckpoint):
(WebCore::MicroTaskQueue::singleton): Deleted.
(WebCore::MicroTaskQueue::queueMicroTask): Deleted.
(WebCore::MicroTaskQueue::runMicroTasks): Deleted.

  • dom/Microtasks.h: Renamed from Source/WebCore/dom/MicroTask.h.

(WebCore::Microtask::~Microtask):
(WebCore::MicrotaskQueue::MicrotaskQueue):
(WebCore::MicrotaskQueue::~MicrotaskQueue):
(WebCore::MicroTask::~MicroTask): Deleted.
(WebCore::MicroTaskQueue::~MicroTaskQueue): Deleted.
(WebCore::MicroTaskQueue::MicroTaskQueue): Deleted.
Re-implement MicrotaskQueue and Microtask to support Microtask suspension (via the KeepInQueue result
value) and correct behavior when Microtasks are queued during checkpoints.

  • dom/MutationObserver.cpp:

(WebCore::suspendedMutationObservers):
(WebCore::MutationObserverMicrotask::MutationObserverMicrotask):
(WebCore::MutationObserverMicrotask::~MutationObserverMicrotask):
(WebCore::MutationObserverMicrotask::run):
(WebCore::queueMutationObserverCompoundMicrotask):
(WebCore::MutationObserver::enqueueMutationRecord):
(WebCore::MutationObserver::setHasTransientRegistration):

  • dom/MutationObserver.h:

Re-implement MutationObserver delivery on top of Microtasks.

  • dom/ScriptRunner.cpp:

(WebCore::ScriptRunner::timerFired):
Remove unnecessary call to runMicroTasks().

  • html/parser/HTMLScriptRunner.cpp:

(WebCore::HTMLScriptRunner::executePendingScriptAndDispatchEvent):
(WebCore::HTMLScriptRunner::runScript):
Remove calls to MutationObserver::deliverAllMutations() now that the MicrotaskQueue will take care of it.

(WebCore::HTMLScriptRunner::executeScriptsWaitingForParsing):
Remove unnecessary call to runMicroTasks().

  • testing/Internals.cpp:

(WebCore::Internals::queueMicroTask):
Use ActiveDOMCallbackMicrotask rather than a custom test subclass.

  • testing/MicroTaskTest.cpp: Removed.
  • testing/MicroTaskTest.h: Removed.

Remove custom test subclass of Microtask, just use ActiveDOMCallbackMicrotask directly.

LayoutTests:

  • fast/dom/microtask-promise-mutation-observer-order-expected.txt: Added.
  • fast/dom/microtask-promise-mutation-observer-order.html: Added.
11:06 AM Changeset in webkit [193285] by timothy@apple.com
  • 179 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191693. rdar://problem/23221163

11:05 AM Changeset in webkit [193284] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source

Merge r191692. rdar://problem/23221163

11:05 AM Changeset in webkit [193283] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191689. rdar://problem/23221163

11:05 AM Changeset in webkit [193282] by timothy@apple.com
  • 11 edits in branches/safari-601-branch/Source

Merge r191651. rdar://problem/23221163

11:05 AM Changeset in webkit [193281] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191640. rdar://problem/23221163

11:05 AM Changeset in webkit [193280] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191639. rdar://problem/23221163

11:05 AM Changeset in webkit [193279] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191615. rdar://problem/23221163

11:04 AM Changeset in webkit [193278] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191614. rdar://problem/23221163

11:04 AM Changeset in webkit [193277] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191613. rdar://problem/23221163

11:04 AM Changeset in webkit [193276] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191612. rdar://problem/23221163

11:04 AM Changeset in webkit [193275] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191519. rdar://problem/23221163

11:04 AM Changeset in webkit [193274] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191496. rdar://problem/23221163

11:04 AM Changeset in webkit [193273] by timothy@apple.com
  • 13 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191493. rdar://problem/23221163

11:04 AM Changeset in webkit [193272] by timothy@apple.com
  • 26 edits
    6 adds
    16 deletes in branches/safari-601-branch/Source/WebInspectorUI

Merge r191488. rdar://problem/23221163

11:04 AM Changeset in webkit [193271] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191486. rdar://problem/23221163

11:03 AM Changeset in webkit [193270] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191478. rdar://problem/23221163

11:03 AM Changeset in webkit [193269] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191464. rdar://problem/23221163

11:03 AM Changeset in webkit [193268] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191454. rdar://problem/23221163

11:03 AM Changeset in webkit [193267] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191421. rdar://problem/23221163

11:03 AM Changeset in webkit [193266] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191418. rdar://problem/23221163

11:03 AM Changeset in webkit [193265] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191417. rdar://problem/23221163

11:03 AM Changeset in webkit [193264] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191416. rdar://problem/23221163

11:03 AM Changeset in webkit [193263] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191387. rdar://problem/23221163

11:03 AM Changeset in webkit [193262] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191371. rdar://problem/23221163

11:03 AM Changeset in webkit [193261] by timothy@apple.com
  • 11 edits
    2 adds in branches/safari-601-branch

Merge r191355. rdar://problem/23221163

11:02 AM Changeset in webkit [193260] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191281. rdar://problem/23221163

11:02 AM Changeset in webkit [193259] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191274. rdar://problem/23221163

11:02 AM Changeset in webkit [193258] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191187. rdar://problem/23221163

11:02 AM Changeset in webkit [193257] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191071. rdar://problem/23221163

11:02 AM Changeset in webkit [193256] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191004. rdar://problem/23221163

11:02 AM Changeset in webkit [193255] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r191001. rdar://problem/23221163

11:02 AM Changeset in webkit [193254] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190839. rdar://problem/23221163

11:02 AM Changeset in webkit [193253] by timothy@apple.com
  • 5 edits in branches/safari-601-branch

Merge r190780. rdar://problem/23221163

11:02 AM Changeset in webkit [193252] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190727. rdar://problem/23221163

11:02 AM Changeset in webkit [193251] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190651. rdar://problem/23221163

11:02 AM Changeset in webkit [193250] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190640. rdar://problem/23221163

11:01 AM Changeset in webkit [193249] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190632. rdar://problem/23221163

11:01 AM Changeset in webkit [193248] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190571. rdar://problem/23221163

11:01 AM Changeset in webkit [193247] by timothy@apple.com
  • 4 edits in branches/safari-601-branch

Merge r190551. rdar://problem/23221163

11:01 AM Changeset in webkit [193246] by timothy@apple.com
  • 13 edits in branches/safari-601-branch/Source

Merge r190542. rdar://problem/23221163

11:01 AM Changeset in webkit [193245] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190540. rdar://problem/23221163

11:01 AM Changeset in webkit [193244] by timothy@apple.com
  • 5 edits
    2 adds in branches/safari-601-branch

Merge r190528. rdar://problem/23221163

11:01 AM Changeset in webkit [193243] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190521. rdar://problem/23221163

11:01 AM Changeset in webkit [193242] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190506. rdar://problem/23221163

11:01 AM Changeset in webkit [193241] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190448. rdar://problem/23221163

11:01 AM Changeset in webkit [193240] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190436. rdar://problem/23221163

11:00 AM Changeset in webkit [193239] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190426. rdar://problem/23221163

11:00 AM Changeset in webkit [193238] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source

Merge r190416. rdar://problem/23221163

11:00 AM Changeset in webkit [193237] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190381. rdar://problem/23221163

11:00 AM Changeset in webkit [193236] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190377. rdar://problem/23221163

11:00 AM Changeset in webkit [193235] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190376. rdar://problem/23221163

11:00 AM Changeset in webkit [193234] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190342. rdar://problem/23221163

11:00 AM Changeset in webkit [193233] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190341. rdar://problem/23221163

11:00 AM Changeset in webkit [193232] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190286. rdar://problem/23221163

11:00 AM Changeset in webkit [193231] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190285. rdar://problem/23221163

11:00 AM Changeset in webkit [193230] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190186. rdar://problem/23221163

10:59 AM Changeset in webkit [193229] by timothy@apple.com
  • 6 edits in branches/safari-601-branch

Merge r190184. rdar://problem/23221163

10:59 AM Changeset in webkit [193228] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190149. rdar://problem/23221163

10:59 AM Changeset in webkit [193227] by timothy@apple.com
  • 9 edits
    1 add in branches/safari-601-branch

Merge r190146. rdar://problem/23221163

10:59 AM Changeset in webkit [193226] by timothy@apple.com
  • 7 edits in branches/safari-601-branch

Merge r190110. rdar://problem/23221163

10:59 AM Changeset in webkit [193225] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r190058. rdar://problem/23221163

10:59 AM Changeset in webkit [193224] by timothy@apple.com
  • 8 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189965. rdar://problem/23221163

10:59 AM Changeset in webkit [193223] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189933. rdar://problem/23221163

10:59 AM Changeset in webkit [193222] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189924. rdar://problem/23221163

10:59 AM Changeset in webkit [193221] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189923. rdar://problem/23221163

10:58 AM Changeset in webkit [193220] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189909. rdar://problem/23221163

10:58 AM Changeset in webkit [193219] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189907. rdar://problem/23221163

10:58 AM Changeset in webkit [193218] by timothy@apple.com
  • 12 edits in branches/safari-601-branch/Source

Merge r189883. rdar://problem/23221163

10:58 AM Changeset in webkit [193217] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189872. rdar://problem/23221163

10:58 AM Changeset in webkit [193216] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189845. rdar://problem/23221163

10:58 AM Changeset in webkit [193215] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189828. rdar://problem/23221163

10:58 AM Changeset in webkit [193214] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189816. rdar://problem/23221163

10:58 AM Changeset in webkit [193213] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189815. rdar://problem/23221163

10:58 AM Changeset in webkit [193212] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189814. rdar://problem/23221163

10:58 AM Changeset in webkit [193211] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189763. rdar://problem/23221163

10:57 AM Changeset in webkit [193210] by timothy@apple.com
  • 5 edits in branches/safari-601-branch

Merge r189761. rdar://problem/23221163

10:57 AM Changeset in webkit [193209] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189759. rdar://problem/23221163

10:57 AM Changeset in webkit [193208] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189733. rdar://problem/23221163

10:57 AM Changeset in webkit [193207] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189593. rdar://problem/23221163

10:57 AM Changeset in webkit [193206] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189590. rdar://problem/23221163

10:57 AM Changeset in webkit [193205] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189508. rdar://problem/23221163

10:57 AM Changeset in webkit [193204] by timothy@apple.com
  • 5 edits
    4 adds in branches/safari-601-branch

Merge r189415. rdar://problem/23221163

10:57 AM Changeset in webkit [193203] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189385. rdar://problem/23221163

10:57 AM Changeset in webkit [193202] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189374. rdar://problem/23221163

10:57 AM Changeset in webkit [193201] by timothy@apple.com
  • 5 edits
    8 adds in branches/safari-601-branch

Merge r189373. rdar://problem/23221163

10:57 AM Changeset in webkit [193200] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189238. rdar://problem/23221163

10:56 AM Changeset in webkit [193199] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189236. rdar://problem/23221163

10:56 AM Changeset in webkit [193198] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189232. rdar://problem/23221163

10:56 AM Changeset in webkit [193197] by timothy@apple.com
  • 11 edits
    2 copies
    1 delete in branches/safari-601-branch/Source/WebInspectorUI

Merge r189220. rdar://problem/23221163

10:56 AM Changeset in webkit [193196] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189210. rdar://problem/23221163

10:56 AM Changeset in webkit [193195] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189206. rdar://problem/23221163

10:56 AM Changeset in webkit [193194] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189190. rdar://problem/23221163

10:56 AM Changeset in webkit [193193] by timothy@apple.com
  • 4 edits
    1 move
    1 add in branches/safari-601-branch/Source/WebInspectorUI

Merge r189189. rdar://problem/23221163

10:56 AM Changeset in webkit [193192] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189183. rdar://problem/23221163

10:56 AM Changeset in webkit [193191] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189142. rdar://problem/23221163

10:55 AM Changeset in webkit [193190] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189141. rdar://problem/23221163

10:55 AM Changeset in webkit [193189] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189118. rdar://problem/23221163

10:55 AM Changeset in webkit [193188] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION(r192753): Remote Web Inspector: Enabling Remote Inspection on Auto Inspect candidate Debuggable doesn't show up in debuggers
https://bugs.webkit.org/show_bug.cgi?id=151792

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2015-12-03
Reviewed by Brian Burg.

  • inspector/remote/RemoteInspector.mm:

(Inspector::RemoteInspector::updateAutomaticInspectionCandidate):
When m_debuggablesMap was split into both m_targetMap and m_listingMap
this particular case was missed in updating both the target and listing
when the target is updated. We should match RemoteInspector::updateTarget
and update the listing map as the debuggable may have changed to be
allowed to debug.

10:55 AM Changeset in webkit [193187] by timothy@apple.com
  • 15 edits
    4 adds in branches/safari-601-branch

Merge r189104. rdar://problem/23221163

10:55 AM Changeset in webkit [193186] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189096. rdar://problem/23221163

10:55 AM Changeset in webkit [193185] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189095. rdar://problem/23221163

10:55 AM Changeset in webkit [193184] by timothy@apple.com
  • 14 edits in branches/safari-601-branch

Merge r189032. rdar://problem/23221163

10:55 AM Changeset in webkit [193183] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189008. rdar://problem/23221163

10:55 AM Changeset in webkit [193182] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r189006. rdar://problem/23221163

10:55 AM Changeset in webkit [193181] by timothy@apple.com
  • 17 edits
    11 adds in branches/safari-601-branch

Merge r189002. rdar://problem/23221163

10:54 AM Changeset in webkit [193180] by timothy@apple.com
  • 40 edits
    2 deletes in branches/safari-601-branch/Source/WebInspectorUI

Merge r188993. rdar://problem/23221163

10:54 AM Changeset in webkit [193179] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188967. rdar://problem/23221163

10:54 AM Changeset in webkit [193178] by timothy@apple.com
  • 26 edits in branches/safari-601-branch

Merge r188965. rdar://problem/23221163

10:54 AM Changeset in webkit [193177] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188964. rdar://problem/23221163

10:54 AM Changeset in webkit [193176] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188963. rdar://problem/23221163

10:53 AM Changeset in webkit [193175] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188962. rdar://problem/23221163

10:53 AM Changeset in webkit [193174] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188946. rdar://problem/23221163

10:53 AM Changeset in webkit [193173] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188916. rdar://problem/23221163

10:53 AM Changeset in webkit [193172] by timothy@apple.com
  • 4 edits
    4 adds in branches/safari-601-branch

Merge r188897. rdar://problem/23221163

10:53 AM Changeset in webkit [193171] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188876. rdar://problem/23221163

10:53 AM Changeset in webkit [193170] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188862. rdar://problem/23221163

10:53 AM Changeset in webkit [193169] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188861. rdar://problem/23221163

10:53 AM Changeset in webkit [193168] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188848. rdar://problem/23221163

10:53 AM Changeset in webkit [193167] by timothy@apple.com
  • 14 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188837. rdar://problem/23221163

10:53 AM Changeset in webkit [193166] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188818. rdar://problem/23221163

10:52 AM Changeset in webkit [193165] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188816. rdar://problem/23221163

10:52 AM Changeset in webkit [193164] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188760. rdar://problem/23221163

10:52 AM Changeset in webkit [193163] by timothy@apple.com
  • 4 edits
    6 adds in branches/safari-601-branch

Merge r188756. rdar://problem/23221163

10:52 AM Changeset in webkit [193162] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188750. rdar://problem/23221163

10:52 AM Changeset in webkit [193161] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188749. rdar://problem/23221163

10:52 AM Changeset in webkit [193160] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188739. rdar://problem/23221163

10:52 AM Changeset in webkit [193159] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188733. rdar://problem/23221163

10:52 AM Changeset in webkit [193158] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188732. rdar://problem/23221163

10:52 AM Changeset in webkit [193157] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188731. rdar://problem/23221163

10:52 AM Changeset in webkit [193156] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188730. rdar://problem/23221163

10:51 AM Changeset in webkit [193155] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188728. rdar://problem/23221163

10:51 AM Changeset in webkit [193154] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188727. rdar://problem/23221163

10:51 AM Changeset in webkit [193153] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188725. rdar://problem/23221163

10:51 AM Changeset in webkit [193152] by timothy@apple.com
  • 26 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188708. rdar://problem/23221163

10:51 AM Changeset in webkit [193151] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188691. rdar://problem/23221163

10:51 AM Changeset in webkit [193150] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188683. rdar://problem/23221163

10:51 AM Changeset in webkit [193149] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188682. rdar://problem/23221163

10:51 AM Changeset in webkit [193148] by timothy@apple.com
  • 23 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188679. rdar://problem/23221163

10:51 AM Changeset in webkit [193147] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188678. rdar://problem/23221163

10:50 AM Changeset in webkit [193146] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188676. rdar://problem/23221163

10:50 AM Changeset in webkit [193145] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188670. rdar://problem/23221163

10:50 AM Changeset in webkit [193144] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188667. rdar://problem/23221163

10:50 AM Changeset in webkit [193143] by timothy@apple.com
  • 1 edit
    3 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188665. rdar://problem/23221163

10:50 AM Changeset in webkit [193142] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188664. rdar://problem/23221163

10:50 AM Changeset in webkit [193141] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188655. rdar://problem/23221163

10:50 AM Changeset in webkit [193140] by timothy@apple.com
  • 10 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188650. rdar://problem/23221163

10:50 AM Changeset in webkit [193139] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188645. rdar://problem/23221163

10:50 AM Changeset in webkit [193138] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188637. rdar://problem/23221163

10:50 AM Changeset in webkit [193137] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188636. rdar://problem/23221163

10:50 AM Changeset in webkit [193136] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188635. rdar://problem/23221163

10:49 AM Changeset in webkit [193135] by timothy@apple.com
  • 14 edits
    4 adds in branches/safari-601-branch

Merge r188631. rdar://problem/23221163

10:49 AM Changeset in webkit [193134] by dbates@webkit.org
  • 1 edit
    2 adds in trunk/LayoutTests

ASSERT_WITH_SECURITY_IMPLICATION in WebCore::DocumentOrderedMap::add()
https://bugs.webkit.org/show_bug.cgi?id=126662
<rdar://problem/15775508>

Reviewed by Brent Fulgham.

Add test to ensure that we do not assert when inserting a subtree that has an element with
a duplicate id before removing the original subtree.

  • svg/custom/insert-subtree-with-duplicate-id-before-removing-subtree-expected.txt: Added.
  • svg/custom/insert-subtree-with-duplicate-id-before-removing-subtree.svg: Added.
10:49 AM Changeset in webkit [193133] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188630. rdar://problem/23221163

10:49 AM Changeset in webkit [193132] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188629. rdar://problem/23221163

10:49 AM Changeset in webkit [193131] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188628. rdar://problem/23221163

10:49 AM Changeset in webkit [193130] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188626. rdar://problem/23221163

10:49 AM Changeset in webkit [193129] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188621. rdar://problem/23221163

10:49 AM Changeset in webkit [193128] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188617. rdar://problem/23221163

10:49 AM Changeset in webkit [193127] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188616. rdar://problem/23221163

10:49 AM Changeset in webkit [193126] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188614. rdar://problem/23221163

10:49 AM Changeset in webkit [193125] by commit-queue@webkit.org
  • 15 edits in trunk/Source/JavaScriptCore

[JSC] Add CLZ support to B3
https://bugs.webkit.org/show_bug.cgi?id=151799

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-03
Reviewed by Michael Saboff.

Previously we were counting on LLVM to select LZCNT
when its available.
Since we have to do that ourself now, I added feature
detection based on the CPUID. The MacroAssembler just
pick the best available lowering based on the platform.

  • assembler/MacroAssemblerX86Common.cpp:
  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::countLeadingZeros32):
(JSC::MacroAssemblerX86Common::supportsLZCNT):
(JSC::MacroAssemblerX86Common::clz32AfterBsr):

  • assembler/MacroAssemblerX86_64.h:

(JSC::MacroAssemblerX86_64::countLeadingZeros64):
(JSC::MacroAssemblerX86_64::clz64AfterBsr):

  • assembler/X86Assembler.h:

(JSC::X86Assembler::lzcnt_rr):
(JSC::X86Assembler::lzcnt_mr):
(JSC::X86Assembler::lzcntq_rr):
(JSC::X86Assembler::lzcntq_mr):
(JSC::X86Assembler::bsr_mr):
(JSC::X86Assembler::bsrq_rr):
(JSC::X86Assembler::bsrq_mr):

  • b3/B3LowerToAir.cpp:

(JSC::B3::Air::LowerToAir::lower):

  • b3/B3Opcode.cpp:

(WTF::printInternal):

  • b3/B3Opcode.h:
  • b3/B3Validate.cpp:
  • b3/B3Value.cpp:

(JSC::B3::Value::effects):
(JSC::B3::Value::key):
(JSC::B3::Value::typeFor):

  • b3/air/AirOpcode.opcodes:
  • b3/testb3.cpp:

(JSC::B3::countLeadingZero):
(JSC::B3::testClzArg64):
(JSC::B3::testClzMem64):
(JSC::B3::testClzArg32):
(JSC::B3::testClzMem32):
(JSC::B3::doubleOperands):
(JSC::B3::run):

  • ftl/FTLB3Output.h:

(JSC::FTL::Output::ctlz32):

  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::compileArithClz32):

  • ftl/FTLOutput.h:

(JSC::FTL::Output::ctlz32):

10:49 AM Changeset in webkit [193124] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188601. rdar://problem/23221163

10:48 AM Changeset in webkit [193123] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188586. rdar://problem/23221163

10:48 AM Changeset in webkit [193122] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188581. rdar://problem/23221163

10:48 AM Changeset in webkit [193121] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188578. rdar://problem/23221163

10:48 AM Changeset in webkit [193120] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188576. rdar://problem/23221163

10:48 AM Changeset in webkit [193119] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188573. rdar://problem/23221163

10:48 AM Changeset in webkit [193118] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188572. rdar://problem/23221163

10:48 AM Changeset in webkit [193117] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188571. rdar://problem/23221163

10:48 AM Changeset in webkit [193116] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188570. rdar://problem/23221163

10:48 AM Changeset in webkit [193115] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source

Merge r188549. rdar://problem/23221163

10:48 AM Changeset in webkit [193114] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188546. rdar://problem/23221163

10:48 AM Changeset in webkit [193113] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188506. rdar://problem/23221163

10:47 AM Changeset in webkit [193112] by timothy@apple.com
  • 5 edits
    2 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188503. rdar://problem/23221163

10:47 AM Changeset in webkit [193111] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188496. rdar://problem/23221163

10:47 AM Changeset in webkit [193110] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188494. rdar://problem/23221163

10:47 AM Changeset in webkit [193109] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188491. rdar://problem/23221163

10:47 AM Changeset in webkit [193108] by timothy@apple.com
  • 9 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188490. rdar://problem/23221163

10:47 AM Changeset in webkit [193107] by timothy@apple.com
  • 1 edit
    5 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188484. rdar://problem/23221163

10:47 AM Changeset in webkit [193106] by timothy@apple.com
  • 2 edits
    5 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188483. rdar://problem/23221163

10:47 AM Changeset in webkit [193105] by timothy@apple.com
  • 3 edits
    1 add in branches/safari-601-branch/Source/WebInspectorUI

Merge r188480. rdar://problem/23221163

10:47 AM Changeset in webkit [193104] by timothy@apple.com
  • 3 edits
    2 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188479. rdar://problem/23221163

10:46 AM Changeset in webkit [193103] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188442. rdar://problem/23221163

10:46 AM Changeset in webkit [193102] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188429. rdar://problem/23221163

10:46 AM Changeset in webkit [193101] by beidson@apple.com
  • 10 edits in trunk/Source/WebCore

Add GetterRaisesExceptionWithMessage and SetterRaisesExceptionWithMessage to the code generator.
https://bugs.webkit.org/show_bug.cgi?id=151807

Reviewed by Alex Christensen.

No new tests (Covered by changes to existing bindings tests).

While we're at it, rework the existing 'RaisesExceptionWithMessage' concept to use a struct instead of
two separate variables to reduce complexity.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):
(GenerateImplementationFunctionCall):
(GenerateConstructorDefinition):
(GenerateParametersCheck): Deleted.
(GenerateReturnParameters): Deleted.

  • bindings/scripts/IDLAttributes.txt:
  • bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:

(webkit_dom_test_obj_set_property):
(webkit_dom_test_obj_get_property):
(webkit_dom_test_obj_class_init):
(webkit_dom_test_obj_get_attr_with_getter_exception_with_message):
(webkit_dom_test_obj_set_attr_with_getter_exception_with_message):
(webkit_dom_test_obj_get_attr_with_setter_exception_with_message):
(webkit_dom_test_obj_set_attr_with_setter_exception_with_message):

  • bindings/scripts/test/GObject/WebKitDOMTestObj.h:
  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::jsTestObjAttrWithGetterExceptionWithMessage):
(WebCore::jsTestObjAttrWithSetterExceptionWithMessage):
(WebCore::setJSTestObjAttrWithGetterExceptionWithMessage):
(WebCore::setJSTestObjAttrWithSetterExceptionWithMessage):
(WebCore::jsTestObjPrototypeFunctionMethodWithExceptionWithMessage):

  • bindings/scripts/test/ObjC/DOMTestObj.h:
  • bindings/scripts/test/ObjC/DOMTestObj.mm:

(-[DOMTestObj attrWithGetterExceptionWithMessage]):
(-[DOMTestObj setAttrWithGetterExceptionWithMessage:]):
(-[DOMTestObj attrWithSetterExceptionWithMessage]):
(-[DOMTestObj setAttrWithSetterExceptionWithMessage:]):

  • bindings/scripts/test/TestObj.idl:
  • dom/ExceptionCode.h:
10:46 AM Changeset in webkit [193100] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188427. rdar://problem/23221163

10:46 AM Changeset in webkit [193099] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188408. rdar://problem/23221163

10:46 AM Changeset in webkit [193098] by timothy@apple.com
  • 14 edits
    3 adds in branches/safari-601-branch

Merge r188407. rdar://problem/23221163

10:46 AM Changeset in webkit [193097] by timothy@apple.com
  • 7 edits in branches/safari-601-branch

Merge r188403. rdar://problem/23221163

10:46 AM Changeset in webkit [193096] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188398. rdar://problem/23221163

10:46 AM Changeset in webkit [193095] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188396. rdar://problem/23221163

10:46 AM Changeset in webkit [193094] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188382. rdar://problem/23221163

10:46 AM Changeset in webkit [193093] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188373. rdar://problem/23221163

10:45 AM Changeset in webkit [193092] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188372. rdar://problem/23221163

10:45 AM Changeset in webkit [193091] by timothy@apple.com
  • 10 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188360. rdar://problem/23221163

10:45 AM Changeset in webkit [193090] by timothy@apple.com
  • 5 edits
    3 adds in branches/safari-601-branch

Merge r188353. rdar://problem/23221163

10:45 AM Changeset in webkit [193089] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188343. rdar://problem/23221163

10:45 AM Changeset in webkit [193088] by timothy@apple.com
  • 20 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188336. rdar://problem/23221163

10:45 AM Changeset in webkit [193087] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188330. rdar://problem/23221163

10:45 AM Changeset in webkit [193086] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188328. rdar://problem/23221163

10:45 AM Changeset in webkit [193085] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188326. rdar://problem/23221163

10:44 AM Changeset in webkit [193084] by timothy@apple.com
  • 29 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188325. rdar://problem/23221163

10:44 AM Changeset in webkit [193083] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188321. rdar://problem/23221163

10:44 AM Changeset in webkit [193082] by timothy@apple.com
  • 10 edits
    3 adds
    2 deletes in branches/safari-601-branch

Merge r188283. rdar://problem/23221163

10:44 AM Changeset in webkit [193081] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188260. rdar://problem/23221163

10:44 AM Changeset in webkit [193080] by timothy@apple.com
  • 1 edit
    8 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188238. rdar://problem/23221163

10:44 AM Changeset in webkit [193079] by timothy@apple.com
  • 3 edits
    30 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188229. rdar://problem/23221163

10:43 AM Changeset in webkit [193078] by timothy@apple.com
  • 5 edits
    4 adds in branches/safari-601-branch/Source/WebInspectorUI

Merge r188226. rdar://problem/23221163

10:43 AM Changeset in webkit [193077] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188221. rdar://problem/23221163

10:43 AM Changeset in webkit [193076] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188192. rdar://problem/23221163

10:43 AM Changeset in webkit [193075] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188191. rdar://problem/23221163

10:43 AM Changeset in webkit [193074] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188188. rdar://problem/23221163

10:43 AM Changeset in webkit [193073] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188184. rdar://problem/23221163

10:43 AM Changeset in webkit [193072] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188138. rdar://problem/23221163

10:43 AM Changeset in webkit [193071] by timothy@apple.com
  • 7 edits
    1 delete in branches/safari-601-branch/Source/WebInspectorUI

Merge r188029. rdar://problem/23221163

10:43 AM Changeset in webkit [193070] by timothy@apple.com
  • 12 edits
    1 copy
    4 adds
    1 delete in branches/safari-601-branch/Source/WebInspectorUI

Merge r188028. rdar://problem/23221163

10:42 AM Changeset in webkit [193069] by timothy@apple.com
  • 11 edits
    3 copies
    3 adds in branches/safari-601-branch

Merge r188017. rdar://problem/23221163

10:42 AM Changeset in webkit [193068] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188015. rdar://problem/23221163

10:42 AM Changeset in webkit [193067] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188007. rdar://problem/23221163

10:42 AM Changeset in webkit [193066] by timothy@apple.com
  • 8 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r188006. rdar://problem/23221163

10:42 AM Changeset in webkit [193065] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187986. rdar://problem/23221163

10:42 AM Changeset in webkit [193064] by timothy@apple.com
  • 13 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187968. rdar://problem/23221163

10:42 AM Changeset in webkit [193063] by timothy@apple.com
  • 35 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187967. rdar://problem/23221163

10:41 AM Changeset in webkit [193062] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187960. rdar://problem/23221163

10:41 AM Changeset in webkit [193061] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187929. rdar://problem/23221163

10:41 AM Changeset in webkit [193060] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187923. rdar://problem/23221163

10:41 AM Changeset in webkit [193059] by timothy@apple.com
  • 3 edits in branches/safari-601-branch

Merge r187903. rdar://problem/23221163

10:41 AM Changeset in webkit [193058] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187902. rdar://problem/23221163

10:41 AM Changeset in webkit [193057] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187900. rdar://problem/23221163

10:41 AM Changeset in webkit [193056] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187899. rdar://problem/23221163

10:41 AM Changeset in webkit [193055] by timothy@apple.com
  • 13 edits
    1 copy
    1 add in branches/safari-601-branch/Source/WebInspectorUI

Merge r187895. rdar://problem/23221163

10:35 AM Changeset in webkit [193054] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187887. rdar://problem/23221163

10:35 AM Changeset in webkit [193053] by timothy@apple.com
  • 17 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187873. rdar://problem/23221163

10:35 AM Changeset in webkit [193052] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187872. rdar://problem/23221163

10:35 AM Changeset in webkit [193051] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187775. rdar://problem/23221163

10:35 AM Changeset in webkit [193050] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187773. rdar://problem/23221163

10:35 AM Changeset in webkit [193049] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187732. rdar://problem/23221163

10:35 AM Changeset in webkit [193048] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187730. rdar://problem/23221163

10:35 AM Changeset in webkit [193047] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187715. rdar://problem/23221163

10:35 AM Changeset in webkit [193046] by timothy@apple.com
  • 5 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187714. rdar://problem/23221163

10:34 AM Changeset in webkit [193045] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187708. rdar://problem/23221163

10:34 AM Changeset in webkit [193044] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187700. rdar://problem/23221163

10:34 AM Changeset in webkit [193043] by timothy@apple.com
  • 20 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187689. rdar://problem/23221163

10:34 AM Changeset in webkit [193042] by timothy@apple.com
  • 7 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187634. rdar://problem/23221163

10:34 AM Changeset in webkit [193041] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187625. rdar://problem/23221163

10:34 AM Changeset in webkit [193040] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187619. rdar://problem/23221163

10:34 AM Changeset in webkit [193039] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187599. rdar://problem/23221163

10:34 AM Changeset in webkit [193038] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187598. rdar://problem/23221163

10:34 AM Changeset in webkit [193037] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187578. rdar://problem/23221163

10:34 AM Changeset in webkit [193036] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187577. rdar://problem/23221163

10:33 AM Changeset in webkit [193035] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187576. rdar://problem/23221163

10:33 AM Changeset in webkit [193034] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187570. rdar://problem/23221163

10:33 AM Changeset in webkit [193033] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187528. rdar://problem/23221163

10:33 AM Changeset in webkit [193032] by timothy@apple.com
  • 13 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187519. rdar://problem/23221163

10:33 AM Changeset in webkit [193031] by timothy@apple.com
  • 5 edits
    2 adds in branches/safari-601-branch

Merge r187507. rdar://problem/23221163

10:33 AM Changeset in webkit [193030] by timothy@apple.com
  • 6 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187500. rdar://problem/23221163

10:33 AM Changeset in webkit [193029] by timothy@apple.com
  • 25 edits
    6 adds in branches/safari-601-branch

Merge r187496. rdar://problem/23221163

10:33 AM Changeset in webkit [193028] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187480. rdar://problem/23221163

10:32 AM Changeset in webkit [193027] by timothy@apple.com
  • 13 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187468. rdar://problem/23221163

10:32 AM Changeset in webkit [193026] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187465. rdar://problem/23221163

10:32 AM Changeset in webkit [193025] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187450. rdar://problem/23221163

10:32 AM Changeset in webkit [193024] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187434. rdar://problem/23221163

10:32 AM Changeset in webkit [193023] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187405. rdar://problem/23221163

10:32 AM Changeset in webkit [193022] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187404. rdar://problem/23221163

10:32 AM Changeset in webkit [193021] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187350. rdar://problem/23221163

10:32 AM Changeset in webkit [193020] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187280. rdar://problem/23221163

10:32 AM Changeset in webkit [193019] by timothy@apple.com
  • 17 edits
    2 adds in branches/safari-601-branch

Merge r187249. rdar://problem/23221163

10:31 AM Changeset in webkit [193018] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187227. rdar://problem/23221163

10:31 AM Changeset in webkit [193017] by timothy@apple.com
  • 9 edits
    2 adds in branches/safari-601-branch

Merge r187211. rdar://problem/23221163

10:31 AM Changeset in webkit [193016] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187207. rdar://problem/23221163

10:31 AM Changeset in webkit [193015] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187195. rdar://problem/23221163

10:31 AM Changeset in webkit [193014] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187158. rdar://problem/23221163

10:31 AM Changeset in webkit [193013] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187147. rdar://problem/23221163

10:31 AM Changeset in webkit [193012] by timothy@apple.com
  • 73 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r187105. rdar://problem/23221163

10:30 AM Changeset in webkit [193011] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186877. rdar://problem/23221163

10:30 AM Changeset in webkit [193010] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186831. rdar://problem/23221163

10:30 AM Changeset in webkit [193009] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186824. rdar://problem/23221163

10:30 AM Changeset in webkit [193008] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186796. rdar://problem/23221163

10:30 AM Changeset in webkit [193007] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186767. rdar://problem/23221163

10:30 AM Changeset in webkit [193006] by timothy@apple.com
  • 2 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186748. rdar://problem/23221163

10:30 AM Changeset in webkit [193005] by timothy@apple.com
  • 10 edits in branches/safari-601-branch/Source

Merge r186724. rdar://problem/23221163

10:29 AM Changeset in webkit [193004] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186717. rdar://problem/23221163

10:29 AM Changeset in webkit [193003] by timothy@apple.com
  • 3 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186708. rdar://problem/23221163

10:29 AM Changeset in webkit [193002] by timothy@apple.com
  • 14 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186698. rdar://problem/23221163

10:29 AM Changeset in webkit [193001] by timothy@apple.com
  • 4 edits in branches/safari-601-branch/Source/WebInspectorUI

Merge r186695. rdar://problem/23221163

9:57 AM Changeset in webkit [193000] by jfernandez@igalia.com
  • 3 edits
    2 adds in trunk

[css-grid] margin-left:auto and margin-top:auto discards the margin on opposite side
https://bugs.webkit.org/show_bug.cgi?id=151802

Reviewed by Sergio Villar Senin.

Source/WebCore:

When resolving auto margins so that they use the available space, in the
corresponding axis, we must consider that there might be other specified
margins. Such margins must account to determine the actual available space.

Test: fast/css-grid-layout/grid-item-auto-margins-must-respect-specified-margins.html

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::updateAutoMarginsInRowAxisIfNeeded):
(WebCore::RenderGrid::updateAutoMarginsInColumnAxisIfNeeded):

LayoutTests:

Tests to verify the specified margins account for determining the available space for
auto-margins alignment.

  • fast/css-grid-layout/grid-item-auto-margins-must-respect-specified-margins-expected.txt: Added.
  • fast/css-grid-layout/grid-item-auto-margins-must-respect-specified-margins.html: Added.
9:08 AM Changeset in webkit [192999] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Rebaselining svg/custom/bug78807.svg since actual results now match Mac expectations
https://bugs.webkit.org/show_bug.cgi?id=151804

Unreviewed test gardening.

  • platform/win/svg/custom/bug78807-expected.txt:
8:43 AM Changeset in webkit [192998] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Skipping failing sputnik/Unicode/Unicode_510 tests pending further investigation
https://bugs.webkit.org/show_bug.cgi?id=151505

Unreviewed test gardening.

  • platform/win/TestExpectations:
8:18 AM Changeset in webkit [192997] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking fast/css/pseudo-visited-background-color-on-input.html as failing on win
https://bugs.webkit.org/show_bug.cgi?id=151756

Unreviewed test gardening.

  • platform/win/TestExpectations:
8:14 AM Changeset in webkit [192996] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

fast/borders/hidpi-border-clipping-right-after-move.html
https://bugs.webkit.org/show_bug.cgi?id=151754

Unreviewed test gardening.

  • platform/win/TestExpectations:
4:51 AM Changeset in webkit [192995] by Antti Koivisto
  • 43 edits
    2 moves in trunk/Source

Move ResourceLoadScheduler to WebKit1
https://bugs.webkit.org/show_bug.cgi?id=151743

Reviewed by Alex Christensen.

Source/WebCore:

It is no longer used by WebKit2. Simplify the WebKit/WebCore interface.

  • WebCore.xcodeproj/project.pbxproj:
  • dom/ContainerNode.cpp:
  • dom/Document.cpp:

(WebCore::Document::styleForElementIgnoringPendingStylesheets):

  • dom/Document.h:
  • loader/DocumentLoader.h:
  • loader/LoaderStrategy.cpp:

(WebCore::LoaderStrategy::~LoaderStrategy):
(WebCore::ResourceLoadSuspender::ResourceLoadSuspender):
(WebCore::ResourceLoadSuspender::~ResourceLoadSuspender):
(WebCore::LoaderStrategy::resourceLoadScheduler): Deleted.
(WebCore::LoaderStrategy::loadResourceSynchronously): Deleted.
(WebCore::LoaderStrategy::createBlobRegistry): Deleted.
(WebCore::LoaderStrategy::createPingHandle): Deleted.

  • loader/LoaderStrategy.h:

Loading functions implemented on WebKit side move to pure virtual LoaderStrategy.

  • loader/ResourceLoadScheduler.cpp: Removed.
  • loader/ResourceLoadScheduler.h: Removed.

ResourceLoadScheduler moves to WebKit1 as WebResourceLoadScheduler.

  • loader/ResourceLoader.cpp:

(WebCore::ResourceLoader::finishNetworkLoad):
(WebCore::ResourceLoader::setDefersLoading):
(WebCore::ResourceLoader::frameLoader):
(WebCore::ResourceLoader::willSwitchToSubstituteResource):
(WebCore::ResourceLoader::willSendRequestInternal):

  • loader/archive/ArchiveResourceCollection.h:
  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::load):

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::CachedResourceLoader::performPostLoadActions):
(WebCore::CachedResourceLoader::incrementRequestCount):

  • platform/PlatformStrategies.h:

(WebCore::PlatformStrategies::pluginStrategy):
(WebCore::PlatformStrategies::blobRegistry):

Move BlobRegistry factory function here from LoaderStrategy as this allows network process to have null loaderStrategy.
(it could be renamed BlobStrategy for consistency later).

(WebCore::PlatformStrategies::PlatformStrategies):

  • platform/network/BlobRegistry.cpp:

(WebCore::blobRegistry):
(WebCore::BlobRegistry::~BlobRegistry):

  • platform/network/ResourceRequestBase.h:
  • style/StyleResolveTree.cpp:

(WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler):
(WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler):

Source/WebKit:

  • WebCoreSupport/WebResourceLoadScheduler.cpp: Copied from Source/WebCore/loader/ResourceLoadScheduler.cpp.

(webResourceLoadScheduler):
(WebResourceLoadScheduler::hostForURL):
(WebResourceLoadScheduler::WebResourceLoadScheduler):
(WebResourceLoadScheduler::~WebResourceLoadScheduler):
(WebResourceLoadScheduler::scheduleSubresourceLoad):
(WebResourceLoadScheduler::loadResourceSynchronously):
(WebResourceLoadScheduler::schedulePluginStreamLoad):
(WebResourceLoadScheduler::scheduleLoad):
(WebResourceLoadScheduler::remove):
(WebResourceLoadScheduler::setDefersLoading):
(WebResourceLoadScheduler::crossOriginRedirectReceived):
(WebResourceLoadScheduler::servePendingRequests):
(WebResourceLoadScheduler::suspendPendingRequests):
(WebResourceLoadScheduler::resumePendingRequests):
(WebResourceLoadScheduler::scheduleServePendingRequests):
(WebResourceLoadScheduler::requestTimerFired):
(WebResourceLoadScheduler::HostInformation::HostInformation):
(WebResourceLoadScheduler::HostInformation::~HostInformation):
(WebResourceLoadScheduler::HostInformation::priorityToIndex):
(WebResourceLoadScheduler::HostInformation::schedule):
(WebResourceLoadScheduler::HostInformation::addLoadInProgress):
(WebResourceLoadScheduler::HostInformation::remove):
(WebResourceLoadScheduler::HostInformation::hasRequests):
(WebResourceLoadScheduler::HostInformation::limitRequests):
(WebResourceLoadScheduler::createPingHandle):
(WebCore::ResourceLoadScheduler::hostForURL): Deleted.
(WebCore::resourceLoadScheduler): Deleted.
(WebCore::ResourceLoadScheduler::ResourceLoadScheduler): Deleted.
(WebCore::ResourceLoadScheduler::~ResourceLoadScheduler): Deleted.
(WebCore::ResourceLoadScheduler::scheduleSubresourceLoad): Deleted.
(WebCore::ResourceLoadScheduler::schedulePluginStreamLoad): Deleted.
(WebCore::ResourceLoadScheduler::scheduleLoad): Deleted.
(WebCore::ResourceLoadScheduler::remove): Deleted.
(WebCore::ResourceLoadScheduler::setDefersLoading): Deleted.
(WebCore::ResourceLoadScheduler::crossOriginRedirectReceived): Deleted.
(WebCore::ResourceLoadScheduler::servePendingRequests): Deleted.
(WebCore::ResourceLoadScheduler::suspendPendingRequests): Deleted.
(WebCore::ResourceLoadScheduler::resumePendingRequests): Deleted.
(WebCore::ResourceLoadScheduler::scheduleServePendingRequests): Deleted.
(WebCore::ResourceLoadScheduler::requestTimerFired): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::HostInformation): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::~HostInformation): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::priorityToIndex): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::schedule): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::addLoadInProgress): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::remove): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::hasRequests): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::limitRequests): Deleted.

  • WebCoreSupport/WebResourceLoadScheduler.h: Copied from Source/WebCore/loader/ResourceLoadScheduler.h.

(WebResourceLoadScheduler::isSerialLoadingEnabled):
(WebResourceLoadScheduler::setSerialLoadingEnabled):
(WebResourceLoadScheduler::HostInformation::name):
(WebResourceLoadScheduler::HostInformation::requestsPending):
(WebCore::ResourceLoadScheduler::isSerialLoadingEnabled): Deleted.
(WebCore::ResourceLoadScheduler::setSerialLoadingEnabled): Deleted.
(WebCore::ResourceLoadScheduler::Suspender::Suspender): Deleted.
(WebCore::ResourceLoadScheduler::Suspender::~Suspender): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::name): Deleted.
(WebCore::ResourceLoadScheduler::HostInformation::requestsPending): Deleted.

  • WebKit.xcodeproj/project.pbxproj:

Source/WebKit/mac:

  • Plugins/Hosted/HostedNetscapePluginStream.mm:

(WebKit::HostedNetscapePluginStream::start):
(WebKit::HostedNetscapePluginStream::stop):

  • Plugins/WebNetscapePluginStream.mm:

(WebNetscapePluginStream::start):
(WebNetscapePluginStream::stop):

  • WebCoreSupport/WebPlatformStrategies.h:
  • WebCoreSupport/WebPlatformStrategies.mm:

(WebPlatformStrategies::createLoaderStrategy):
(WebPlatformStrategies::createPasteboardStrategy):
(WebPlatformStrategies::createPluginStrategy):
(WebPlatformStrategies::createBlobRegistry):
(WebPlatformStrategies::cookiesForDOM):

  • WebView/WebView.mm:

(-[WebView _dispatchPendingLoadRequests]):
(+[WebView _setLoadResourcesSerially:]):
(+[WebView _HTTPPipeliningEnabled]):

Source/WebKit2:

  • NetworkProcess/NetworkProcessPlatformStrategies.cpp:

(WebKit::NetworkProcessPlatformStrategies::createCookiesStrategy):
(WebKit::NetworkProcessPlatformStrategies::createLoaderStrategy):
(WebKit::NetworkProcessPlatformStrategies::createPasteboardStrategy):
(WebKit::NetworkProcessPlatformStrategies::createPluginStrategy):
(WebKit::NetworkProcessPlatformStrategies::createBlobRegistry):
(WebKit::NetworkProcessPlatformStrategies::resourceLoadScheduler): Deleted.
(WebKit::NetworkProcessPlatformStrategies::loadResourceSynchronously): Deleted.

  • NetworkProcess/NetworkProcessPlatformStrategies.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:
  • WebProcess/Network/WebResourceLoadScheduler.cpp:

(WebKit::WebResourceLoadScheduler::~WebResourceLoadScheduler):
(WebKit::WebResourceLoadScheduler::loadResource):
(WebKit::WebResourceLoadScheduler::resumePendingRequests):
(WebKit::WebResourceLoadScheduler::networkProcessCrashed):
(WebKit::WebResourceLoadScheduler::loadResourceSynchronously):
(WebKit::WebResourceLoadScheduler::createPingHandle):
(WebKit::WebResourceLoadScheduler::scheduleSubresourceLoad): Deleted.
(WebKit::WebResourceLoadScheduler::setSerialLoadingEnabled): Deleted.

  • WebProcess/Network/WebResourceLoadScheduler.h:

(WebKit::WebResourceLoadScheduler::webResourceLoaderForIdentifier):

  • WebProcess/Plugins/PluginView.cpp:

(WebKit::PluginView::Stream::start):
(WebKit::PluginView::Stream::cancel):

  • WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:

(WebKit::WebPlatformStrategies::createLoaderStrategy):
(WebKit::WebPlatformStrategies::createPasteboardStrategy):
(WebKit::WebPlatformStrategies::createPluginStrategy):
(WebKit::WebPlatformStrategies::createBlobRegistry):
(WebKit::WebPlatformStrategies::cookiesForDOM):
(WebKit::WebPlatformStrategies::deleteCookie):
(WebKit::WebPlatformStrategies::refreshPlugins):
(WebKit::WebPlatformStrategies::resourceLoadScheduler): Deleted.
(WebKit::WebPlatformStrategies::loadResourceSynchronously): Deleted.
(WebKit::WebPlatformStrategies::createPingHandle): Deleted.

  • WebProcess/WebCoreSupport/WebPlatformStrategies.h:
12:07 AM Changeset in webkit [192994] by Gyuyoung Kim
  • 2 edits in trunk/LayoutTests

Unreviewed EFL urgent gardening. Skip web-platform-tests
because it has been timeout since r192796.

  • platform/efl/TestExpectations:

Dec 2, 2015:

9:42 PM Changeset in webkit [192993] by mark.lam@apple.com
  • 19 edits
    3 adds in trunk

Polymorphic operand types for DFG and FTL mul.
https://bugs.webkit.org/show_bug.cgi?id=151746

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Perf on benchmarks is neutral except for the newly added JSRegress ftl-object-mul
test which shows a 2.16x speed up on x86_64 FTL, 1.27x speed up on x86_64 DFG,
and 1.56x on x86 DFG.

The speed up comes not from the mul operator itself, but from the fact that the
polymorphic operand types support now allow the test function to run without OSR
exiting, thereby realizing the DFG and FTL's speed up on other work that the test
function does.

This patch has passed the layout tests on x86_64 with a debug build.
It passed the JSC tests with x86 and x86_64 debug builds.

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGClobberize.h:

(JSC::DFG::clobberize):

  • dfg/DFGFixupPhase.cpp:

(JSC::DFG::FixupPhase::fixupNode):

  • dfg/DFGOperations.cpp:
  • dfg/DFGOperations.h:
  • dfg/DFGPredictionPropagationPhase.cpp:

(JSC::DFG::PredictionPropagationPhase::propagate):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileArithMul):

  • ftl/FTLCompile.cpp:
  • Changed to call generateBinaryOpFastPath() instead now, and let it dispatch to the appropriate snippet generator.
  • ftl/FTLCompileBinaryOp.cpp:

(JSC::FTL::generateBinaryArithOpFastPath):
(JSC::FTL::generateBinaryOpFastPath):
(JSC::FTL::generateArithSubFastPath): Deleted.
(JSC::FTL::generateValueAddFastPath): Deleted.

  • Refactored these functions to eliminate the need for copy-pasting every time we add support for another binary arithmetic snippet.
  • ftl/FTLCompileBinaryOp.h:
  • ftl/FTLInlineCacheDescriptor.h:
  • ftl/FTLInlineCacheDescriptorInlines.h:

(JSC::FTL::ArithMulDescriptor::ArithMulDescriptor):
(JSC::FTL::ArithMulDescriptor::icSize):

  • ftl/FTLInlineCacheSize.cpp:

(JSC::FTL::sizeOfArithMul):

  • ftl/FTLInlineCacheSize.h:
  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::lower):
(JSC::FTL::DFG::LowerDFGToLLVM::compileArithMul):

  • jit/JITMulGenerator.h:

(JSC::JITMulGenerator::JITMulGenerator):

  • tests/stress/op_mul.js:
  • Updated a test value: the interesting value for imminent overflow from an int32 is 0x7fffffff, not 0x7ffffff.

LayoutTests:

  • js/regress/ftl-object-mul-expected.txt: Added.
  • js/regress/ftl-object-mul.html: Added.
  • js/regress/script-tests/ftl-object-mul.js: Added.

(o1.valueOf):
(foo):

8:08 PM Changeset in webkit [192992] by mmaxfield@apple.com
  • 31 edits
    2 adds in trunk

Unify font-variant-* with font-variant shorthand
https://bugs.webkit.org/show_bug.cgi?id=149773

Reviewed by Darin Adler.

Source/WebCore:

This patch makes font-variant a shorthand for the following properties:
font-variant-ligatures
font-variant-position
font-variant-caps
font-variant-numeric
font-variant-alternates
font-variant-east-asian

This is consistent with the CSS Fonts Level 3 spec.

This patch also migrates the "font" longhand to use the font-variant-caps
property.

Test: fast/text/font-variant-shorthand.html

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::fontVariantEastAsianPropertyValue): Rename FontVariantEastAsian values.
(WebCore::fontVariantFromStyle): We must consult with the longhand properties to determine
font-variant computed style.
(WebCore::ComputedStyleExtractor::propertyValue): Don't put any-old font-variant-caps inside
the font shorthand.

  • css/CSSFontSelector.cpp:

(WebCore::CSSFontSelector::addFontFaceRule): Guard against incorrect downcasts (due to inherit
of the new shorthand property).

  • css/CSSParser.cpp: Parse font-variant as a shorthand. Also implement its "normal" and "none" values.

(WebCore::CSSParser::parseValue):
(WebCore::CSSParser::parseFont):
(WebCore::CSSParser::parseSystemFont):
(WebCore::CSSParser::parseFontVariantLigatures):
(WebCore::CSSParser::parseFontVariantNumeric):
(WebCore::CSSParser::parseFontVariantEastAsian):
(WebCore::CSSParser::parseFontVariant):
(WebCore::isValidKeywordPropertyAndValue): Deleted.
(WebCore::isKeywordPropertyID): Deleted.

  • css/CSSParser.h:
  • css/CSSPropertyNames.in: Turn font-variant into a shorthand property.
  • css/FontVariantBuilder.h: Guard against incorrect downcasts. Also update for renamed

FontVariantEastAsian type.
(WebCore::applyValueFontVariantLigatures):
(WebCore::applyValueFontVariantNumeric):
(WebCore::applyValueFontVariantEastAsian):

  • css/StyleProperties.cpp: Update to use the more specific property.

(WebCore::StyleProperties::appendFontLonghandValueIfExplicit):
(WebCore::StyleProperties::fontValue):
(WebCore::StyleProperties::asText):

  • css/StyleResolver.cpp: Ditto.

(WebCore::StyleResolver::isValidCueStyleProperty):

  • editing/EditingStyle.cpp: Ditto.
  • editing/cocoa/HTMLConverter.mm: Ditto.

(HTMLConverterCaches::propertyValueForNode):
(HTMLConverter::computedAttributesForElement):

  • editing/ios/EditorIOS.mm: Ditto.

(WebCore::Editor::removeUnchangeableStyles):

  • html/canvas/CanvasRenderingContext2D.cpp: Ditto.

(WebCore::CanvasRenderingContext2D::font):
(WebCore::CanvasRenderingContext2D::setFont):

  • platform/graphics/FontCache.h: Removing duplicate cache key value.

(WebCore::FontDescriptionKey::makeFlagsKey):

  • platform/graphics/FontCascade.cpp: Migrate to the new font-variant-caps from the old member variable.

(WebCore::FontCascade::glyphDataForCharacter):

  • platform/graphics/FontCascade.h: Ditto.

(WebCore::FontCascade::isSmallCaps):

  • platform/graphics/FontDescription.cpp: Ditto.

(WebCore::FontDescription::FontDescription):

  • platform/graphics/FontDescription.h: Ditto.

(WebCore::FontCascadeDescription::equalForTextAutoSizing):
(WebCore::FontDescription::smallCaps): Deleted.
(WebCore::FontDescription::setSmallCaps): Deleted.
(WebCore::FontDescription::setIsSmallCaps): Deleted.
(WebCore::FontDescription::operator==): Deleted.

  • platform/graphics/cocoa/FontCacheCoreText.cpp: Rename FontVariantEastAsianWidth.

(WebCore::computeFeatureSettingsFromVariants):

  • platform/text/TextFlags.h: Ditto.

(WebCore::FontVariantSettings::operator==):

  • rendering/RenderText.cpp: Migrage to the new font-variant-caps from the old member variable.

(WebCore::RenderText::widthFromCache):

LayoutTests:

Update tests. Also temporarily skip existing font-features tests until
https://bugs.webkit.org/show_bug.cgi?id=149774 is fixed.

  • css3/font-variant-parsing-expected.txt:
  • css3/font-variant-parsing.html:
  • fast/css/font-property-priority-expected.txt:
  • fast/css/font-shorthand-expected.txt:
  • fast/css/parsing-font-variant-ligatures-expected.txt:
  • fast/css/parsing-font-variant-ligatures.html:
  • fast/inspector-support/style-expected.txt:
  • fast/text/font-variant-shorthand-expected.txt: Added.
  • fast/text/font-variant-shorthand.html: Added.
  • platform/mac/TestExpectations:
  • platform/mac/fast/writing-mode/broken-ideograph-small-caps-expected.txt:
8:05 PM Changeset in webkit [192991] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION(r192753): Remote Web Inspector: Applications and Debuggables not showing up in debuggers
https://bugs.webkit.org/show_bug.cgi?id=151787

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2015-12-02
Reviewed by Brian Burg.

  • inspector/remote/RemoteInspector.mm:

(Inspector::RemoteInspector::receivedIndicateMessage):
Removed lock that was unnecessarily added in r192753. It was
protecting nothing.

7:44 PM Changeset in webkit [192990] by Yusuke Suzuki
  • 2 edits in trunk/Tools

Allow nil for unspecified benchmark pathes
https://bugs.webkit.org/show_bug.cgi?id=151784

Reviewed by Filip Pizlo.

Pathname.new(nil) will raise an error.
Only generate Pathname if the benchmark path is specified.

  • Scripts/run-jsc-benchmarks:
7:29 PM Changeset in webkit [192989] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

Reduce size of ScriptElement
https://bugs.webkit.org/show_bug.cgi?id=151786

Patch by Alex Christensen <achristensen@webkit.org> on 2015-12-02
Reviewed by Andreas Kling.

  • dom/ScriptElement.cpp:

(WebCore::ScriptElement::ScriptElement):
(WebCore::ScriptElement::requestScript):

  • dom/ScriptElement.h:

Use callOnMainThread instead of a Timer to save memory on a timer that is rarely used.
Use bit fields for the boolean values to save another 8 bytes per ScriptElement.
This reduces sizeof(ScriptElement) from 168 to 48 bytes.

7:17 PM Changeset in webkit [192988] by sbarati@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Insert a FIXME comment FTLLazySlowPath.h to remind us to remove/refactor the ScratchRegisterAllocator field.

Rubber-stamped by Filip Pizlo.

  • ftl/FTLLazySlowPath.h:
6:00 PM Changeset in webkit [192987] by benjamin@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Remove insertElement() from FTLB3Output
https://bugs.webkit.org/show_bug.cgi?id=151781

Reviewed by Sam Weinig.

  • ftl/FTLB3Output.h:

(JSC::FTL::Output::insertElement): Deleted.
That's a LLVM concept.

5:46 PM Changeset in webkit [192986] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Rebaselining fast/dom/adopt-attribute-crash-expected for win
https://bugs.webkit.org/show_bug.cgi?id=151762

Reviewed by Darin Adler.

  • platform/win/fast/dom/adopt-attribute-crash-expected.txt:
4:32 PM Changeset in webkit [192985] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Remove stuffs related to alloca from FTLB3Output
https://bugs.webkit.org/show_bug.cgi?id=151780

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-02
Reviewed by Mark Lam.

We can use the Phis directly with B3 :)

  • ftl/FTLB3Output.h:

(JSC::FTL::Output::alloca): Deleted.
(JSC::FTL::Output::get): Deleted.
(JSC::FTL::Output::set): Deleted.

4:21 PM Changeset in webkit [192984] by benjamin@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Add sin(), cos(), pow() and log() to B3
https://bugs.webkit.org/show_bug.cgi?id=151778

Reviewed by Geoffrey Garen.

  • ftl/FTLB3Output.h:

(JSC::FTL::Output::doubleSin):
(JSC::FTL::Output::doubleCos):
(JSC::FTL::Output::doublePow):
(JSC::FTL::Output::doubleLog):
(JSC::FTL::Output::callWithoutSideEffects):

3:55 PM Changeset in webkit [192983] by commit-queue@webkit.org
  • 8 edits
    3 adds in trunk

Asynchronously call onerror when a content blocker blocks ascript element's load
https://bugs.webkit.org/show_bug.cgi?id=151649

Patch by Alex Christensen <achristensen@webkit.org> on 2015-12-02
Reviewed by Brady Eidson.

Source/WebCore:

Test: http/tests/contentextensions/script-onerror.html

  • dom/ScriptElement.cpp:

(WebCore::ScriptElement::ScriptElement):
(WebCore::ScriptElement::requestScript):

  • dom/ScriptElement.h:

LayoutTests:

  • http/tests/contentextensions/script-onerror-expected.txt: Added.
  • http/tests/contentextensions/script-onerror.html: Added.
  • http/tests/contentextensions/script-onerror.html.json: Added.
  • http/tests/misc/unloadable-script-expected.txt:
  • http/tests/misc/unloadable-script.html:
  • http/tests/security/local-JavaScript-from-remote-expected.txt:
  • http/tests/security/local-JavaScript-from-remote.html:

Added testRunner.waitUntilDone and testRunner.notifyDone to reflect the fact that onerror is no longer called synchronously.

3:51 PM Changeset in webkit [192982] by achristensen@apple.com
  • 5 edits in trunk/Source/WebKit2

Fix authentication requests with NetworkSession and canHandleHTTPSServerTrustEvaluation true
https://bugs.webkit.org/show_bug.cgi?id=151775
rdar://problem/23586265

Reviewed by Chris Dumez.

In https://bugs.webkit.org/show_bug.cgi?id=150968 I copied functionality from
NetworkLoad::canAuthenticateAgainstProtectionSpaceAsync into NetworkLoad::didReceiveChallenge
but I overlooked the call to m_client.canAuthenticateAgainstProtectionSpaceAsync which is needed
if canHandleHTTPSServerTrustEvaluation is true. This adds that call and moves what should happen
after that to NetworkLoad::continueCanAuthenticateAgainstProtectionSpace.

  • NetworkProcess/NetworkLoad.cpp:

(WebKit::NetworkLoad::didReceiveChallenge):
(WebKit::NetworkLoad::didReceiveResponse):
(WebKit::NetworkLoad::continueCanAuthenticateAgainstProtectionSpace):

  • NetworkProcess/NetworkLoad.h:
  • NetworkProcess/NetworkSession.h:
  • Shared/Authentication/AuthenticationManager.h:
3:41 PM Changeset in webkit [192981] by fpizlo@apple.com
  • 5 edits in trunk/Source/JavaScriptCore

Add a few obvious strength-reductions to Air
https://bugs.webkit.org/show_bug.cgi?id=151777

Reviewed by Mark Lam.

The absence of these optimizations was obnoxious.

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::add32): lea 1(reg), reg -> add 1, reg.

  • b3/air/AirGenerate.cpp:

(JSC::B3::Air::generate): Emit simpler prologue/epilogue if !frameSize.

  • b3/air/AirOpcode.opcodes: We have matching for BranchMul32 with immediate, but we forgot to add the instruction form.
  • jit/AssemblyHelpers.h: Support for the prologue/epilogue optimizations.

(JSC::AssemblyHelpers::emitFunctionPrologue):
(JSC::AssemblyHelpers::emitFunctionEpilogueWithEmptyFrame):
(JSC::AssemblyHelpers::emitFunctionEpilogue):

3:04 PM Changeset in webkit [192980] by eric.carlson@apple.com
  • 2 edits in trunk/LayoutTests

Fix flaky test added with r192954.

Unreviewed.

  • fast/mediastream/MediaStreamTrack-getSettings.html:
3:04 PM Changeset in webkit [192979] by matthew_hanson@apple.com
  • 8 edits
    3 adds in branches/safari-601.1.46-branch

Merge r192432. rdar://problem/23558672

3:04 PM Changeset in webkit [192978] by matthew_hanson@apple.com
  • 4 edits in branches/safari-601.1.46-branch/Source/WebCore

Merge r192259. rdar://problem/23189749

3:04 PM Changeset in webkit [192977] by matthew_hanson@apple.com
  • 2 edits in branches/safari-601.1.46-branch/Source/WebCore

Merge r192368. rdar://problem/23189763

3:04 PM Changeset in webkit [192976] by matthew_hanson@apple.com
  • 3 edits
    2 adds in branches/safari-601.1.46-branch

Merge r192169. rdar://problem/23189763

3:04 PM Changeset in webkit [192975] by matthew_hanson@apple.com
  • 5 edits
    2 adds in branches/safari-601.1.46-branch

Merge r190383. rdar://problem/23432383

3:04 PM Changeset in webkit [192974] by matthew_hanson@apple.com
  • 10 edits in branches/safari-601.1.46-branch

Merge r188194. rdar://problem/23432383

3:04 PM Changeset in webkit [192973] by matthew_hanson@apple.com
  • 3 edits in branches/safari-601.1.46-branch/Source/WebCore

Merge r189427. rdar://problem/23432383

3:04 PM Changeset in webkit [192972] by matthew_hanson@apple.com
  • 7 edits in branches/safari-601.1.46-branch/Source

Merge r187544. rdar://problem/23395970

3:01 PM Changeset in webkit [192971] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

[iOS] Abrupt transition between Fullscreen -> PiP
https://bugs.webkit.org/show_bug.cgi?id=151719

Reviewed by Eric Carlson.

Follow-up to r192922: When moving from inline -> PiP, don't forget to hide the fullscreen
window once the PiP transition completes.

  • platform/ios/WebVideoFullscreenInterfaceAVKit.mm:

(WebVideoFullscreenInterfaceAVKit::didStartPictureInPicture):

2:52 PM Changeset in webkit [192970] by commit-queue@webkit.org
  • 68 edits
    3 deletes in trunk

Unreviewed, rolling out r192955.
https://bugs.webkit.org/show_bug.cgi?id=151776

A large number of the tests added with this change are failing
on Windows (Requested by ryanhaddad on #webkit).

Reverted changeset:

"[css border] border-image doesn't honor border-style"
https://bugs.webkit.org/show_bug.cgi?id=99922
http://trac.webkit.org/changeset/192955

2:41 PM Changeset in webkit [192969] by yoav@yoav.ws
  • 3 edits
    2 adds in trunk

Fix preloader issue with srcdoc documents.
https://bugs.webkit.org/show_bug.cgi?id=151744

Reviewed by Ryosuke Niwa.

Source/WebCore:

Make sure that PreloadRequest is resolving URLs based on the document's
baseURL() rather than using url() as the base URL, which is not how URLs
are resolved by the parser, and fails when document->url() diverges from
the document's base URL (e.g. in the case of srcdoc based documents).

Test: fast/preloader/iframe-srcdoc.html

  • html/parser/HTMLResourcePreloader.cpp:

(WebCore::PreloadRequest::completeURL):

LayoutTests:

Added a test that makes sure that srcdoc based subresources are properly preloaded.

  • fast/preloader/iframe-srcdoc-expected.txt: Added.
  • fast/preloader/iframe-srcdoc.html: Added.
2:35 PM Changeset in webkit [192968] by benjamin@webkit.org
  • 4 edits in trunk/Source/JavaScriptCore

Update the interface added in r192967

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-02

  • b3/B3CCallValue.h:

Filip prefers explicit effects.

  • b3/testb3.cpp:

(JSC::B3::testCallSimplePure):

2:12 PM Changeset in webkit [192967] by benjamin@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Add a function attribute for Pure functions in B3
https://bugs.webkit.org/show_bug.cgi?id=151741

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-02
Reviewed by Geoffrey Garen.

We have plenty of functions without side effects
when lowering DFG.
This patch adds the "PureCall" flag to B3's CCall
to make sure those functions do not prevent optimizations.

  • b3/B3CCallValue.h:
  • b3/testb3.cpp:

(JSC::B3::testCallSimplePure):
(JSC::B3::run):

2:09 PM Changeset in webkit [192966] by jer.noble@apple.com
  • 22 edits
    2 adds in trunk

Add a setting and restriction which will pause invisible autoplaying video
https://bugs.webkit.org/show_bug.cgi?id=151412

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/video-restricted-invisible-autoplay-not-allowed.html

Drive-by fix: m_autoplaying is reset in many places by calling pause() or play(), where those
calls did not originate from an explicit request to pause or play, e.g., during an interruption.
This causes m_autoplaying to be set to false, thus breaking resumption of autoplaying when the
interruption ends. Update PlatformMediaSession to remember its client's "autoplaying" state and
restore it when an interruption ends.

Add a means to register for viewport visibility notifications to FrameView, RenderView,
and RenderElement. Elements who wish to recieve these notifications must do so through their
renderer, and thus will have to re-register whenever a new renderer is attached.

Add a restriction to HTMLMediaElement which will pause autoplaying video when that video scrolls
out of the viewport, or is hidden with CSS.

Add a setting which controls whether that new restriction is set.

  • dom/Element.h:

(WebCore::Element::isVisibleInViewportChanged): Add default empty virtual method.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::HTMLMediaElement):
(WebCore::HTMLMediaElement::didMoveToNewDocument):
(WebCore::HTMLMediaElement::documentDidResumeFromPageCache):
(WebCore::HTMLMediaElement::removeBehaviorsRestrictionsAfterFirstUserGesture):
(WebCore::HTMLMediaElement::resumeAutoplaying):
(WebCore::mediaElementIsAllowedToAutoplay):
(WebCore::HTMLMediaElement::isVisibleInViewportChanged):
(WebCore::HTMLMediaElement::updateShouldAutoplay):
(WebCore::HTMLMediaElement::HTMLMediaElement): Set the new restriction based on the current Settings.
(WebCore::HTMLMediaElement::resumeAutoplaying): Continue autoplay, or begin playback.
(WebCore::HTMLMediaElement::didMoveToNewDocument): Update our autoplay state.
(WebCore::HTMLMediaElement::documentDidResumeFromPageCache): Ditto.
(WebCore::HTMLMediaElement::removedFrom): Ditto.
(WebCore::HTMLMediaElement::didAttachRenderers): Ditto.
(WebCore::HTMLMediaElement::didDetachRenderers): Ditto.
(WebCore::HTMLMediaElement::visibilityDidChange): Ditto.
(WebCore::HTMLMediaElement::willDetachRenderers): Unregister for visibility callbacks.
(WebCore::HTMLMediaElement::removeBehaviorsRestrictionsAfterFirstUserGesture): Clear new restriction.
(WebCore::mediaElementIsAllowedToAutoplay): Check for autoplay requirements.
(WebCore::HTMLMediaElement::isVisibleInViewportChanged): Added, update our autoplay state.
(WebCore::HTMLMediaElement::updateShouldAutoplay): Set interruption if necessary, clear otherwise.

  • html/HTMLMediaElement.h:
  • html/MediaElementSession.cpp:

(WebCore::restrictionName): Added support for new restriction.

  • html/MediaElementSession.h:
  • page/FrameView.cpp:

(WebCore::FrameView::viewportContentsChanged): Update clients of viewport visibility.

  • page/Settings.in:
  • platform/audio/PlatformMediaSession.cpp:

(WebCore::stateName): Add new "Autoplay" state.
(WebCore::interruptionName): Added new interruption type.
(WebCore::PlatformMediaSession::beginInterruption): Set the m_interruptionType.
(WebCore::PlatformMediaSession::clientWillBeginAutoplaying): Set the m_state to Autoplaying.

  • platform/audio/PlatformMediaSession.h:

(WebCore::PlatformMediaSession::interruptionType): Added getter.
(WebCore::PlatformMediaSessionClient::resumeAutoplaying): Added default.

  • platform/audio/PlatformMediaSessionManager.cpp:

(WebCore::PlatformMediaSessionManager::sessionWillBeginPlayback): Only pause session if its state is playing.

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::RenderElement): Set new ivars.
(WebCore::RenderElement::~RenderElement): Unregister for callbacks if necessary.
(WebCore::RenderElement::registerForVisibleInViewportCallback): Register for callbacks from RenderView.
(WebCore::RenderElement::unregisterForVisibleInViewportCallback): Unregister from same.
(WebCore::RenderElement::visibleInViewportStateChanged): Notify Element if value has changed.

  • rendering/RenderElement.h:
  • rendering/RenderView.cpp:

(WebCore::RenderView::registerForVisibleInViewportCallback): Add renderer to list of callbacks.
(WebCore::RenderView::unregisterForVisibleInViewportCallback): Remove renderer from same.
(WebCore::RenderView::updateVisibleViewportRect): Walk renderers setting their visiblility based on the viewport visible rect.

  • rendering/RenderView.h:
  • testing/Internals.cpp:

(WebCore::Internals::setMediaElementRestrictions): Support new restriction.

LayoutTests:

  • media/video-restricted-invisible-autoplay-not-allowed-expected.txt: Added.
  • media/video-restricted-invisible-autoplay-not-allowed.html: Added.
2:09 PM Changeset in webkit [192965] by rniwa@webkit.org
  • 2 edits in trunk/Websites/perf.webkit.org

Perf dashboard should avoid overflow during geometric mean computation
https://bugs.webkit.org/show_bug.cgi?id=151773

Reviewed by Chris Dumez.

  • public/include/report-processor.php:
2:04 PM Changeset in webkit [192964] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

Rebaseline fast/parser/xml-declaration-missing-ending-mark.html, fast/parser/xml-colon-entity.html for Win
https://bugs.webkit.org/show_bug.cgi?id=151763

Reviewed by Brent Fulgham.

  • platform/win/fast/parser/xml-colon-entity-expected.txt:
  • platform/win/fast/parser/xml-declaration-missing-ending-mark-expected.txt:
1:47 PM Changeset in webkit [192963] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

Rebaseline fast/dynamic/text-combine.html on win
https://bugs.webkit.org/show_bug.cgi?id=151761

Unreviewed test gardening.

  • platform/win/fast/dynamic/text-combine-expected.png:
  • platform/win/fast/dynamic/text-combine-expected.txt:
1:41 PM Changeset in webkit [192962] by Ryan Haddad
  • 2 edits in trunk/LayoutTests/imported/w3c

Rebaseline imported/w3c/web-platform-tests/html/dom/interfaces.html after r192953
https://bugs.webkit.org/show_bug.cgi?id=116963

Unreviewed test gardening.

  • web-platform-tests/html/dom/interfaces-expected.txt:
1:37 PM Changeset in webkit [192961] by bshafiei@apple.com
  • 5 edits in branches/safari-601-branch/Source

Versioning.

1:33 PM Changeset in webkit [192960] by beidson@apple.com
  • 10 edits
    3 deletes in trunk/LayoutTests

Modern IDB: Remove all traces of IDBObjectStore::openKeyCursor from tests.
https://bugs.webkit.org/show_bug.cgi?id=151772

Reviewed by Alex Christensen.

IDBObjectStore::openKeyCursor no longer exists, so testing it is inherently bogus.

  • platform/mac-wk1/TestExpectations: Two tests now pass with small expectations changes.
  • storage/indexeddb/cursor-basics-expected.txt:
  • storage/indexeddb/cursor-overloads-expected.txt:
  • storage/indexeddb/cursor-overloads.html:
  • storage/indexeddb/optional-arguments.html:
  • storage/indexeddb/resources/cursor-basics.js:
  • storage/indexeddb/resources/deleted-objects.js:
  • storage/indexeddb/resources/exceptions.js:
  • storage/indexeddb/resources/objectstore-basics.js:
  • storage/indexeddb/objectstore-keycursor-expected.txt: Removed.
  • storage/indexeddb/objectstore-keycursor.html: Removed.
  • storage/indexeddb/resources/objectstore-keycursor.js: Removed.
12:57 PM Changeset in webkit [192959] by hyatt@apple.com
  • 1 edit
    4 adds in trunk/LayoutTests

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.

Add some more picture element layout tests
https://bugs.webkit.org/show_bug.cgi?id=151769

Reviewed by Dean Jackson.

  • fast/picture/image-picture-invalid-expected.txt: Added.
  • fast/picture/image-picture-invalid.html: Added.
  • fast/picture/image-picture-nested-expected.txt: Added.
  • fast/picture/image-picture-nested.html: Added.
12:53 PM Changeset in webkit [192958] by beidson@apple.com
  • 3 edits in trunk/LayoutTests

Modern IDB: Enable a couple more passing tests.
https://bugs.webkit.org/show_bug.cgi?id=151766

Reviewed by Beth Dakin.

  • platform/mac-wk1/TestExpectations:
  • storage/indexeddb/create-object-store-options-expected.txt:
12:50 PM Changeset in webkit [192957] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Skipping tests on Win that fail due to unimplemented showModalDialog function.
https://bugs.webkit.org/show_bug.cgi?id=151506

Unreviewed test gardening.

  • platform/win/TestExpectations:
12:32 PM Changeset in webkit [192956] by beidson@apple.com
  • 12 edits in trunk

Modern IDB: IDBTransaction::error is not exposed.
https://bugs.webkit.org/show_bug.cgi?id=151752

Reviewed by Alex Christensen.

Source/WebCore:

No new tests (At least 3 failing tests now pass, plus changes to other faulty tests).

  • Modules/indexeddb/client/IDBRequestImpl.cpp:

(WebCore::IDBClient::IDBRequest::dispatchEvent):
(WebCore::IDBClient::IDBRequest::uncaughtExceptionInEventHandler):

  • Modules/indexeddb/client/IDBRequestImpl.h:
  • Modules/indexeddb/client/IDBTransactionImpl.cpp:

(WebCore::IDBClient::IDBTransaction::error):
(WebCore::IDBClient::IDBTransaction::abortDueToFailedRequest):
(WebCore::IDBClient::IDBTransaction::abort):
(WebCore::IDBClient::IDBTransaction::didCreateIndexOnServer):

  • Modules/indexeddb/client/IDBTransactionImpl.h:

LayoutTests:

  • platform/mac-wk1/TestExpectations:
  • storage/indexeddb/modern/basic-add.html:
  • storage/indexeddb/modern/double-abort-expected.txt:
  • storage/indexeddb/modern/index-3.html:
  • storage/indexeddb/resources/transaction-error.js:
  • storage/indexeddb/transaction-error-expected.txt:
12:25 PM Changeset in webkit [192955] by cavalcantii@gmail.com
  • 68 edits
    3 adds in trunk

[css border] border-image doesn't honor border-style
https://bugs.webkit.org/show_bug.cgi?id=99922

Reviewed by Simon Fraser.

Source/WebCore:

Ensure that WebKit will be compliant to css-backgrounds spec where a
border with an image will only be rendered if there is a style defined.

Quote: "None: No border. Color and width are ignored (i.e., the border has width 0)".
Reference: http://www.w3.org/TR/css3-background/#border-style

From W3C discussion: "The fact that these properties set the style of the border is
normative". Reference: https://lists.w3.org/Archives/Public/www-style/2015Nov/0260.html

Test: fast/borders/border-image-should-not-display.html

  • rendering/style/BorderData.h:

(WebCore::BorderData::hasBorder):
(WebCore::BorderData::borderLeftWidth):
(WebCore::BorderData::borderRightWidth):
(WebCore::BorderData::borderTopWidth):
(WebCore::BorderData::borderBottomWidth):

  • rendering/style/BorderValue.h:

(WebCore::BorderValue::nonZero):
(WebCore::BorderValue::isVisible):

LayoutTests:

Ensure that WebKit will be compliant to css-backgrounds spec where
a border with an image will only be rendered if there is a style defined.

Previous border image tests had to be edited (i.e. define border-style)
to ensure that a decorated border would be rendered.

  • fast/borders/border-image-01.html:
  • fast/borders/border-image-border-radius.html:
  • fast/borders/border-image-fill-no-intrinsic-size.html:
  • fast/borders/border-image-longhand.html:
  • fast/borders/border-image-massive-scale.html:
  • fast/borders/border-image-omit-right-slice.html:
  • fast/borders/border-image-outset-in-shorthand.html:
  • fast/borders/border-image-outset-split-inline-expected.txt:
  • fast/borders/border-image-outset-split-inline-vertical-lr-expected.txt:
  • fast/borders/border-image-outset-split-inline-vertical-lr.html:
  • fast/borders/border-image-outset-split-inline.html:
  • fast/borders/border-image-outset.html:
  • fast/borders/border-image-repeat.html:
  • fast/borders/border-image-rotate-transform.html:
  • fast/borders/border-image-scale-transform.html:
  • fast/borders/border-image-scaled.html:
  • fast/borders/border-image-scrambled.html:
  • fast/borders/border-image-should-not-display-expected.html: Added.
  • fast/borders/border-image-should-not-display.html: Added.
  • fast/borders/border-image-side-reduction.html:
  • fast/borders/border-image-slice-constrained.html:
  • fast/borders/border-image-slice-missing-right.html:
  • fast/borders/border-image-slices.html:
  • fast/borders/border-image-source.html:
  • fast/borders/border-image-trumps-radius-expected.txt:
  • fast/borders/border-image-trumps-radius.html:
  • fast/borders/hidpi-border-image-gradient-on-subpixels.html:
  • fast/borders/resources/red.png: Added.
  • fast/borders/scaled-border-image.html:
  • fast/gradients/border-image-gradient-expected.txt:
  • fast/gradients/border-image-gradient.html:
  • fast/hidpi/image-set-border-image-comparison.html:
  • fast/hidpi/image-set-border-image-dynamic.html:
  • fast/hidpi/image-set-border-image-simple.html:
  • fast/writing-mode/border-image-horizontal-bt.html:
  • fast/writing-mode/border-image-vertical-lr.html:
  • fast/writing-mode/border-image-vertical-rl.html:
  • platform/mac/fast/borders/border-image-01-expected.txt:
  • platform/mac/fast/borders/border-image-border-radius-expected.txt:
  • platform/mac/fast/borders/border-image-longhand-expected.txt:
  • platform/mac/fast/borders/border-image-massive-scale-expected.txt:
  • platform/mac/fast/borders/border-image-omit-right-slice-expected.txt:
  • platform/mac/fast/borders/border-image-outset-expected.txt:
  • platform/mac/fast/borders/border-image-outset-in-shorthand-expected.txt:
  • platform/mac/fast/borders/border-image-repeat-expected.txt:
  • platform/mac/fast/borders/border-image-rotate-transform-expected.txt:
  • platform/mac/fast/borders/border-image-scale-transform-expected.txt:
  • platform/mac/fast/borders/border-image-scaled-expected.txt:
  • platform/mac/fast/borders/border-image-scrambled-expected.txt:
  • platform/mac/fast/borders/border-image-side-reduction-expected.txt:
  • platform/mac/fast/borders/border-image-slice-constrained-expected.txt:
  • platform/mac/fast/borders/border-image-slices-expected.txt:
  • platform/mac/fast/borders/border-image-source-expected.txt:
  • platform/mac/fast/borders/scaled-border-image-expected.txt:
  • platform/mac/fast/hidpi/image-set-border-image-comparison-expected.txt:
  • platform/mac/fast/hidpi/image-set-border-image-dynamic-expected.txt:
  • platform/mac/fast/hidpi/image-set-border-image-simple-expected.txt:
  • platform/mac/fast/writing-mode/border-image-horizontal-bt-expected.txt:
  • platform/mac/fast/writing-mode/border-image-vertical-lr-expected.txt:
  • platform/mac/fast/writing-mode/border-image-vertical-rl-expected.txt:
12:20 PM Changeset in webkit [192954] by eric.carlson@apple.com
  • 43 edits
    4 moves
    3 adds
    2 deletes in trunk

[MediaStream] Implement MediaStreamTrack.getSettings()
https://bugs.webkit.org/show_bug.cgi?id=151727

Reviewed by Jer Noble.

Source/WebCore:

MediaStreamTrack.getStates has been replaced by MediaStreamTrack.getSettings.

Test: fast/mediastream/MediaStreamTrack-getSettings.html

  • CMakeLists.txt: MediaSourceStates.* -> MediaSourceSettings.*.
  • DerivedSources.make: No more MediaSourceStates.idl.
  • Modules/mediastream/CapabilityRange.cpp: MediaSourceStates.* -> MediaSourceSettings.*.
  • Modules/mediastream/MediaSourceSettings.cpp: Copied from Source/WebCore/Modules/mediastream/MediaSourceStates.cpp.

(WebCore::MediaSourceSettings::create):
(WebCore::MediaSourceSettings::MediaSourceSettings):
(WebCore::MediaSourceSettings::facingMode):
(WebCore::MediaSourceStates::create): Deleted.
(WebCore::MediaSourceStates::MediaSourceStates): Deleted.
(WebCore::MediaSourceStates::sourceType): Deleted.
(WebCore::MediaSourceStates::facingMode): Deleted.

  • Modules/mediastream/MediaSourceSettings.h: Copied from Source/WebCore/Modules/mediastream/MediaSourceStates.h.

MediaSourceStates.* renamed to MediaSourceSettings.* and updated to new API.

  • Modules/mediastream/MediaSourceStates.cpp: Removed.
  • Modules/mediastream/MediaSourceStates.h: Removed.
  • Modules/mediastream/MediaSourceStates.idl: Removed.
  • Modules/mediastream/MediaStreamCapabilities.cpp:

(WebCore::MediaStreamCapabilities::sourceType): Return an empty vector for now, will be fixed

by the changes for https://bugs.webkit.org/show_bug.cgi?id=151728.

(WebCore::MediaStreamCapabilities::sourceId): RealtimeMediaSourceStates -> MediaSourceSettings.
(WebCore::MediaStreamCapabilities::facingMode): Ditto.

  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::getSettings): New.
(WebCore::MediaStreamTrack::getCapabilities): Don't modify states, just pass through whatever

private track returns.

(WebCore::MediaStreamTrack::trackSettingsChanged):
(WebCore::MediaStreamTrack::states): Deleted.
(WebCore::MediaStreamTrack::trackStatesChanged): Deleted.

  • Modules/mediastream/MediaStreamTrack.h:
  • Modules/mediastream/MediaStreamTrack.idl: MediaSourceStates -> MediaSourceSettings.
  • Modules/webaudio/MediaStreamAudioSource.cpp:

(WebCore::MediaStreamAudioSource::settings):
(WebCore::MediaStreamAudioSource::states): Deleted.

  • Modules/webaudio/MediaStreamAudioSource.h: MediaSourceStates -> MediaSourceSettings.
  • WebCore.xcodeproj/project.pbxproj: MediaSourceStates.* -> MediaSourceSettings.*.
  • bindings/js/JSMediaSourceStatesCustom.cpp: Removed.
  • bindings/js/JSMediaStreamTrackCustom.cpp: Added.

(WebCore::JSMediaStreamTrack::getSettings): MediaSourceSettings is a generic dictionary so

it has to be generated manually.

  • platform/mediastream/MediaStreamPrivate.cpp:

(WebCore::MediaStreamPrivate::intrinsicSize): states -> settings.
(WebCore::MediaStreamPrivate::trackStatesChanged): Deleted.

  • platform/mediastream/MediaStreamPrivate.h:
  • platform/mediastream/MediaStreamTrackPrivate.cpp:

(WebCore::MediaStreamTrackPrivate::settings):
(WebCore::MediaStreamTrackPrivate::sourceSettingsChanged):
(WebCore::MediaStreamTrackPrivate::states): Deleted.
(WebCore::MediaStreamTrackPrivate::sourceStatesChanged): Deleted.

  • platform/mediastream/MediaStreamTrackPrivate.h:
  • platform/mediastream/RealtimeMediaSource.cpp:

(WebCore::RealtimeMediaSource::settingsDidChanged):
(WebCore::RealtimeMediaSource::statesDidChanged): Deleted.

  • platform/mediastream/RealtimeMediaSource.h:
  • platform/mediastream/RealtimeMediaSourceCapabilities.h:

(WebCore::RealtimeMediaSourceCapabilities::facingModes): States -> Settings.
(WebCore::RealtimeMediaSourceCapabilities::addFacingMode): Ditto.
(WebCore::RealtimeMediaSourceCapabilities::sourceTypes): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::setSourceType): Deleted.
(WebCore::RealtimeMediaSourceCapabilities::addSourceType): Deleted.

  • platform/mediastream/RealtimeMediaSourceCenter.h: States -> Settings.
  • platform/mediastream/RealtimeMediaSourceSettings.cpp: Copied from Source/WebCore/platform/mediastream/RealtimeMediaSourceStates.cpp.

(WebCore::RealtimeMediaSourceSettings::facingMode):
(WebCore::RealtimeMediaSourceStates::facingMode): Deleted.
(WebCore::RealtimeMediaSourceStates::sourceType): Deleted.

  • platform/mediastream/RealtimeMediaSourceSettings.h: Copied from Source/WebCore/platform/mediastream/RealtimeMediaSourceStates.h.
  • platform/mediastream/RealtimeMediaSourceStates.cpp: Removed.
  • platform/mediastream/RealtimeMediaSourceStates.h: Removed.
  • platform/mediastream/mac/AVAudioCaptureSource.h:
  • platform/mediastream/mac/AVAudioCaptureSource.mm:

(WebCore::AVAudioCaptureSource::updateStates): Deleted.

  • platform/mediastream/mac/AVCaptureDeviceManager.h:
  • platform/mediastream/mac/AVCaptureDeviceManager.mm:
  • platform/mediastream/mac/AVMediaCaptureSource.h:
  • platform/mediastream/mac/AVMediaCaptureSource.mm:

(WebCore::AVMediaCaptureSource::states): Deleted.

  • platform/mediastream/mac/AVVideoCaptureSource.h:
  • platform/mediastream/mac/AVVideoCaptureSource.mm:

(WebCore::AVVideoCaptureSource::updateStates): Deleted.

  • platform/mediastream/mac/MockRealtimeVideoSourceMac.mm:
  • platform/mediastream/openwebrtc/RealtimeMediaSourceOwr.h:
  • platform/mock/MockRealtimeAudioSource.cpp:

(WebCore::MockRealtimeAudioSource::initializeSupportedConstraints):
(WebCore::MockRealtimeAudioSource::updateStates): Deleted.

  • platform/mock/MockRealtimeAudioSource.h:
  • platform/mock/MockRealtimeMediaSource.cpp:

(WebCore::MockRealtimeMediaSource::capabilities): Minor cleanup.
(WebCore::MockRealtimeMediaSource::settings):
(WebCore::MockRealtimeMediaSource::supportedConstraints):
(WebCore::MockRealtimeMediaSource::states): Deleted.

  • platform/mock/MockRealtimeMediaSource.h:

(WebCore::MockRealtimeMediaSource::constraints):
(WebCore::MockRealtimeMediaSource::currentStates): Deleted.

  • platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::updateSettings):
(WebCore::MockRealtimeVideoSource::initializeCapabilities):
(WebCore::MockRealtimeVideoSource::initializeSupportedConstraints):
(WebCore::MockRealtimeVideoSource::setFrameRate): states -> settings.
(WebCore::MockRealtimeVideoSource::setSize): Ditto.
(WebCore::MockRealtimeVideoSource::drawAnimation): Ditto.
(WebCore::MockRealtimeVideoSource::drawText): Ditto.
(WebCore::MockRealtimeVideoSource::updateStates): Deleted.
(WebCore::MockRealtimeVideoSource::setFacingMode): Deleted.

  • platform/mock/MockRealtimeVideoSource.h:

LayoutTests:

  • fast/mediastream/MediaStream-video-element-expected.txt:
  • fast/mediastream/MediaStream-video-element-track-stop-expected.txt:
  • fast/mediastream/MediaStream-video-element-track-stop.html:
  • fast/mediastream/MediaStream-video-element.html:
  • fast/mediastream/MediaStreamTrack-getSettings-expected.txt: Added.
  • fast/mediastream/MediaStreamTrack-getSettings.html: Added.
12:13 PM Changeset in webkit [192953] by hyatt@apple.com
  • 20 edits
    10 adds in trunk

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.

Implement the picture element.
https://bugs.webkit.org/show_bug.cgi?id=116963

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/select-an-image-source-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/update-the-source-set-expected.txt:

Source/WebCore:

Added fast/picture tests.

  • WebCore.xcodeproj/project.pbxproj:

Add HTMLPictureElement.* to the project.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
Remove the CURRENT_SRC ifdef.

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
New helper function that checks the <source> elements of a <picture> parent
for the best match.

(WebCore::HTMLImageElement::selectImageSource):
Pull out the process of image selection into its own function so that this can
be called from many places (to ensure that dynamic changes are reflected as elements
get changed, added or removed).

(WebCore::HTMLImageElement::parseAttribute):
Call selectImageSource when attributes change.

(WebCore::HTMLImageElement::insertedInto):
If inserted into a picture element, make sure to update the source.

  • html/HTMLImageElement.h:

(WebCore::HTMLImageElement::currentSrc):
Remove the CURRENT_SRC ifdef.

  • html/HTMLImageElement.idl:

Remove the CURRENT_SRC ifdef.

  • html/HTMLPictureElement.cpp: Added.

(WebCore::HTMLPictureElement::HTMLPictureElement):
(WebCore::HTMLPictureElement::create):
(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLPictureElement.h: Added.

The new picture element. Has a sourcesChanged() function that is invoked whenever anything
about the <source> elements changes.

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedInto):
(WebCore::HTMLSourceElement::removedFrom):
(WebCore::HTMLSourceElement::parseAttribute):
Make sure to call sourcesChanged when new sources come and go or when attributes on
source elements change.

  • html/HTMLSourceElement.h:

Added parseAttribute function so we can see when attributes change that force us to
do a dynamic update.

  • html/HTMLTagNames.in:

Add the picture element.

  • html/parser/HTMLSrcsetParser.h:

(WebCore::ImageCandidate::srcOrigin):
(WebCore::ImageCandidate::isEmpty):
Some helpers for picture parsing.

LayoutTests:

  • fast/picture: Added.
  • fast/picture/image-picture-1x-expected.txt: Added.
  • fast/picture/image-picture-1x.html: Added.
  • fast/picture/resources: Added.
  • fast/picture/resources/blue_rect.jpg: Added.
  • fast/picture/resources/currentSrcHelper.js: Added.

(fileName):
(currentSrcFileName):
(currentSrcFileNameNoParams):

  • fast/picture/resources/image-set-4x.png: Added.
12:10 PM Changeset in webkit [192952] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Removed unnecessary #if USE(JSVALUE64).
https://bugs.webkit.org/show_bug.cgi?id=151733

Not reviewed.

  • dfg/DFGClobberize.h:

(JSC::DFG::clobberize):

11:46 AM Changeset in webkit [192951] by peavo@outlook.com
  • 2 edits in trunk/Source/WebCore

[WinCairo][MediaFoundation] Video is not rendered correctly on some graphics cards.
https://bugs.webkit.org/show_bug.cgi?id=151757

Reviewed by Alex Christensen.

We need to make sure we use the same bitmap format as in the Direct3D surface
in video memory when copying surface data and rendering with Cairo.

  • platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:

(WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::presentSample):
(WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::paintCurrentFrame):

11:20 AM Changeset in webkit [192950] by mark.lam@apple.com
  • 9 edits in trunk/Source/JavaScriptCore

Use the JITAddGenerator snippet in the FTL.
https://bugs.webkit.org/show_bug.cgi?id=151519

Reviewed by Geoffrey Garen.

One detail about how we choosing to handle operands to the binary snippets that
may be constant: the slow path call to a C++ function still needs the constant
operand loaded in a register. To simplify things, we're choosing to always tell
LLVM to load the operands into registers even if they may be constant. However,
even though a constant operand is preloaded in a register, the snippet generator
will not be made aware of it. It will continue to load the constant as an
immediate.

  • ftl/FTLCompile.cpp:
  • ftl/FTLCompileBinaryOp.cpp:

(JSC::FTL::generateArithSubFastPath):
(JSC::FTL::generateValueAddFastPath):

  • generateValueAddFastPath() currently is an exact copy of generateArithSubFastPath() except that it uses JITAddGenerator instead of JITSubGenerator. When we add support for JITMulGenerator later, the code will start to vary. We'll refactor these functions then when we have more insight into what needs to vary between the implementations.
  • ftl/FTLCompileBinaryOp.h:
  • ftl/FTLInlineCacheDescriptor.h:
  • ftl/FTLInlineCacheDescriptorInlines.h:

(JSC::FTL::ValueAddDescriptor::ValueAddDescriptor):
(JSC::FTL::ValueAddDescriptor::icSize):

  • ftl/FTLInlineCacheSize.cpp:

(JSC::FTL::sizeOfValueAdd):

  • ftl/FTLInlineCacheSize.h:
  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::DFG::LowerDFGToLLVM::lower):
(JSC::FTL::DFG::LowerDFGToLLVM::compileValueAdd):

11:15 AM Changeset in webkit [192949] by mark.lam@apple.com
  • 4 edits in trunk/Source/JavaScriptCore

Teach DFG that ArithSub can now clobber the heap (and other things).
https://bugs.webkit.org/show_bug.cgi?id=151733

Reviewed by Geoffrey Garen.

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGClobberize.h:

(JSC::DFG::clobberize):

  • dfg/DFGPredictionPropagationPhase.cpp:

(JSC::DFG::PredictionPropagationPhase::propagate):

11:13 AM Changeset in webkit [192948] by beidson@apple.com
  • 12 edits in trunk/Source/WebCore

Modern IDB: Get rid of IDBExceptionCode.
https://bugs.webkit.org/show_bug.cgi?id=151753

Reviewed by Alex Christensen.

No new tests (No change in behavior).

  • Modules/indexeddb/client/IDBIndexImpl.cpp:

(WebCore::IDBClient::IDBIndex::count):
(WebCore::IDBClient::IDBIndex::doCount):
(WebCore::IDBClient::IDBIndex::get):
(WebCore::IDBClient::IDBIndex::doGet):
(WebCore::IDBClient::IDBIndex::getKey):
(WebCore::IDBClient::IDBIndex::doGetKey):

  • Modules/indexeddb/client/IDBObjectStoreImpl.cpp:

(WebCore::IDBClient::IDBObjectStore::get):
(WebCore::IDBClient::IDBObjectStore::deleteFunction):
(WebCore::IDBClient::IDBObjectStore::clear):
(WebCore::IDBClient::IDBObjectStore::createIndex):
(WebCore::IDBClient::IDBObjectStore::index):
(WebCore::IDBClient::IDBObjectStore::deleteIndex):
(WebCore::IDBClient::IDBObjectStore::count):
(WebCore::IDBClient::IDBObjectStore::doCount):

  • Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:

(WebCore::IDBClient::IDBOpenDBRequest::fireErrorAfterVersionChangeAbort):

  • Modules/indexeddb/client/IDBTransactionImpl.cpp:

(WebCore::IDBClient::IDBTransaction::abortOnServerAndCancelRequests):

  • Modules/indexeddb/server/IndexValueStore.cpp:

(WebCore::IDBServer::IndexValueStore::addRecord):

  • Modules/indexeddb/server/MemoryIDBBackingStore.cpp:

(WebCore::IDBServer::MemoryIDBBackingStore::beginTransaction):
(WebCore::IDBServer::MemoryIDBBackingStore::abortTransaction):
(WebCore::IDBServer::MemoryIDBBackingStore::commitTransaction):
(WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):
(WebCore::IDBServer::MemoryIDBBackingStore::deleteObjectStore):
(WebCore::IDBServer::MemoryIDBBackingStore::clearObjectStore):
(WebCore::IDBServer::MemoryIDBBackingStore::createIndex):
(WebCore::IDBServer::MemoryIDBBackingStore::deleteIndex):
(WebCore::IDBServer::MemoryIDBBackingStore::deleteRange):
(WebCore::IDBServer::MemoryIDBBackingStore::addRecord):
(WebCore::IDBServer::MemoryIDBBackingStore::getRecord):
(WebCore::IDBServer::MemoryIDBBackingStore::getIndexRecord):
(WebCore::IDBServer::MemoryIDBBackingStore::getCount):
(WebCore::IDBServer::MemoryIDBBackingStore::openCursor):
(WebCore::IDBServer::MemoryIDBBackingStore::iterateCursor):

  • Modules/indexeddb/server/MemoryIndex.cpp:

(WebCore::IDBServer::MemoryIndex::putIndexKey):

  • Modules/indexeddb/server/MemoryObjectStore.cpp:

(WebCore::IDBServer::MemoryObjectStore::createIndex):
(WebCore::IDBServer::MemoryObjectStore::deleteIndex):

  • Modules/indexeddb/server/UniqueIDBDatabase.cpp:

(WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations):
(WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):

  • Modules/indexeddb/shared/IDBError.cpp:

(WebCore::IDBError::IDBError):
(WebCore::IDBError::name):
(WebCore::IDBError::message):
(WebCore::idbErrorName): Deleted.
(WebCore::idbErrorDescription): Deleted.

  • Modules/indexeddb/shared/IDBError.h:

(WebCore::IDBError::code):
(WebCore::IDBError::isNull):

11:04 AM Changeset in webkit [192947] by jiewen_tan@apple.com
  • 3 edits
    2 adds in trunk

Null dereference loading Blink layout test fast/loader/unload-mutation-crash.html
https://bugs.webkit.org/show_bug.cgi?id=149305
<rdar://problem/22747892>

Reviewed by Brent Fulgham.

Source/WebCore:

Add an extra guard to replaceDocument() against rude JS in unload event handlers.

Test: fast/loader/unload-mutation-crash.html

  • loader/DocumentWriter.cpp:

(WebCore::DocumentWriter::replaceDocument):
(WebCore::DocumentWriter::begin):

LayoutTests:

This test case is from Blink r180918:
https://codereview.chromium.org/495743003

  • fast/loader/unload-mutation-crash-expected.txt: Added.
  • fast/loader/unload-mutation-crash.html: Added.
10:49 AM Changeset in webkit [192946] by commit-queue@webkit.org
  • 7 edits
    2 adds in trunk/Source/JavaScriptCore

[JSC] Handle x86 partial register stalls in Air
https://bugs.webkit.org/show_bug.cgi?id=151735

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-02
Reviewed by Filip Pizlo.

This patch adds a primitive false-dependency breaking
algorithm to Air. We look for redefinition of the same
variable that is too close to a partial definition.

There is not explicit dependency tracking going on,
but it is pretty fast and the extra xorps added on false-positives
are cheap anyway.

Typically, partial register stalls appear from instructions
interfering with themselves in small loops. Something like:

Label0:

cvtsi2sdq %eax, %xmm0
...
jmp Label0

Those are correctly detected by propagating the local distance
information from block to block until no unsafe chain is found.

The test testInt32ToDoublePartialRegisterStall() checks the kind
of cases we typically find from JavaScript.
The execution time is 20% faster with a register reset (which is
astounding since the very next instruction has a real dependency).

Future tweaks will be needed when we can run more JavaScript:
-Handle function calls differently.
-Anything with a special can have hidden instructions.

We need to take them into account.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::moveZeroToDouble):

  • assembler/X86Assembler.h:

(JSC::X86Assembler::xorps_rr):
(JSC::X86Assembler::xorpd_rr):
According to the documentation, starting with Sandy Bridge,
registers reset can be done in the frontend with xorps.

  • b3/B3IndexSet.h:

(JSC::B3::IndexSet::remove):

  • b3/air/AirFixPartialRegisterStalls.cpp: Added.

(JSC::B3::Air::fixPartialRegisterStalls):

  • b3/air/AirFixPartialRegisterStalls.h: Added.
  • b3/air/AirGenerate.cpp:

(JSC::B3::Air::prepareForGeneration):

  • b3/testb3.cpp:

(JSC::B3::testInt32ToDoublePartialRegisterStall):
(JSC::B3::run):

  • jit/FPRInfo.h:
9:27 AM Changeset in webkit [192945] by commit-queue@webkit.org
  • 6 edits in trunk

Web Inspector: Handle YieldExpressions in the ScriptSyntaxTree
https://bugs.webkit.org/show_bug.cgi?id=151730

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2015-12-02
Reviewed by Brian Burg.

Source/WebInspectorUI:

  • UserInterface/Models/NativeFunctionParameters.js:

Add the Generator API.

  • UserInterface/Models/ScriptSyntaxTree.js:

(WebInspector.ScriptSyntaxTree.prototype._recurse):
(WebInspector.ScriptSyntaxTree.prototype._createInternalSyntaxTree):
Handle YieldExpressions.

LayoutTests:

  • inspector/model/parse-script-syntax-tree-expected.txt:
  • inspector/model/parse-script-syntax-tree.html:
8:53 AM Changeset in webkit [192944] by Brent Fulgham
  • 25 edits in trunk/Tools

[Win] Run non-http tests without Cygwin
https://bugs.webkit.org/show_bug.cgi?id=151721

Reviewed by Andy Estes.

Support native 32-bit and 64-bit Python (and Perl) builds
for running tests:

  1. Use "startswith('win')", rather than "== 'win32'" to support

various Windows build types.

  1. Supply full path for some native Windows utilities, since the

path environment does not always have the specified, and they are
guaranteed to exist in those specific locations.

  1. Make sure native Windows Python test runs pass proper environment

variables to run programs.

  1. Append 'exe' suffix when running Windows executables.
  2. Use the _winreg Python module on Windows, since the Cygwin 'regtool'

command doesn't exist.

  • Scripts/update-webkit: Use Perl $X command to refer to the path of

the current Perl executable, rather than requiring a new path search.

  • Scripts/webkitpy/common/find_files_unittest.py:

(TestWinNormalize.test_win): Use startswith('win').

  • Scripts/webkitpy/common/prettypatch_unittest.py:

(test_pretty_diff_encodings): Ditto.

  • Scripts/webkitpy/common/system/executive.py:

(Executive._should_close_fds): Ditto.
(Executive.shell_command_for_script): Use startswith('win').
(Executive.kill_process): Use full path to killall executable.
(Executive.check_running_pid): Use startswith('win').
(Executive.running_pids): Ditto.
(Executive.kill_all): Ditto. Also use path to 'killall' executable when
running under native Windows Python.
(Executive._child_process_encoding): Use startswith('win').
(Executive._should_encode_child_process_arguments): Ditto.
(Executive.popen): Recognize proper script engine on Windows, since it
does not support the shebang syntax.
(Executive.run_in_parallel): Use startswith('win').

  • Scripts/webkitpy/common/system/executive_unittest.py:

(never_ending_command): Ditto.
(ExecutiveTest.test_run_command_with_unicode): Ditto.
(ExecutiveTest.serial_test_kill_process): Ditto.
(ExecutiveTest.serial_test_kill_all): Ditto.
(ExecutiveTest.serial_test_check_running_pid): Ditto.
(ExecutiveTest.serial_test_run_in_parallel): Ditto.
(main): Ditto.

  • Scripts/webkitpy/common/system/file_lock.py:

(FileLock._create_lock): Ditto.
(FileLock._remove_lock): Ditto.

  • Scripts/webkitpy/common/system/filesystem_unittest.py:

(RealFileSystemTest.test_chdir): Ditto.
(RealFileSystemTest.test_chdirnotexists): Ditto.
(RealFileSystemTest.test_maybe_make_directory
failure): Ditto.

  • Scripts/webkitpy/common/system/path_unittest.py:

(AbspathTest.test_abspath_to_uri_win): Ditto.

  • Scripts/webkitpy/common/system/platforminfo.py:

(PlatformInfo._determine_os_name): Ditto.

  • Scripts/webkitpy/common/system/user.py: Ditto.
  • Scripts/webkitpy/layout_tests/controllers/manager_unittest.py:

(ManagerTest.integration_test_needs_servers): Ditto.

  • Scripts/webkitpy/layout_tests/servers/apache_http_server.py:

(LayoutTestApacheHttpd.init): Handle upper and lower-case
driver letters.
(LayoutTestApacheHttpd._get_apache_config_file_path): Ditto.

  • Scripts/webkitpy/layout_tests/servers/apache_http_server_unittest.py:

(TestLayoutTestApacheHttpd.test_start_cmd): Ditto.

  • Scripts/webkitpy/layout_tests/servers/http_server_base.py:

(HttpServerBase._check_that_all_ports_are_available): Ditto.

  • Scripts/webkitpy/layout_tests/servers/http_server_unittest.py:

(TestHttpServer.test_start_cmd): Ditto.

  • Scripts/webkitpy/port/base.py:

(Port.to.setup_environ_for_server): Include 'COMSPEC', 'SYSTEMDRIVE',
and 'SYSTEMROOT' in environment passed to test runners.
(Port._apache_config_file_name_for_platform): Use startswith('win').
(Port._build_path): Ditto.
(Port._path_to_driver): Include 'exe' suffix when running under native
Windows.

  • Scripts/webkitpy/port/driver.py:

(Driver._setup_environ_for_driver): Explicitly make some environment
variables strings.

  • Scripts/webkitpy/port/server_process.py:

(ServerProcess.init): Use startswith('win').

  • Scripts/webkitpy/port/win.py:

(WinPort): Use the win32 registry utilities on Windows, and appropriate
registry key formats.
(WinPort._ntsd_location): Revise tool search paths for Windows 10.
(WinPort.read_registry_value): Revise to use _winreg library on Windows,
and regtool on Cygwin.
(WinPort.write_registry_value): Ditto.
(WinPort.setup_crash_log_saving): Ditto.
(WinPort.restore_crash_log_saving): Ditto.
(WinPort.prevent_error_dialogs): Ditto.
(WinPort.allow_error_dialogs): Ditto.
(WinPort.find_system_pid): Revise to use Windows management
infrastructure on native Windows, continue using 'ps' on Cygwin.
(WinPort.read_registry_string): Deleted.
(WinPort.write_registry_string): Deleted.

  • Scripts/webkitpy/test/main.py:

(main): Use startswith('win').
(Tester._parse_args): Ditto.

4:08 AM Changeset in webkit [192943] by peavo@outlook.com
  • 2 edits in trunk/Source/WebCore

[WinCairo] Compile error.
https://bugs.webkit.org/show_bug.cgi?id=151742

Reviewed by Csaba Osztrogonác.

System font flag has moved from Font class to FontData class.

  • platform/graphics/win/SimpleFontDataCairoWin.cpp:

(WebCore::Font::platformInit):

Note: See TracTimeline for information about the timeline view.