Skip to content
  • enrica@apple.com's avatar
    Refactor DragData class to use PlatformStrategies in the Mac implementation. · 1a0e7a68
    enrica@apple.com authored
    https://bugs.webkit.org/show_bug.cgi?id=78768
    
    Reviewed by Darin Adler.
    
    Source/WebCore: 
    
    No new tests. No behavior change.
    
    * WebCore.exp.in: Added new exported method of the PlatformPasteboard class.
    * platform/DragData.h:
    (WebCore::DragData::pasteboardName): Added pasteboardName and removed pasteboard.
    * platform/PasteboardStrategy.h: Added color() method.
    * platform/PlatformPasteboard.h: Ditto.
    * platform/mac/ClipboardMac.mm:
    (WebCore::Clipboard::create): Changed to use pasteboardName() method.
    * platform/mac/DragDataMac.mm: All the methods below have been changed to use pasteboardName
    and the pasteboardStrategy() methods.
    (WebCore::DragData::DragData):
    (WebCore::DragData::canSmartReplace):
    (WebCore::DragData::containsColor):
    (WebCore::DragData::containsFiles):
    (WebCore::DragData::numberOfFiles):
    (WebCore::DragData::asFilenames):
    (WebCore::DragData::containsPlainText):
    (WebCore::DragData::asPlainText):
    (WebCore::DragData::asColor):
    (WebCore::DragData::containsCompatibleContent):
    (WebCore::DragData::asURL):
    (WebCore::DragData::asFragment):
    * platform/mac/PlatformPasteboardMac.mm:
    (WebCore::PlatformPasteboard::color): Added implementation of the color() method.
    
    Source/WebKit/mac: 
    
    * WebCoreSupport/WebPlatformStrategies.h: Added color() method.
    * WebCoreSupport/WebPlatformStrategies.mm:
    (WebPlatformStrategies::color):
    
    Source/WebKit2: 
    
    * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp: Added color() method.
    (WebKit::WebPlatformStrategies::color):
    * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@108101 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    1a0e7a68