• darin@apple.com's avatar
    2011-03-11 Darin Adler <darin@apple.com> · caf9248c
    darin@apple.com authored
            Reviewed by Sam Weinig.
    
            Dragging image to desktop gives webloc instead of image file in WebKit2
            https://bugs.webkit.org/show_bug.cgi?id=56193
    
            * WebCore.exp.in: Added some additional exports. Re-sorted.
    2011-03-11  Darin Adler  <darin@apple.com>
    
            Reviewed by Sam Weinig.
    
            Dragging image to desktop gives webloc instead of image file in WebKit2
            https://bugs.webkit.org/show_bug.cgi?id=56193
    
            * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
            (WebKit::convertImageToBitmap): Added. Factored out from startDrag to
            make the startDrag code clearer.
            (WebKit::WebDragClient::startDrag): Streamlined code a bit.
            (WebKit::cachedImage): Added. Helper for function below.
            (WebKit::arrayForURLsWithTitles): Added. Helper for function below.
            (WebKit::WebDragClient::declareAndWriteDragImage): Added code to handle file
            promises and removed a log of uneeded code.
            (-[WKPasteboardFilePromiseOwner copyDropDirectory]): Added.
            (promisedDataClient): Added.
            (-[WKPasteboardOwner clearImage]): Added.
            (-[WKPasteboardOwner initWithImage:]): Added.
            (-[WKPasteboardOwner dealloc]): Added.
            (-[WKPasteboardOwner finalize]): Added.
            (-[WKPasteboardOwner pasteboard:provideDataForType:]): Added.
            (-[WKPasteboardOwner pasteboardChangedOwner:]): Added.
            (matchesExtensionOrEquivalent): Added.
            (-[WKPasteboardOwner namesOfPromisedFilesDroppedAtDestination:]): Added.
            Much of the new code above came from the WebKit1 drag code.
    
            * WebProcess/WebPage/WebPage.cpp:
            (WebKit::WebPage::dragEnded): Added call to Mac-only platformDragEnded.
            * WebProcess/WebPage/WebPage.h: Added Mac-only platformDragEnded and m_dragSource.
            * WebProcess/WebPage/mac/WebPageMac.mm:
            (WebKit::WebPage::setDragSource): Added.
            (WebKit::WebPage::platformDragEnded): Added.
    
    
    git-svn-id: svn://svn.chromium.org/blink/trunk@80948 bbb929c8-8fbe-4397-9dbb-9b2b20218538
    caf9248c
ChangeLog 227 KB