Commit dc5fa7a6 authored by bweinstein@apple.com's avatar bweinstein@apple.com

Prep work for: Crash under WebPage::platformDragEnded when dragging on Mac

https://bugs.webkit.org/show_bug.cgi?id=64766
<rdar://problem/9548174>
        
Reviewed by Darin Adler.

Add a DragClient function that is called when a drag is ended, and call it from DragController::dragEnded.
This isn't used yet, but will be used by WebKit2 on Mac.
        
This patch also cleans up style in DragClient.h.

No change in behavior, no tests needed.

* page/DragClient.h:
(WebCore::DragClient::dragEnded): Stub virtual implementation for now, this will be used by
    WebKit2 on Mac.
* page/DragController.cpp:
(WebCore::DragController::dragEnded): Call DragClient::dragEnded.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@91222 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent f63be00a
2011-07-18 Brian Weinstein <bweinstein@apple.com>
Prep work for: Crash under WebPage::platformDragEnded when dragging on Mac
https://bugs.webkit.org/show_bug.cgi?id=64766
<rdar://problem/9548174>
Reviewed by Darin Adler.
Add a DragClient function that is called when a drag is ended, and call it from DragController::dragEnded.
This isn't used yet, but will be used by WebKit2 on Mac.
This patch also cleans up style in DragClient.h.
No change in behavior, no tests needed.
* page/DragClient.h:
(WebCore::DragClient::dragEnded): Stub virtual implementation for now, this will be used by
WebKit2 on Mac.
* page/DragController.cpp:
(WebCore::DragController::dragEnded): Call DragClient::dragEnded.
2011-07-18 Jon Honeycutt <jhoneycutt@apple.com>
Focus and selection events are not fired when a <select>'s selection
......@@ -58,20 +58,23 @@ namespace WebCore {
virtual void willPerformDragDestinationAction(DragDestinationAction, DragData*) = 0;
virtual void willPerformDragSourceAction(DragSourceAction, const IntPoint&, Clipboard*) = 0;
virtual DragDestinationAction actionMaskForDrag(DragData*) = 0;
//We work in window rather than view coordinates here
// We work in window rather than view coordinates here.
virtual DragSourceAction dragSourceActionMaskForPoint(const IntPoint& windowPoint) = 0;
virtual void startDrag(DragImageRef dragImage, const IntPoint& dragImageOrigin, const IntPoint& eventPos, Clipboard*, Frame*, bool linkDrag = false) = 0;
virtual void dragControllerDestroyed() = 0;
#if PLATFORM(MAC)
//Mac specific helper functions to allow access to functionality in webkit -- such as
//web archives and NSPasteboard extras
//not abstract as that would require another #if PLATFORM(MAC) for the SVGImage client empty impl
virtual void declareAndWriteDragImage(NSPasteboard*, DOMElement*, NSURL*, NSString*, Frame*) {};
// Mac-specific helper function to allow access to web archives and NSPasteboard extras in WebKit.
// This is not abstract as that would require another #if PLATFORM(MAC) for the SVGImage client empty implentation.
virtual void declareAndWriteDragImage(NSPasteboard *, DOMElement*, NSURL *, NSString *, Frame*) { }
#endif
virtual ~DragClient() {};
virtual void dragEnded() { }
virtual ~DragClient() { }
};
}
......
......@@ -158,6 +158,8 @@ void DragController::dragEnded()
m_dragInitiator = 0;
m_didInitiateDrag = false;
m_page->dragCaretController()->clear();
m_client->dragEnded();
}
DragOperation DragController::dragEntered(DragData* dragData)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment