Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 30dd3a9c941fa5e1fc1a285d2b31b5eea1ebf50b
      
https://github.com/WebKit/WebKit/commit/30dd3a9c941fa5e1fc1a285d2b31b5eea1ebf50b
  Author: Zak Ridouh <[email protected]>
  Date:   2026-02-24 (Tue, 24 Feb 2026)

  Changed paths:
    M Source/WebCore/dom/ConstantPropertyMap.cpp
    M Source/WebCore/dom/ConstantPropertyMap.h
    M Source/WebCore/dom/CurrentScriptIncrementer.h
    M Source/WebCore/dom/DOMImplementation.cpp
    M Source/WebCore/dom/DOMImplementation.h
    M Source/WebCore/dom/Document.cpp
    M Source/WebCore/dom/Document.h
    M Source/WebCore/dom/DocumentFontLoader.cpp
    M Source/WebCore/dom/DocumentFontLoader.h
    M Source/WebCore/dom/DocumentMarkerController.cpp
    M Source/WebCore/dom/DocumentMarkerController.h
    M Source/WebCore/dom/DocumentStorageAccess.cpp
    M Source/WebCore/dom/DocumentStorageAccess.h
    M Source/WebCore/dom/EventLoop.cpp
    M Source/WebCore/dom/EventLoop.h
    M Source/WebCore/dom/InternalObserverDrop.cpp
    M Source/WebCore/dom/InternalObserverFilter.cpp
    M Source/WebCore/dom/InternalObserverFirst.cpp
    M Source/WebCore/dom/InternalObserverForEach.cpp
    M Source/WebCore/dom/InternalObserverInspect.cpp
    M Source/WebCore/dom/InternalObserverLast.cpp
    M Source/WebCore/dom/InternalObserverMap.cpp
    M Source/WebCore/dom/InternalObserverReduce.cpp
    M Source/WebCore/dom/InternalObserverSome.cpp
    M Source/WebCore/dom/InternalObserverTake.cpp
    M Source/WebCore/dom/LoadableClassicScript.cpp
    M Source/WebCore/dom/LoadableClassicScript.h
    M Source/WebCore/dom/MessageChannel.cpp
    M Source/WebCore/dom/MessagePort.cpp
    M Source/WebCore/dom/MutationObserver.cpp
    M Source/WebCore/dom/MutationObserverRegistration.h
    M Source/WebCore/dom/NodeIterator.h
    M Source/WebCore/dom/ScriptedAnimationController.cpp
    M Source/WebCore/dom/ScriptedAnimationController.h
    M Source/WebCore/dom/messageports/MessagePortChannelProvider.h
    M Source/WebCore/svg/SVGDocumentExtensions.cpp
    M Source/WebCore/svg/SVGDocumentExtensions.h
    M Source/WebCore/svg/SVGLengthContext.cpp
    M Source/WebCore/svg/SVGLengthContext.h
    M Source/WebCore/svg/SVGTRefElement.cpp
    M Source/WebCore/svg/SVGTRefElement.h
    M Source/WebCore/svg/SVGTests.cpp
    M Source/WebCore/svg/SVGTests.h
    M Source/WebCore/svg/SVGToOTFFontConversion.cpp
    M Source/WebCore/svg/graphics/SVGImageCache.cpp
    M Source/WebCore/svg/graphics/SVGImageCache.h
    M Source/WebCore/svg/graphics/SVGImageForContainer.cpp
    M Source/WebCore/svg/graphics/SVGImageForContainer.h
    M Source/WebCore/xml/DOMParser.cpp
    M Source/WebCore/xml/DOMParser.h
    M Source/WebCore/xml/XMLHttpRequestProgressEventThrottle.cpp
    M Source/WebCore/xml/XMLHttpRequestProgressEventThrottle.h
    M Source/WebCore/xml/parser/XMLDocumentParser.cpp
    M Source/WebCore/xml/parser/XMLDocumentParser.h

  Log Message:
  -----------
  Reduce usage of protectedFoo() style in WebCore/dom, WebCore/xml, and 
WebCore/svg code
https://bugs.webkit.org/show_bug.cgi?id=308379
rdar://170870938

Reviewed by Chris Dumez.

Replace protectedFoo() one-off wrapper methods with the protect()
free function throughout dom/, xml/, and svg/ code

No new tests, as no change in functionality.

