Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor some image drag and drop codepaths
https://bugs.webkit.org/show_bug.cgi?id=245058 rdar://98992054 Reviewed by Ryosuke Niwa. Refactor some codepaths related to dragging and dropping images. * Source/WebCore/dom/DataTransfer.cpp: (WebCore::DataTransfer::types const): (WebCore::DataTransfer::filesFromPasteboardAndItemList const): * Source/WebCore/dom/DataTransfer.h: (WebCore::DataTransfer::allowsFileAccess const): * Source/WebCore/page/DragController.cpp: (WebCore::DragController::dragEntered): (WebCore::DragController::dragExited): (WebCore::DragController::dragUpdated): (WebCore::DragController::performDragOperation): (WebCore::DragController::dragEnteredOrUpdated): (WebCore::DragController::disallowFileAccessIfNeeded): * Source/WebCore/page/DragController.h: * Source/WebCore/page/DragState.h: * Source/WebCore/page/EventHandler.cpp: (WebCore::EventHandler::canDropCurrentlyDraggedImageAsFile const): (WebCore::EventHandler::handleDrag): * Source/WebCore/page/EventHandler.h: * Source/WebCore/page/SecurityOrigin.cpp: (WebCore::SecurityOrigin::canReceiveDragData const): * Source/WebCore/platform/DragData.cpp: (WebCore::DragData::disallowFileAccess): * Source/WebCore/platform/DragData.h: * Source/WebCore/platform/cocoa/DragDataCocoa.mm: (WebCore::DragData::containsFiles const): (WebCore::DragData::numberOfFiles const): (WebCore::DragData::asFilenames const): (WebCore::DragData::containsCompatibleContent const): (WebCore::DragData::containsPromise const): * Source/WebKit/WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::performDragControllerAction): * Source/WebKit/WebProcess/WebPage/WebPage.h: * Source/WebKitLegacy/mac/WebView/WebView.mm: (-[WebView _enteredDataInteraction:client:global:operation:]): (-[WebView _updatedDataInteraction:client:global:operation:]): (-[WebView _exitedDataInteraction:client:global:operation:]): (-[WebView _tryToPerformDataInteraction:client:global:operation:]): (-[WebView draggingEntered:]): (-[WebView draggingUpdated:]): (-[WebView draggingExited:]): (-[WebView performDragOperation:]): * Source/WebKitLegacy/win/WebView.cpp: (WebView::DragEnter): (WebView::DragOver): (WebView::DragLeave): (WebView::Drop): Use `WTFMove()` when handing the `DragData` over to `DragController`. * Tools/TestWebKitAPI/Tests/WebKitCocoa/DragAndDropTests.mm: Canonical link: https://commits.webkit.org/254380@main
- Loading branch information
Showing
16 changed files
with
101 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.