Timeline
Aug 11, 2019:
- 7:00 PM Changeset in webkit [248525] by
-
- 13 edits1 add in trunk/Source
Add threading assertions to RefCounted
https://bugs.webkit.org/show_bug.cgi?id=200507
Reviewed by Ryosuke Niwa.
Source/JavaScriptCore:
- dfg/DFGPlan.cpp:
(JSC::DFG::Plan::Plan):
Disable threading assertions for DFG::Plan::m_inlineCallFrames while the JSC team
investigates.
Source/WebKit:
Enable new RefCounted threading assertions for WebKit2
(UIProcess + auxiliary processes).
- Shared/AuxiliaryProcess.cpp:
(WebKit::AuxiliaryProcess::initialize):
- Shared/Cocoa/WebKit2InitializeCocoa.mm:
(WebKit::runInitializationCode):
- Shared/WebKit2Initialize.cpp:
(WebKit::InitializeWebKit2):
Source/WebKitLegacy/mac:
- WebView/WebView.mm:
(+[WebView initialize]):
Enable new RefCounted threading assertions for WebKitLegacy.
Source/WTF:
Add threading assertions to RefCounted to try and catch unsafe concurrent ref'ing / derefing of
RefCounted objects from several threads. If you hit these new assertions, it likely means you either
need to:
- Have your class subclass ThreadSafeRefCounted instead of RefCounted
or
- Make sure your objects always gets ref'd / deref'd from the same thread.
These assertions already found several thread safety bugs in our code base, which I fixed via
dependency bugs.
These assertions are currently enabled in WebKit (UIProcess, child processes and
WebKitLegacy), they do not apply other JavascriptCore API clients.
- WTF.xcodeproj/project.pbxproj:
- wtf/CMakeLists.txt:
- wtf/RefCounted.cpp: Added.
- wtf/RefCounted.h:
(WTF::RefCountedBase::ref const):
(WTF::RefCountedBase::disableThreadingChecks):
(WTF::RefCountedBase::enableThreadingChecksGlobally):
(WTF::RefCountedBase::RefCountedBase):
(WTF::RefCountedBase::areThreadingCheckedEnabled const):
(WTF::RefCountedBase::derefBase const):
- wtf/SizeLimits.cpp:
- 4:27 PM Changeset in webkit [248524] by
-
- 1 copy in tags/Safari-608.1.42.2
Tag Safari-608.1.42.2.
- 4:25 PM Changeset in webkit [248523] by
-
- 1 copy in tags/Safari-608.1.47
Tag Safari-608.1.47.
- 12:11 PM Changeset in webkit [248522] by
-
- 15 edits in trunk/Source/WebKit
WebPage and ViewportConfiguration have differing notions of viewLayoutSize
https://bugs.webkit.org/show_bug.cgi?id=200619
Reviewed by Tim Horton.
The notion of a "view layout size" exists on WebPage and WebPageProxy for the purpose of specifying an intrinsic
content size for the entire web view on macOS. However, it also exists in ViewportConfiguration (as
viewLayoutSize) and WebPageProxy (under the name m_viewportConfigurationViewLayoutSize) for the purposes of
specifying the minimum layout size of the page's viewport.
This is especially confusing in WebPageProxy, which has both m_viewportConfigurationViewLayoutSize and
m_viewLayoutSize. To remedy this, rename "*viewLayoutSize" for the purposes of specifying an intrinsic web view
size to "*minimumSizeForAutoLayout" instead, which is consistent with the corresponding SPI property name on
WKView.
No change in behavior.
- Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode const):
(WebKit::WebPageCreationParameters::decode):
- Shared/WebPageCreationParameters.h:
- UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _minimumLayoutWidth]):
(-[WKWebView _setMinimumLayoutWidth:]):
- UIProcess/Cocoa/WebViewImpl.mm:
(WebKit::WebViewImpl::setMinimumSizeForAutoLayout):
(WebKit::WebViewImpl::minimumSizeForAutoLayout const):
(WebKit::WebViewImpl::setIntrinsicContentSize):
- UIProcess/DrawingAreaProxy.h:
(WebKit::DrawingAreaProxy::minimumSizeForAutoLayoutDidChange):
(WebKit::DrawingAreaProxy::viewLayoutSizeDidChange): Deleted.
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):
- UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::minimumSizeForAutoLayout const):
(WebKit::WebPageProxy::viewLayoutSize const): Deleted.
- UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
- UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
(WebKit::TiledCoreAnimationDrawingAreaProxy::minimumSizeForAutoLayoutDidChange):
(WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
(WebKit::TiledCoreAnimationDrawingAreaProxy::willSendUpdateGeometry):
(WebKit::TiledCoreAnimationDrawingAreaProxy::viewLayoutSizeDidChange): Deleted.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
- WebProcess/WebPage/WebPage.cpp:
(WebKit::m_textAutoSizingAdjustmentTimer):
(WebKit::WebPage::reinitializeWebPage):
(WebKit::WebPage::setMinimumSizeForAutoLayout):
(WebKit::WebPage::updateIntrinsicContentSizeIfNeeded):
(WebKit::WebPage::setViewLayoutSize): Deleted.
- WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::minimumSizeForAutoLayout const):
(WebKit::WebPage::viewLayoutSize const): Deleted.
- WebProcess/WebPage/WebPage.messages.in:
- WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
- 9:21 AM Changeset in webkit [248521] by
-
- 4 edits in trunk
[MSE][GStreamer] Don't use vorbisparse
https://bugs.webkit.org/show_bug.cgi?id=200622
Reviewed by Philippe Normand.
Source/WebCore:
This patch has been splitted from the original WebKitMediaSrc rework
patch (https://bugs.webkit.org/show_bug.cgi?id=199719).
Unlike other parsers, vorbisparse has latency (in the sense that when
it gets a chain call with a series of complete frames, it may not emit
the parsed frames until another chain in the future), which makes it
inappropriate for AppendPipeline, as there is no good way I know to
flush it.
But actually vorbisparse is not known to be necessary and it was only
introduced for consistency with other formats. Parsers are used in
AppendPipeline to reconstruct information that is lost due to poor
muxes. There have been no reported cases of this being a problem with
Vorbis in WebM, so I'm just removing the parser.
Fixes imported/w3c/web-platform-tests/media-source/mediasource-config-change-webm-a-bitrate.html
- platform/graphics/gstreamer/mse/AppendPipeline.cpp:
(WebCore::createOptionalParserForFormat):
LayoutTests:
- platform/gtk/TestExpectations:
- 7:34 AM Changeset in webkit [248520] by
-
- 2 edits in branches/safari-608.1.42-branch/Source/JavaScriptCore
Apply patch. rdar://problem/54171864
- 7:30 AM Changeset in webkit [248519] by
-
- 2 edits in branches/safari-608.1-branch/Source/WebCore
Apply patch. rdar://problem/54139834
- 7:30 AM Changeset in webkit [248518] by
-
- 2 edits in branches/safari-608.1-branch/Source/JavaScriptCore
Apply patch. rdar://problem/54171879
- 4:02 AM Changeset in webkit [248517] by
-
- 19 edits1 move1 add in trunk/Source/WebCore
Factor complex line layout path out from RenderBlockFlow
https://bugs.webkit.org/show_bug.cgi?id=200612
Reviewed by Zalan Bujtas.
This patch factors the line layout code that is currently part of the RenderBlockFlow and lives in RenderBlockLineLayout.cpp
into a new ComplexLineLayout class. ComplexLineLayout is a member of RenderBlockFlow.
In the future we can stop constructing ComplexLineLayout at all when using other line layout paths.
- Sources.txt:
- WebCore.xcodeproj/project.pbxproj:
- rendering/ComplexLineLayout.cpp: Copied from Source/WebCore/rendering/RenderBlockLineLayout.cpp.
(WebCore::ComplexLineLayout::ComplexLineLayout):
(WebCore::ComplexLineLayout::appendRunsForObject):
(WebCore::ComplexLineLayout::createRootInlineBox):
(WebCore::ComplexLineLayout::createAndAppendRootInlineBox):
(WebCore::ComplexLineLayout::createInlineBoxForRenderer):
(WebCore::ComplexLineLayout::createLineBoxes):
(WebCore::ComplexLineLayout::constructLine):
(WebCore::ComplexLineLayout::textAlignmentForLine const):
(WebCore::ComplexLineLayout::setMarginsForRubyRun):
(WebCore::ComplexLineLayout::updateRubyForJustifiedText):
(WebCore::ComplexLineLayout::computeExpansionForJustifiedText):
(WebCore::ComplexLineLayout::updateLogicalWidthForAlignment):
(WebCore::ComplexLineLayout::computeInlineDirectionPositionsForLine):
(WebCore::ComplexLineLayout::computeInlineDirectionPositionsForSegment):
(WebCore::ComplexLineLayout::removeInlineBox const):
(WebCore::ComplexLineLayout::computeBlockDirectionPositionsForLine):
(WebCore::ComplexLineLayout::handleTrailingSpaces):
(WebCore::ComplexLineLayout::appendFloatingObjectToLastLine):
(WebCore::ComplexLineLayout::createLineBoxesFromBidiRuns):
(WebCore::ComplexLineLayout::layoutRunsAndFloats):
(WebCore::ComplexLineLayout::restartLayoutRunsAndFloatsInRange):
(WebCore::ComplexLineLayout::layoutRunsAndFloatsInRange):
(WebCore::ComplexLineLayout::reattachCleanLineFloats):
(WebCore::ComplexLineLayout::linkToEndLineIfNeeded):
(WebCore::ComplexLineLayout::layoutLineBoxes):
(WebCore::ComplexLineLayout::checkFloatInCleanLine):
(WebCore::ComplexLineLayout::determineStartPosition):
(WebCore::ComplexLineLayout::determineEndPosition):
(WebCore::ComplexLineLayout::checkPaginationAndFloatsAtEndLine):
(WebCore::ComplexLineLayout::lineWidthForPaginatedLineChanged const):
(WebCore::ComplexLineLayout::matchedEndLine):
(WebCore::ComplexLineLayout::addOverflowFromInlineChildren):
(WebCore::ComplexLineLayout::deleteEllipsisLineBoxes):
(WebCore::ComplexLineLayout::checkLinesForTextOverflow):
(WebCore::ComplexLineLayout::positionNewFloatOnLine):
(WebCore::ComplexLineLayout::startAlignedOffsetForLine):
(WebCore::ComplexLineLayout::updateFragmentForLine const):
(WebCore::ComplexLineLayout::style const):
(WebCore::ComplexLineLayout::layoutContext const):
(WebCore::RenderBlockFlow::appendRunsForObject): Deleted.
(WebCore::RenderBlockFlow::createRootInlineBox): Deleted.
(WebCore::RenderBlockFlow::createAndAppendRootInlineBox): Deleted.
(WebCore::createInlineBoxForRenderer): Deleted.
(WebCore::RenderBlockFlow::createLineBoxes): Deleted.
(WebCore::RenderBlockFlow::constructLine): Deleted.
(WebCore::RenderBlockFlow::textAlignmentForLine const): Deleted.
(WebCore::RenderBlockFlow::setMarginsForRubyRun): Deleted.
(WebCore::RenderBlockFlow::updateRubyForJustifiedText): Deleted.
(WebCore::RenderBlockFlow::computeExpansionForJustifiedText): Deleted.
(WebCore::RenderBlockFlow::updateLogicalWidthForAlignment): Deleted.
(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine): Deleted.
(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment): Deleted.
(WebCore::RenderBlockFlow::removeInlineBox const): Deleted.
(WebCore::RenderBlockFlow::computeBlockDirectionPositionsForLine): Deleted.
(WebCore::RenderBlockFlow::handleTrailingSpaces): Deleted.
(WebCore::RenderBlockFlow::appendFloatingObjectToLastLine): Deleted.
(WebCore::RenderBlockFlow::createLineBoxesFromBidiRuns): Deleted.
(WebCore::RenderBlockFlow::layoutRunsAndFloats): Deleted.
(WebCore::RenderBlockFlow::restartLayoutRunsAndFloatsInRange): Deleted.
(WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange): Deleted.
(WebCore::RenderBlockFlow::reattachCleanLineFloats): Deleted.
(WebCore::RenderBlockFlow::linkToEndLineIfNeeded): Deleted.
(WebCore::RenderBlockFlow::layoutLineBoxes): Deleted.
(WebCore::RenderBlockFlow::checkFloatInCleanLine): Deleted.
(WebCore::RenderBlockFlow::determineStartPosition): Deleted.
(WebCore::RenderBlockFlow::determineEndPosition): Deleted.
(WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine): Deleted.
(WebCore::RenderBlockFlow::lineWidthForPaginatedLineChanged const): Deleted.
(WebCore::RenderBlockFlow::matchedEndLine): Deleted.
(WebCore::RenderBlock::generatesLineBoxesForInlineChild): Deleted.
(WebCore::RenderBlockFlow::addOverflowFromInlineChildren): Deleted.
(WebCore::RenderBlockFlow::deleteEllipsisLineBoxes): Deleted.
(WebCore::RenderBlockFlow::checkLinesForTextOverflow): Deleted.
(WebCore::RenderBlockFlow::positionNewFloatOnLine): Deleted.
(WebCore::RenderBlockFlow::startAlignedOffsetForLine): Deleted.
(WebCore::RenderBlockFlow::updateFragmentForLine const): Deleted.
- rendering/ComplexLineLayout.h: Added.
(WebCore::ComplexLineLayout::lineBoxes):
(WebCore::ComplexLineLayout::lineBoxes const):
(WebCore::ComplexLineLayout::firstRootBox const):
(WebCore::ComplexLineLayout::lastRootBox const):
- rendering/InlineIterator.h:
(WebCore::IsolateTracker::addFakeRunIfNecessary):
(WebCore::InlineBidiResolver::appendRunInternal):
- rendering/RenderBlock.h:
- rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::RenderBlockFlow):
(WebCore::RenderBlockFlow::willBeDestroyed):
(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::RenderBlockFlow::updateStaticInlinePositionForChild):
(WebCore::RenderBlockFlow::deleteLines):
(WebCore::RenderBlockFlow::hitTestInlineChildren):
(WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
(WebCore::RenderBlockFlow::paintInlineChildren):
(WebCore::RenderBlockFlow::layoutSimpleLines):
(WebCore::RenderBlockFlow::ensureLineBoxes):
- rendering/RenderBlockFlow.h:
(WebCore::RenderBlockFlow::lineBoxes):
(WebCore::RenderBlockFlow::lineBoxes const):
(WebCore::RenderBlockFlow::firstRootBox const):
(WebCore::RenderBlockFlow::lastRootBox const):
(WebCore::RenderBlockFlow::floatingObjects):
(WebCore::RenderBlockFlow::complexLineLayout):
(WebCore::RenderBlockFlow::overrideTextAlignmentForLine const):
(WebCore::RenderBlockFlow::adjustInlineDirectionLineBounds const):
- rendering/RenderBlockLineLayout.cpp: Removed.
- rendering/RenderRubyBase.cpp:
(WebCore::RenderRubyBase::overrideTextAlignmentForLine const):
(WebCore::RenderRubyBase::textAlignmentForLine const): Deleted.
- rendering/RenderRubyBase.h:
- rendering/RenderRubyText.cpp:
(WebCore::RenderRubyText::overrideTextAlignmentForLine const):
(WebCore::RenderRubyText::textAlignmentForLine const): Deleted.
- rendering/RenderRubyText.h:
- rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::generateLineBoxTree):
- rendering/line/LineBreaker.cpp:
(WebCore::LineBreaker::skipLeadingWhitespace):
- rendering/line/LineBreaker.h:
(WebCore::LineBreaker::positionNewFloatOnLine):
- rendering/line/LineInlineHeaders.h:
(WebCore::setStaticPositions):
- rendering/svg/RenderSVGText.cpp:
(WebCore::RenderSVGText::createRootInlineBox): Deleted.
- rendering/svg/RenderSVGText.h:
- rendering/updating/RenderTreeBuilderList.cpp:
(WebCore::generatesLineBoxesForInlineChild):
(WebCore::getParentOfFirstLineBox):
Aug 10, 2019:
- 10:03 PM Changeset in webkit [248516] by
-
- 4 edits in branches/safari-608.1-branch/Source/WebKit
Apply patch. rdar://problem/54130665
- 9:48 PM Changeset in webkit [248515] by
-
- 2 edits in trunk/Tools
WebKitTestRunner's InjectedBundle has too aggressive stripping, resulting in non-symbolicated crash logs
https://bugs.webkit.org/show_bug.cgi?id=200621
Reviewed by Dan Bernstein.
- WebKitTestRunner/Configurations/InjectedBundle.xcconfig:
- 9:03 PM Changeset in webkit [248514] by
-
- 6 edits3 adds in trunk
REGRESSION (r245974): Missing content on habitburger.com, amazon.com
https://bugs.webkit.org/show_bug.cgi?id=200618
rdar://problem/53920224
Reviewed by Zalan Bujtas.
Source/WebCore:
In r245974 TileController::adjustTileCoverageRect() started to intersect the coverage
rect with the bounds of the layer, which is wrong because this coverage rect is passed down
to descendant layers, and they may project outside the bounds of this tiled layer.
This caused missing dropdowns on amazon.com, and a missing menu on habitburger.com on iPhone.
The fix is to just not do the intersection with the bounds. TileGrid::getTileIndexRangeForRect()
already ensures that we never make tiles outside the bounds of a TileController.
Test: compositing/backing/layer-outside-tiled-parent.html
- platform/graphics/ca/TileController.cpp:
(WebCore::TileController::adjustTileCoverageRect):
- platform/graphics/ca/TileGrid.cpp:
(WebCore::TileGrid::ensureTilesForRect):
LayoutTests:
- compositing/backing/layer-outside-tiled-parent-expected.txt: Added.
- compositing/backing/layer-outside-tiled-parent.html: Added.
- platform/ios-wk2/compositing/backing/layer-outside-tiled-parent-expected.txt: Added.
- tiled-drawing/tile-coverage-iframe-to-zero-coverage-expected.txt:
- tiled-drawing/tiled-backing-in-window-expected.txt:
- 8:46 PM Changeset in webkit [248513] by
-
- 7 edits in trunk
Accessibility client cannot navigate to internal links targets on iOS.
https://bugs.webkit.org/show_bug.cgi?id=200559
<rdar://problem/45242534>
Patch by Andres Gonzalez <Andres Gonzalez> on 2019-08-10
Reviewed by Zalan Bujtas.
Source/WebCore:
The cause of the problem on iOS is that AccessibilityObject::firstAccessibleObjectFromNode
used in AccessibilityRenderObject::linkedUIElements may return an object
that is ignored by accessibility clients on iOS, and thus the client
would not track the target of an internal link. This change ensures that
accessibilityLinkedElement will return a valid accessibility element to
the client, if it is exists.
- accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::firstAccessibleObjectFromNode):
(WebCore::firstAccessibleObjectFromNode):
- accessibility/AccessibilityObject.h:
- accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper accessibilityLinkedElement]):
LayoutTests:
Extneded this test to not only check that internal links expose their
target, but also that the target is an accessible element. Added a
second test case where the target is contained in a grouping element.
- accessibility/ios-simulator/internal-link-expected.txt:
- accessibility/ios-simulator/internal-link.html:
- 8:18 PM Changeset in webkit [248512] by
-
- 14 edits3 adds in branches/safari-608.1.42-branch
Cherry-pick r248494. rdar://problem/54171864
Universal XSS in JSObject::putInlineSlow and JSValue::putToPrimitive
https://bugs.webkit.org/show_bug.cgi?id=199864
Reviewed by Saam Barati.
Source/JavaScriptCore:
Our JSObject::put implementation is not correct in term of the spec. Our Put implementation is something like this.
JSObject::put(object):
if (can-do-fast-path(object))
return fast-path(object);
slow-path
do {
object-put-check-and-setter-calls(object); (1)
object = object->prototype;
} while (is-object(object));
return do-put(object);
Since JSObject::put is registered in the methodTable, the derived classes can override it. Some of classes are adding
extra checks to this put.
Derived::put(object):
if (do-extra-check(object))
fail
return JSObject::put(object)
The problem is that Derived::put is only called when the |this| object is the Derived class. When traversing Prototype in
JSObject::put, at (1), we do not perform the extra checks added in Derived::put even ifobjectis Derived one. This means that
we skip the check.
Currently, JSObject::put and WebCore checking mechanism are broken. JSObject::put should call getOwnPropertySlot at (1) to
perform the additional checks. This behavior is matching against the spec. However, currently, our JSObject::getOwnPropertySlot
does not propagate setter information. This is required to cache cacheable Put at (1) for CustomValue, CustomAccessor, and
Accessors. We also need to reconsider how to integrate static property setters to this mechanism. So, basically, this involves
large refactoring to renew our JSObject::put and JSObject::getOwnPropertySlot.
To work-around for now, we add a new TypeInfo flag, HasPutPropertySecurityCheck . And adding this flag to DOM objects
that implements the addition checks. We also add doPutPropertySecurityCheck method hook to perform the check in JSObject.
When we found this flag at (1), we perform doPutPropertySecurityCheck to properly perform the checks.
Since our JSObject::put code is old and it does not match against the spec now, we should refactor it largely. This is tracked separately in [1].
- runtime/ClassInfo.h:
- runtime/JSCJSValue.cpp: (JSC::JSValue::putToPrimitive):
- runtime/JSCell.cpp: (JSC::JSCell::doPutPropertySecurityCheck):
- runtime/JSCell.h:
- runtime/JSObject.cpp: (JSC::JSObject::putInlineSlow): (JSC::JSObject::getOwnPropertyDescriptor):
- runtime/JSObject.h: (JSC::JSObject::doPutPropertySecurityCheck):
- runtime/JSTypeInfo.h: (JSC::TypeInfo::hasPutPropertySecurityCheck const):
Source/WebCore:
Test: http/tests/security/cross-frame-access-object-put-optimization.html
- bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::doPutPropertySecurityCheck):
- bindings/js/JSLocationCustom.cpp: (WebCore::JSLocation::doPutPropertySecurityCheck):
- bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader):
- bindings/scripts/test/JS/JSTestActiveDOMObject.h:
LayoutTests:
- http/tests/security/cross-frame-access-object-put-optimization-expected.txt: Added.
- http/tests/security/cross-frame-access-object-put-optimization.html: Added.
- http/tests/security/resources/cross-frame-iframe-for-object-put-optimization-test.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248494 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:17 PM Changeset in webkit [248511] by
-
- 7 edits in branches/safari-608.1.42-branch/Source
Versioning.
- 8:02 PM Changeset in webkit [248510] by
-
- 11 edits in branches/safari-608.1-branch/Source
Cherry-pick r248502. rdar://problem/54130678
Disable ContentChangeObserver TouchEvent adjustment on youtube.com on iOS in mobile browsing mode
https://bugs.webkit.org/show_bug.cgi?id=200609
<rdar://problem/54015403>
Reviewed by Maciej Stachowiak.
Source/WebCore:
When watching a youtube video on iOS with "Autoplay" switched to off,
upon finishing the video all clicks anywhere on the page are effectively ignored.
Disabling ContentChangeObserver's TouchEvent adjustment fixes this bug. I verified this manually.
This switch was introduced in r242621, and it disables part of a new feature, so there is low risk of fallout.
- loader/DocumentLoader.h: (WebCore::DocumentLoader::setAllowContentChangeObserverQuirk): (WebCore::DocumentLoader::allowContentChangeObserverQuirk const):
- page/Quirks.cpp: (WebCore::Quirks::shouldDisableContentChangeObserverTouchEventAdjustment const):
- page/Quirks.h:
- page/ios/ContentChangeObserver.cpp: (WebCore::ContentChangeObserver::touchEventDidStart):
Source/WebKit:
- Shared/WebsitePoliciesData.cpp: (WebKit::WebsitePoliciesData::encode const): (WebKit::WebsitePoliciesData::decode): (WebKit::WebsitePoliciesData::applyToDocumentLoader):
- Shared/WebsitePoliciesData.h:
- UIProcess/API/APIWebsitePolicies.cpp: (API::WebsitePolicies::copy const): (API::WebsitePolicies::data):
- UIProcess/API/APIWebsitePolicies.h:
- UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248502 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:02 PM Changeset in webkit [248509] by
-
- 9 edits in branches/safari-608.1-branch/Source
Cherry-pick r248501. rdar://problem/54130617
[iOS] Add a quirk for gmail.com messages on iPhone iOS13
https://bugs.webkit.org/show_bug.cgi?id=200605
Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
Reviewed by Maciej Stachowiak.
Source/WebCore:
Add a quirk which sets the user agent for gmail.com messages on iPhone
OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
it is fixed.
- page/Quirks.cpp: (WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
- page/Quirks.h:
- platform/UserAgent.h:
- platform/ios/UserAgentIOS.mm: (WebCore::osNameForUserAgent): (WebCore::standardUserAgentWithApplicationName):
- platform/mac/UserAgentMac.mm: (WebCore::standardUserAgentWithApplicationName):
Source/WebKit:
Use WebPage::platformUserAgent() to add the gmail.com quirk.
- UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
- WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::platformUserAgent const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248501 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:02 PM Changeset in webkit [248508] by
-
- 14 edits3 adds in branches/safari-608.1-branch
Cherry-pick r248494. rdar://problem/54171879
Universal XSS in JSObject::putInlineSlow and JSValue::putToPrimitive
https://bugs.webkit.org/show_bug.cgi?id=199864
Reviewed by Saam Barati.
Source/JavaScriptCore:
Our JSObject::put implementation is not correct in term of the spec. Our Put implementation is something like this.
JSObject::put(object):
if (can-do-fast-path(object))
return fast-path(object);
slow-path
do {
object-put-check-and-setter-calls(object); (1)
object = object->prototype;
} while (is-object(object));
return do-put(object);
Since JSObject::put is registered in the methodTable, the derived classes can override it. Some of classes are adding
extra checks to this put.
Derived::put(object):
if (do-extra-check(object))
fail
return JSObject::put(object)
The problem is that Derived::put is only called when the |this| object is the Derived class. When traversing Prototype in
JSObject::put, at (1), we do not perform the extra checks added in Derived::put even ifobjectis Derived one. This means that
we skip the check.
Currently, JSObject::put and WebCore checking mechanism are broken. JSObject::put should call getOwnPropertySlot at (1) to
perform the additional checks. This behavior is matching against the spec. However, currently, our JSObject::getOwnPropertySlot
does not propagate setter information. This is required to cache cacheable Put at (1) for CustomValue, CustomAccessor, and
Accessors. We also need to reconsider how to integrate static property setters to this mechanism. So, basically, this involves
large refactoring to renew our JSObject::put and JSObject::getOwnPropertySlot.
To work-around for now, we add a new TypeInfo flag, HasPutPropertySecurityCheck . And adding this flag to DOM objects
that implements the addition checks. We also add doPutPropertySecurityCheck method hook to perform the check in JSObject.
When we found this flag at (1), we perform doPutPropertySecurityCheck to properly perform the checks.
Since our JSObject::put code is old and it does not match against the spec now, we should refactor it largely. This is tracked separately in [1].
- runtime/ClassInfo.h:
- runtime/JSCJSValue.cpp: (JSC::JSValue::putToPrimitive):
- runtime/JSCell.cpp: (JSC::JSCell::doPutPropertySecurityCheck):
- runtime/JSCell.h:
- runtime/JSObject.cpp: (JSC::JSObject::putInlineSlow): (JSC::JSObject::getOwnPropertyDescriptor):
- runtime/JSObject.h: (JSC::JSObject::doPutPropertySecurityCheck):
- runtime/JSTypeInfo.h: (JSC::TypeInfo::hasPutPropertySecurityCheck const):
Source/WebCore:
Test: http/tests/security/cross-frame-access-object-put-optimization.html
- bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::doPutPropertySecurityCheck):
- bindings/js/JSLocationCustom.cpp: (WebCore::JSLocation::doPutPropertySecurityCheck):
- bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader):
- bindings/scripts/test/JS/JSTestActiveDOMObject.h:
LayoutTests:
- http/tests/security/cross-frame-access-object-put-optimization-expected.txt: Added.
- http/tests/security/cross-frame-access-object-put-optimization.html: Added.
- http/tests/security/resources/cross-frame-iframe-for-object-put-optimization-test.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248494 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:02 PM Changeset in webkit [248507] by
-
- 12 edits16 adds in branches/safari-608.1-branch
Cherry-pick r248491. rdar://problem/54130644
Don't allow cross-origin iframes to autofocus
https://bugs.webkit.org/show_bug.cgi?id=200515
<rdar://problem/54092988>
Reviewed by Ryosuke Niwa.
Source/WebCore:
According to Step 6 in the WhatWG Spec (https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#autofocusing-a-form-control:-the-autofocus-attribute),
the 'autofocus' attribute shouldn't work for cross-origin iframes.
This change is based on the Blink change (patch by <mustaq@chromium.org>):
<https://chromium-review.googlesource.com/c/chromium/src/+/1593026>
Also disallow cross-origin iframes from focusing programmatically without ever having
had any user interaction.
- dom/Element.cpp: Check if an invalid frame is trying to grab the focus. (WebCore::Element::focus):
- html/HTMLFormControlElement.cpp: Check if the focus is moving to an invalid frame. (WebCore::shouldAutofocus):
- page/DOMWindow.cpp: Check if an invalid frame is trying to grab the focus. (WebCore::DOMWindow::focus):
Tools:
Make WebKit.FocusedFrameAfterCrash use same-origin iframes instead
of cross-origin iframes, since it depends on focusing one of the
frames.
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/WebKit/ReloadPageAfterCrash.cpp: (TestWebKitAPI::TEST):
- TestWebKitAPI/Tests/WebKit/many-same-origin-iframes.html: Added.
LayoutTests:
Add test coverage, and simulate user interaction in existing tests
that require focusing a cross-origin frame.
- http/tests/security/clipboard/resources/copy-html.html:
- http/tests/security/clipboard/resources/copy-mso-list.html:
- http/tests/security/clipboard/resources/copy-url.html:
- http/wpt/html/interaction/focus/no-cross-origin-element-focus-expected.txt: Added.
- http/wpt/html/interaction/focus/no-cross-origin-element-focus.html: Added.
- http/wpt/html/interaction/focus/no-cross-origin-window-focus-expected.txt: Added.
- http/wpt/html/interaction/focus/no-cross-origin-window-focus.html: Added.
- http/wpt/html/interaction/focus/resources/child-focus-element.html: Added.
- http/wpt/html/interaction/focus/resources/child-focus-window.html: Added.
- http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub-expected.txt: Added.
- http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub.html: Added.
- http/wpt/html/semantics/forms/autofocus/resources/child-autofocus.html: Added.
- http/wpt/webauthn/resources/last-layer-frame.https.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248491 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:01 PM Changeset in webkit [248506] by
-
- 7 edits in branches/safari-608.1-branch/Source
Cherry-pick r248471. rdar://problem/54130628
Disable CSSOM View Scrolling API for IMDb iOS app
https://bugs.webkit.org/show_bug.cgi?id=200586
<rdar://problem/53645833>
Patch by Alex Christensen <achristensen@webkit.org> on 2019-08-09
Reviewed by Simon Fraser.
Source/WebCore:
They are calling scrollHeight on the HTML element and it is running new code introduced in r235806
Disable this new feature until they update their app to use the iOS13 SDK.
- platform/RuntimeApplicationChecks.h:
- platform/cocoa/RuntimeApplicationChecksCocoa.mm: (WebCore::IOSApplication::isIMDb):
Source/WebKit:
Change the CSSOMViewScrollingAPIEnabled default value to be off for the IMDb app's WKWebViews.
I manually verified this is effective in those WKWebViews but no other WKWebViews and that it fixes the radar.
- Shared/WebPreferences.yaml:
- Shared/WebPreferencesDefaultValues.cpp: (WebKit::defaultCSSOMViewScrollingAPIEnabled):
- Shared/WebPreferencesDefaultValues.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248471 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:01 PM Changeset in webkit [248505] by
-
- 5 edits in branches/safari-608.1-branch/Source
Cherry-pick r248469. rdar://problem/54130692
Tapping buttons in Data Detectors lookup previews doesn't work
https://bugs.webkit.org/show_bug.cgi?id=200579
<rdar://problem/54056519>
Reviewed by Megan Gardner.
Source/WebCore/PAL:
- pal/spi/ios/DataDetectorsUISPI.h:
Source/WebKit:
- Platform/spi/ios/UIKitSPI.h:
- UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _contextMenuInteraction:styleForMenuWithConfiguration:]): If a Data Detectors context menu wants the action menu style, provide it.
(-[WKContentView contextMenuInteraction:willPerformPreviewActionForMenuWithConfiguration:animator:]):
If a Data Detectors context menu provides a view controller to present
on context menu commit, present it. We present on top of the same view
controller that is currently presenting the context menu, but modally
instead of inside the context menu.
If a Data Detectors context menu instead provides a URL to launch on
context menu commit, call openURL.
In both cases, change the commit style to pop, since we're committing
instead of dismissing.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248469 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 8:01 PM Changeset in webkit [248504] by
-
- 4 edits in branches/safari-608.1-branch/Source/WebCore
Cherry-pick r248463. rdar://problem/54139834
REGRESSION (iOS 13): united.com web forms do not respond to taps
https://bugs.webkit.org/show_bug.cgi?id=200531
Reviewed by Antti Koivisto and Wenson Hsieh.
The bug is caused by the content change observer detecting “Site Feedback” link at the bottom of
the page (https://www.united.com/ual/en/US/account/enroll/default) constantly getting re-generated
in every frame via requestAnimationFrame when the page is opened with iPhone UA string.
Note that the content re-generation can be reproduced even in Chrome if iPhone UA string is used.
Ignore this constant content change in ContentChangeObserver as a site specific quirk.
In the future, we should make ContentChangeObserver observe the final location of each element
being observed so that we can ignore content that like this which is placed outside the viewport,
and/or far away from where the user tapped.
- page/Quirks.cpp: (WebCore::Quirks::shouldIgnoreContentChange const): Added.
- page/Quirks.h:
- page/ios/ContentChangeObserver.cpp: (WebCore::ContentChangeObserver::shouldObserveVisibilityChangeForElement):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248463 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 3:50 PM Changeset in webkit [248503] by
-
- 43 edits in trunk/Source/WebCore
Blob should store its session ID
https://bugs.webkit.org/show_bug.cgi?id=200572
Reviewed by Darin Adler.
Blob at creation time now initializes its session ID.
This will allow in the future to call blob registry routines with it.
Update all call sites to provide the session ID.
No observable change.
- Modules/entriesapi/DOMFileSystem.cpp:
(WebCore::DOMFileSystem::getFile):
- Modules/fetch/FetchBody.cpp:
(WebCore::FetchBody::fromFormData):
- Modules/fetch/FetchBody.h:
- Modules/fetch/FetchBodyConsumer.cpp:
(WebCore::blobFromData):
(WebCore::resolveWithTypeAndData):
(WebCore::FetchBodyConsumer::resolve):
(WebCore::FetchBodyConsumer::takeAsBlob):
- Modules/fetch/FetchBodyConsumer.h:
- Modules/fetch/FetchBodyOwner.cpp:
(WebCore::FetchBodyOwner::blob):
- Modules/mediarecorder/MediaRecorder.cpp:
(WebCore::MediaRecorder::createRecordingDataBlob):
- Modules/mediastream/RTCDataChannel.cpp:
(WebCore::RTCDataChannel::didReceiveRawData):
- Modules/websockets/WebSocket.cpp:
(WebCore::WebSocket::didReceiveBinaryData):
- Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
(WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
- bindings/js/JSDOMPromiseDeferred.h:
(WebCore::DeferredPromise::sessionID const):
- bindings/js/SerializedScriptValue.cpp:
(WebCore::CloneDeserializer::readFile):
(WebCore::CloneDeserializer::readTerminal):
- dom/DataTransfer.cpp:
(WebCore::DataTransfer::DataTransfer):
(WebCore::DataTransfer::createForCopyAndPaste):
(WebCore::DataTransfer::filesFromPasteboardAndItemList const):
(WebCore::DataTransfer::createForInputEvent):
(WebCore::DataTransfer::createForDrag):
(WebCore::DataTransfer::createForDragStartEvent):
(WebCore::DataTransfer::createForDrop):
(WebCore::DataTransfer::createForUpdatingDropTarget):
- dom/DataTransfer.h:
- dom/Document.cpp:
(WebCore::Document::originIdentifierForPasteboard const):
- dom/Document.h:
- editing/ReplaceRangeWithTextCommand.cpp:
(WebCore::ReplaceRangeWithTextCommand::inputEventDataTransfer const):
- editing/ReplaceSelectionCommand.cpp:
(WebCore::ReplaceSelectionCommand::inputEventDataTransfer const):
- editing/SpellingCorrectionCommand.cpp:
(WebCore::SpellingCorrectionCommand::inputEventDataTransfer const):
- editing/TypingCommand.cpp:
(WebCore::TypingCommand::inputEventDataTransfer const):
- editing/WebCorePasteboardFileReader.cpp:
(WebCore::WebCorePasteboardFileReader::readFilename):
(WebCore::WebCorePasteboardFileReader::readBuffer):
- editing/WebCorePasteboardFileReader.h:
- editing/cocoa/WebContentReaderCocoa.mm:
(WebCore::createFragmentForImageAttachment):
(WebCore::replaceRichContentWithAttachments):
(WebCore::createFragmentAndAddResources):
(WebCore::sanitizeMarkupWithArchive):
(WebCore::WebContentReader::readImage):
(WebCore::attachmentForFilePath):
(WebCore::attachmentForData):
- editing/markup.cpp:
(WebCore::restoreAttachmentElementsInFragment):
- fileapi/Blob.cpp:
(WebCore::Blob::Blob):
- fileapi/Blob.h:
(WebCore::Blob::create):
(WebCore::Blob::deserialize):
(WebCore::Blob::slice const):
- fileapi/Blob.idl:
- fileapi/File.cpp:
(WebCore::File::createWithRelativePath):
(WebCore::File::File):
- fileapi/File.h:
- fileapi/File.idl:
- html/FileInputType.cpp:
(WebCore::FileInputType::appendFormData const):
(WebCore::FileInputType::filesChosen):
- html/FileListCreator.cpp:
(WebCore::appendDirectoryFiles):
(WebCore::FileListCreator::FileListCreator):
(WebCore::FileListCreator::createFileList):
- html/FileListCreator.h:
(WebCore::FileListCreator::create):
- html/HTMLAttachmentElement.cpp:
(WebCore::HTMLAttachmentElement::updateEnclosingImageWithData):
- html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::toBlob):
- page/EventHandler.cpp:
(WebCore::EventHandler::handleDrag):
- testing/Internals.cpp:
(WebCore::Internals::createFile):
- testing/ServiceWorkerInternals.cpp:
(WebCore::ServiceWorkerInternals::createOpaqueWithBlobBodyResponse):
- workers/service/context/ServiceWorkerFetch.cpp:
(WebCore::ServiceWorkerFetch::dispatchFetchEvent):
- xml/XMLHttpRequest.cpp:
(WebCore::XMLHttpRequest::createResponseBlob):
- 3:45 PM Changeset in webkit [248502] by
-
- 11 edits in trunk/Source
Disable ContentChangeObserver TouchEvent adjustment on youtube.com on iOS in mobile browsing mode
https://bugs.webkit.org/show_bug.cgi?id=200609
<rdar://problem/54015403>
Reviewed by Maciej Stachowiak.
Source/WebCore:
When watching a youtube video on iOS with "Autoplay" switched to off,
upon finishing the video all clicks anywhere on the page are effectively ignored.
Disabling ContentChangeObserver's TouchEvent adjustment fixes this bug. I verified this manually.
This switch was introduced in r242621, and it disables part of a new feature, so there is low risk of fallout.
- loader/DocumentLoader.h:
(WebCore::DocumentLoader::setAllowContentChangeObserverQuirk):
(WebCore::DocumentLoader::allowContentChangeObserverQuirk const):
- page/Quirks.cpp:
(WebCore::Quirks::shouldDisableContentChangeObserverTouchEventAdjustment const):
- page/Quirks.h:
- page/ios/ContentChangeObserver.cpp:
(WebCore::ContentChangeObserver::touchEventDidStart):
Source/WebKit:
- Shared/WebsitePoliciesData.cpp:
(WebKit::WebsitePoliciesData::encode const):
(WebKit::WebsitePoliciesData::decode):
(WebKit::WebsitePoliciesData::applyToDocumentLoader):
- Shared/WebsitePoliciesData.h:
- UIProcess/API/APIWebsitePolicies.cpp:
(API::WebsitePolicies::copy const):
(API::WebsitePolicies::data):
- UIProcess/API/APIWebsitePolicies.h:
- UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
- 3:25 PM Changeset in webkit [248501] by
-
- 9 edits in trunk/Source
[iOS] Add a quirk for gmail.com messages on iPhone iOS13
https://bugs.webkit.org/show_bug.cgi?id=200605
Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
Reviewed by Maciej Stachowiak.
Source/WebCore:
Add a quirk which sets the user agent for gmail.com messages on iPhone
OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
it is fixed.
- page/Quirks.cpp:
(WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
- page/Quirks.h:
- platform/UserAgent.h:
- platform/ios/UserAgentIOS.mm:
(WebCore::osNameForUserAgent):
(WebCore::standardUserAgentWithApplicationName):
- platform/mac/UserAgentMac.mm:
(WebCore::standardUserAgentWithApplicationName):
Source/WebKit:
Use WebPage::platformUserAgent() to add the gmail.com quirk.
- UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
- WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::platformUserAgent const):
- 4:18 AM Changeset in webkit [248500] by
-
- 2 edits in trunk/Source/WebCore
[GStreamer][WebRTC] Remove unused GstAdapter
https://bugs.webkit.org/show_bug.cgi?id=200585
Patch by Thibault Saunier <tsaunier@igalia.com> on 2019-08-10
Reviewed by Philippe Normand.
Minor "refactoring"
- platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.cpp:
(WebCore::GStreamerVideoEncoder::GStreamerVideoEncoder):
- 3:38 AM Changeset in webkit [248499] by
-
- 3 edits in trunk/Source/WebCore
Can’t sort videos on a YouTube channel page on iPad
https://bugs.webkit.org/show_bug.cgi?id=200573
<rdar://problem/53415195>
Reviewed by Darin Adler.
Add a quirk to make touch events non-cancelable (preventDefault() does nothing).
- page/Quirks.cpp:
(WebCore::Quirks::shouldMakeTouchEventNonCancelableForTarget const):
- page/Quirks.h:
- 1:04 AM Changeset in webkit [248498] by
-
- 14 edits2 deletes in trunk/Source
Remove some more unused 32-bit code
https://bugs.webkit.org/show_bug.cgi?id=200607
Reviewed by Alexey Proskuryakov.
Source/WebKit:
- Modules/OSX.modulemap:
Source/WebKitLegacy:
- PlatformMac.cmake:
- WebKitLegacy.xcodeproj/project.pbxproj:
Source/WebKitLegacy/mac:
- Configurations/WebKitLegacy.xcconfig:
- Misc/WebSharingServicePickerController.mm:
(-[WebSharingServicePickerController initWithItems:includeEditorServices:client:style:]):
(-[WebSharingServicePickerController initWithSharingServicePicker:client:]):
(-[WebSharingServicePickerController sharingService:didShareItems:]):
- Plugins/WebNetscapePluginEventHandler.mm:
- Plugins/WebNetscapePluginEventHandlerCarbon.h: Removed.
- Plugins/WebNetscapePluginEventHandlerCarbon.mm: Removed.
- Plugins/WebNetscapePluginEventHandlerCocoa.h:
(WebNetscapePluginEventHandlerCocoa::installKeyEventHandler): Deleted.
(WebNetscapePluginEventHandlerCocoa::removeKeyEventHandler): Deleted.
- Plugins/WebNetscapePluginEventHandlerCocoa.mm:
(WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
(WebNetscapePluginEventHandlerCocoa::keyDown):
(WebNetscapePluginEventHandlerCocoa::focusChanged):
(WebNetscapePluginEventHandlerCocoa::installKeyEventHandler): Deleted.
(WebNetscapePluginEventHandlerCocoa::removeKeyEventHandler): Deleted.
(WebNetscapePluginEventHandlerCocoa::TSMEventHandler): Deleted.
(WebNetscapePluginEventHandlerCocoa::handleTSMEvent): Deleted.
- WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::contextMenuForEvent):
- WebView/WebHTMLView.mm:
(-[WebHTMLView _adjustedBottomOfPageWithTop:bottom:limit:]):
(-[WebHTMLView pressureChangeWithEvent:]):
- WebView/WebView.mm:
(LayerFlushController::flushLayers):
- 12:02 AM Changeset in webkit [248497] by
-
- 14 edits1 delete in trunk/Source
Web Inspector: REGRESSION(r248454): WK1 inspector frontend client doesn't queue messages to the frontend before it's loaded
https://bugs.webkit.org/show_bug.cgi?id=200587
Reviewed by Joseph Pecoraro.
WK1 inspector sends messages to the frontend using
WebCore::InspectorClient::doDispatchMessageOnFrontendPage,
which does not do any sort of queueing to wait until the frontend is loaded (InspectorFrontendHost.loaded()).
Now that we are sending messages immediately, we should always queue.
Source/WebCore:
Covered by existing tests (which were failing after r248454, and now won't fail).
- inspector/InspectorFrontendClientLocal.h:
- inspector/InspectorFrontendClientLocal.cpp:
(WebCore::InspectorFrontendClientLocal::setDockingUnavailable):
(WebCore::InspectorFrontendClientLocal::setAttachedWindow):
(WebCore::InspectorFrontendClientLocal::setDebuggingEnabled):
(WebCore::InspectorFrontendClientLocal::setTimelineProfilingEnabled):
(WebCore::InspectorFrontendClientLocal::startProfilingJavaScript):
(WebCore::InspectorFrontendClientLocal::stopProfilingJavaScript):
(WebCore::InspectorFrontendClientLocal::showConsole):
(WebCore::InspectorFrontendClientLocal::showResources):
(WebCore::InspectorFrontendClientLocal::showMainResourceForFrame):
(WebCore::InspectorFrontendClientLocal::dispatch): Added.
(WebCore::InspectorFrontendClientLocal::dispatchMessage): Added.
(WebCore::InspectorFrontendClientLocal::dispatchMessageAsync): Added.
(WebCore::InspectorFrontendClientLocal::evaluateOnLoad):
Provide additional ways for subclasses to call otherInspectorFrontendAPImethods using
the "on load" queue.
- testing/Internals.cpp:
(WebCore::InspectorStubFrontend::sendMessageToFrontend):
(WebCore::InspectorStubFrontend::frontendLoaded): Deleted.
Leverage the baseInspectorFrontendClientLocal's functions for queueing messages.
- inspector/InspectorClient.h:
- inspector/InspectorClient.cpp: Removed.
(WebCore::InspectorClient::doDispatchMessageOnFrontendPage): Deleted.
- inspector/agents/InspectorTimelineAgent.cpp:
Add missing include.
- Sources.txt:
- WebCore.xcodeproj/project.pbxproj:
Source/WebInspectorUI:
- UserInterface/Test/TestStub.js:
(InspectorFrontendAPI.dispatch): Added.
- UserInterface/Models/Frame.js:
(WI.Frame.prototype.markDOMContentReadyEvent):
(WI.Frame.prototype.markLoadEvent):
- UserInterface/Controllers/TimelineManager.js:
(WI.TimelineManager.prototype.pageDOMContentLoadedEventFired):
(WI.TimelineManager.prototype.pageLoadEventFired):
Source/WebKitLegacy/cf:
- WebCoreSupport/WebInspectorClientCF.cpp:
(WebInspectorClient::sendMessageToFrontend):
Leverage the baseInspectorFrontendClientLocal's functions for queueing messages.