* Source/WebCore/dom/ConstantPropertyMap.cpp:
(WebCore::ConstantPropertyMap::didChangeSafeAreaInsets):
(WebCore::ConstantPropertyMap::didChangeFullscreenInsets):
(WebCore::ConstantPropertyMap::setFullscreenAutoHideDuration):
(WebCore::ConstantPropertyMap::protectedDocument const): Deleted.
* Source/WebCore/dom/ConstantPropertyMap.h:
* Source/WebCore/dom/CurrentScriptIncrementer.h:
(WebCore::CurrentScriptIncrementer::CurrentScriptIncrementer):
(WebCore::CurrentScriptIncrementer::~CurrentScriptIncrementer):
(WebCore::CurrentScriptIncrementer::protectedDocument const): Deleted.
* Source/WebCore/dom/DOMImplementation.cpp:
(WebCore::DOMImplementation::createDocumentType):
(WebCore::DOMImplementation::protectedDocument): Deleted.
* Source/WebCore/dom/DOMImplementation.h:
* Source/WebCore/dom/Document.cpp:
(WebCore::Document::setTitle):
(WebCore::Document::updateTitleElement):
(WebCore::Document::protectedTitleElement const): Deleted.
* Source/WebCore/dom/Document.h:
* Source/WebCore/dom/DocumentFontLoader.cpp:
(WebCore::DocumentFontLoader::cachedFont):
(WebCore::DocumentFontLoader::beginLoadingFontSoon):
(WebCore::DocumentFontLoader::loadPendingFonts):
* Source/WebCore/dom/DocumentFontLoader.h:
(WebCore::DocumentFontLoader::protectedDocument const): Deleted.
* Source/WebCore/dom/DocumentMarkerController.cpp:
(WebCore::DocumentMarkerController::updateRectsForInvalidatedMarkersOfType):
(WebCore::DocumentMarkerController::protectedDocument const): Deleted.
* Source/WebCore/dom/DocumentMarkerController.h:
* Source/WebCore/dom/DocumentStorageAccess.cpp:
(WebCore::DocumentStorageAccess::requestStorageAccessForDocumentQuirk):
(WebCore::DocumentStorageAccess::requestStorageAccessQuirk):
(WebCore::DocumentStorageAccess::enableTemporaryTimeUserGesture):
(WebCore::DocumentStorageAccess::protectedDocument const): Deleted.
* Source/WebCore/dom/DocumentStorageAccess.h:
* Source/WebCore/dom/EventLoop.cpp:
(WebCore::EventLoopTaskGroup::queueTask):
(WebCore::EventLoopTaskGroup::queueMicrotask):
(WebCore::EventLoopTaskGroup::scheduleTask):
(WebCore::EventLoopTaskGroup::scheduleRepeatingTask):
(WebCore::EventLoopTaskGroup::protectedEventLoop const): Deleted.
* Source/WebCore/dom/EventLoop.h:
* Source/WebCore/dom/InternalObserverDrop.cpp:
* Source/WebCore/dom/InternalObserverFilter.cpp:
* Source/WebCore/dom/InternalObserverFirst.cpp:
* Source/WebCore/dom/InternalObserverForEach.cpp:
* Source/WebCore/dom/InternalObserverInspect.cpp:
* Source/WebCore/dom/InternalObserverLast.cpp:
* Source/WebCore/dom/InternalObserverMap.cpp:
* Source/WebCore/dom/InternalObserverReduce.cpp:
* Source/WebCore/dom/InternalObserverSome.cpp:
* Source/WebCore/dom/InternalObserverTake.cpp:
* Source/WebCore/dom/LoadableClassicScript.cpp:
(WebCore::LoadableClassicScript::execute):
* Source/WebCore/dom/LoadableClassicScript.h:
(WebCore::LoadableNonModuleScriptBase::cachedScript):
(WebCore::LoadableNonModuleScriptBase::protectedCachedScript): Deleted.
* Source/WebCore/dom/MessageChannel.cpp:
(WebCore::MessageChannel::MessageChannel):
* Source/WebCore/dom/MessagePort.cpp:
(WebCore::MessagePort::entangle):
(WebCore::MessagePort::postMessage):
(WebCore::MessagePort::disentangle):
(WebCore::MessagePort::dispatchMessages):
* Source/WebCore/dom/MutationObserver.cpp:
(WebCore::MutationObserver::disconnect):
* Source/WebCore/dom/MutationObserverRegistration.h:
* Source/WebCore/dom/NodeIterator.h:
* Source/WebCore/dom/ScriptedAnimationController.cpp:
(WebCore::ScriptedAnimationController::cancelCallback):
(WebCore::ScriptedAnimationController::protectedDocument): Deleted.
* Source/WebCore/dom/ScriptedAnimationController.h:
* Source/WebCore/dom/messageports/MessagePortChannelProvider.h:
(WebCore::MessagePortChannelProvider::protectedFromContext): Deleted.
* Source/WebCore/svg/SVGDocumentExtensions.cpp:
(WebCore::SVGDocumentExtensions::unpauseAnimations):
(WebCore::SVGDocumentExtensions::reportWarning):
(WebCore::SVGDocumentExtensions::reportError):
(WebCore::SVGDocumentExtensions::protectedDocument const): Deleted.
* Source/WebCore/svg/SVGDocumentExtensions.h:
* Source/WebCore/svg/SVGLengthContext.cpp:
(WebCore::SVGLengthContext::convertValueFromUserUnitsToEXS const):
(WebCore::SVGLengthContext::convertValueFromEXSToUserUnits const):
(WebCore::SVGLengthContext::computeViewportSize const):
(WebCore::SVGLengthContext::protectedContext const): Deleted.
* Source/WebCore/svg/SVGLengthContext.h:
* Source/WebCore/svg/SVGTRefElement.cpp:
(WebCore::SVGTRefTargetEventListener::handleEvent):
(WebCore::SVGTRefElement::~SVGTRefElement):
(WebCore::SVGTRefElement::detachTarget):
(WebCore::SVGTRefElement::clearTarget):
(WebCore::SVGTRefElement::buildPendingResource):
(WebCore::SVGTRefElement::removedFromAncestor):
(WebCore::SVGTRefElement::protectedTargetListener const): Deleted.
* Source/WebCore/svg/SVGTRefElement.h:
* Source/WebCore/svg/SVGTests.cpp:
(WebCore::SVGTests::conditionalProcessingAttributesIfExists const):
(WebCore::SVGTests::protectedContextElement const): Deleted.
* Source/WebCore/svg/SVGTests.h:
* Source/WebCore/svg/SVGToOTFFontConversion.cpp:
(WebCore::SVGToOTFFontConverter::appendKERNSubtable):
(WebCore::SVGToOTFFontConverter::SVGToOTFFontConverter):
(WebCore::SVGToOTFFontConverter::protectedFontElement const): Deleted.
* Source/WebCore/svg/graphics/SVGImageCache.cpp:
(WebCore::SVGImageCache::setContainerContextForClient):
(WebCore::SVGImageCache::protectedSVGImage const): Deleted.
* Source/WebCore/svg/graphics/SVGImageCache.h:
* Source/WebCore/svg/graphics/SVGImageForContainer.cpp:
(WebCore::SVGImageForContainer::draw):
(WebCore::SVGImageForContainer::drawPattern):
(WebCore::SVGImageForContainer::currentNativeImage):
(WebCore::SVGImageForContainer::protectedImage const): Deleted.
* Source/WebCore/svg/graphics/SVGImageForContainer.h:
* Source/WebCore/xml/DOMParser.cpp:
(WebCore::DOMParser::parseFromString):
* Source/WebCore/xml/DOMParser.h:
(WebCore::DOMParser::protectedContextDocument const): Deleted.
* Source/WebCore/xml/XMLHttpRequestProgressEventThrottle.cpp:
(WebCore::XMLHttpRequestProgressEventThrottle::dispatchProgressEvent):
(WebCore::XMLHttpRequestProgressEventThrottle::dispatchErrorProgressEvent):
(WebCore::XMLHttpRequestProgressEventThrottle::suspend):
(WebCore::XMLHttpRequestProgressEventThrottle::resume):
(WebCore::XMLHttpRequestProgressEventThrottle::protectedTarget): Deleted.
* Source/WebCore/xml/XMLHttpRequestProgressEventThrottle.h:
* Source/WebCore/xml/parser/XMLDocumentParser.cpp:
(WebCore::XMLDocumentParser::createLeafTextNode):
(WebCore::XMLDocumentParser::updateLeafTextNode):
* Source/WebCore/xml/parser/XMLDocumentParser.h:

Canonical link: https://commits.webkit.org/308161@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to