2011-02-04 Daniel Cheng <dcheng@chromium.org>
Reviewed by Dmitry Titov.
Clone WebClipboard to be frame-specific.
https://bugs.webkit.org/show_bug.cgi?id=53727
For drop operations, Chrome currently snapshots the data and copies it
into the renderer process. As we add more supported drag data types, the
copy will become increasingly expensive. Instead, we'd like to snapshot
data in the browser to reduce the amount of data copied and to support
Blob in DataTransferItem. In order to allow this, we associated
WebClipboard with a frame so it can correctly route its IPCs to the
corresponding Chromium host.
No new tests because no new functionality.
* platform/chromium/ChromiumDataObject.cpp:
(WebCore::ChromiumDataObject::createReadable):
* platform/chromium/ChromiumDataObject.h:
* platform/chromium/ClipboardChromium.cpp:
(WebCore::ClipboardChromium::create):
* platform/chromium/PlatformBridge.h:
* platform/chromium/ReadableDataObject.cpp:
(WebCore::ReadableDataObject::create):
(WebCore::ReadableDataObject::ReadableDataObject):
(WebCore::ReadableDataObject::getData):
(WebCore::ReadableDataObject::urlTitle):
(WebCore::ReadableDataObject::htmlBaseUrl):
(WebCore::ReadableDataObject::filenames):
(WebCore::ReadableDataObject::ensureTypeCacheInitialized):
* platform/chromium/ReadableDataObject.h:
2011-02-04 Daniel Cheng <dcheng@chromium.org>
Reviewed by Dmitry Titov.
Clone WebClipboard to be frame-specific.
https://bugs.webkit.org/show_bug.cgi?id=53727
For drop operations, Chrome currently snapshots the data and copies it
into the renderer process. As we add more supported drag data types, the
copy will become increasingly expensive. Instead, we'd like to snapshot
data in the browser to reduce the amount of data copied and to support
Blob in DataTransferItem. In order to allow this, we associated
WebClipboard with a frame so it can correctly route its IPCs to the
corresponding Chromium host.
* public/WebFrameClient.h:
(WebKit::WebFrameClient::clipboard):
* src/PlatformBridge.cpp:
(WebCore::getClipboard):
(WebCore::PlatformBridge::clipboardReadAvailableTypes):
(WebCore::PlatformBridge::clipboardReadData):
(WebCore::PlatformBridge::clipboardReadFilenames):
* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::fromFrame):
* src/WebFrameImpl.h:
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::dragTargetDragEnterNew):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@77687
268f45cc-cd09-0410-ab3c-
d52691b4dbfc