haikuwebkit/Source/WebCore/PAL/pal/mac
Wenson Hsieh 3c06249705 [macOS] Move DataDetectors softlinking in DataDetectorsSPI.h out into a separate PAL header
https://bugs.webkit.org/show_bug.cgi?id=226669

Reviewed by Sam Weinig.

Source/WebCore:

Clean up some softlinking code for the DataDetectors framework. Currently, the `SOFT_LINK_*` macros are defined
inside the SPI header (`pal/spi/mac/DataDetectorsSPI.h`); this patch moves them out into
`pal/mac/DataDetectorsSoftLink.{h|mm}` instead, and updates a few places that use these soft-linked symbols to
import `DataDetectorsSoftLink.h` instead of `DataDetectorsSPI.h`.

* editing/cocoa/DataDetection.mm:
(WebCore::detectItem):
(WebCore::DataDetection::detectItemAroundHitTestResult):
* page/mac/ImageOverlayControllerMac.mm:
(WebCore::ImageOverlayController::updateDataDetectorHighlights):
(WebCore::ImageOverlayController::platformHandleMouseEvent):
* page/mac/ServicesOverlayController.mm:
(WebCore::ServicesOverlayController::mouseIsOverHighlight const):
(WebCore::ServicesOverlayController::buildPhoneNumberHighlights):
(WebCore::ServicesOverlayController::buildSelectionHighlight):
* platform/mac/DataDetectorHighlight.mm:
(WebCore::DataDetectorHighlight::setHighlight):
(WebCore::DataDetectorHighlight::paintContents):

Source/WebCore/PAL:

Add the new softlinking headers. See WebCore/ChangeLog for more details.

* PAL.xcodeproj/project.pbxproj:
* pal/PlatformMac.cmake:
* pal/cocoa/DataDetectorsCoreSoftLink.h:
* pal/cocoa/DataDetectorsCoreSoftLink.mm:

Move the `DDBinderPhoneNumberKey` soft link into `DataDetectorsCoreSoftLink` instead, since this symbol comes
from DataDetectorsCore rather than the DataDetectors framework.

* pal/mac/DataDetectorsSoftLink.h: Added.
* pal/mac/DataDetectorsSoftLink.mm: Added.
* pal/mac/QuickLookUISoftLink.h:
* pal/spi/mac/DataDetectorsSPI.h:

Source/WebKit:

Adopt the new PAL softlinking header in a few places. See WebCore/ChangeLog for more details. Additionally, move
several softlinking header imports so that they're the last imported headers in a few sources.

* Platform/mac/MenuUtilities.mm:
(WebKit::actionForMenuItem):
(WebKit::menuItemForTelephoneNumber):
* Shared/Cocoa/DataDetectionResult.mm:
(WebKit::DataDetectionResult::decode):
* Shared/ios/InteractionInformationAtPosition.mm:
(WebKit::InteractionInformationAtPosition::decode):
* Shared/mac/WebHitTestResultData.mm:
(WebKit::WebHitTestResultData::platformDecode):
* UIProcess/Cocoa/WebViewImpl.mm:
(WebKit::WebViewImpl::dismissContentRelativeChildWindowsFromViewOnly):
* UIProcess/mac/WKImmediateActionController.mm:
(-[WKImmediateActionController _clearImmediateActionState]):
(-[WKImmediateActionController immediateActionRecognizerWillBeginAnimation:]):
(-[WKImmediateActionController _animationControllerForDataDetectedText]):
(-[WKImmediateActionController _animationControllerForDataDetectedLink]):

Source/WebKitLegacy/mac:

Adopt the new PAL softlinking header in a few places. See WebCore/ChangeLog for more details.

* WebView/WebImmediateActionController.mm:
(-[WebImmediateActionController _clearImmediateActionState]):
(-[WebImmediateActionController immediateActionRecognizerWillBeginAnimation:]):
(-[WebImmediateActionController _animationControllerForDataDetectedText]):
(-[WebImmediateActionController _animationControllerForDataDetectedLink]):


Canonical link: https://commits.webkit.org/238528@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@278530 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-06-06 01:18:09 +00:00
..
DataDetectorsSoftLink.h
DataDetectorsSoftLink.mm
LookupSoftLink.h
LookupSoftLink.mm
QuickLookUISoftLink.h
QuickLookUISoftLink.mm