Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(74)

Unified Diff: content/browser/renderer_host/clipboard_message_filter.cc

Issue 9921018: Added RTF support to pepper API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/renderer_host/clipboard_message_filter.h ('k') | content/common/clipboard_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/clipboard_message_filter.cc
diff --git a/content/browser/renderer_host/clipboard_message_filter.cc b/content/browser/renderer_host/clipboard_message_filter.cc
index f8592273741201b7d51109540de21ee43f5cbe98..25b2fd7ad4e110aca6a7e99e3ebf0de947d07708 100644
--- a/content/browser/renderer_host/clipboard_message_filter.cc
+++ b/content/browser/renderer_host/clipboard_message_filter.cc
@@ -73,6 +73,7 @@ bool ClipboardMessageFilter::OnMessageReceived(const IPC::Message& message,
IPC_MESSAGE_HANDLER(ClipboardHostMsg_ReadText, OnReadText)
IPC_MESSAGE_HANDLER(ClipboardHostMsg_ReadAsciiText, OnReadAsciiText)
IPC_MESSAGE_HANDLER(ClipboardHostMsg_ReadHTML, OnReadHTML)
+ IPC_MESSAGE_HANDLER(ClipboardHostMsg_ReadRTF, OnReadRTF)
IPC_MESSAGE_HANDLER_DELAY_REPLY(ClipboardHostMsg_ReadImage, OnReadImage)
IPC_MESSAGE_HANDLER(ClipboardHostMsg_ReadCustomData, OnReadCustomData)
#if defined(OS_MACOSX)
@@ -179,6 +180,11 @@ void ClipboardMessageFilter::OnReadHTML(
*url = GURL(src_url_str);
}
+void ClipboardMessageFilter::OnReadRTF(
+ ui::Clipboard::Buffer buffer, std::string* result) {
+ GetClipboard()->ReadRTF(buffer, result);
+}
+
void ClipboardMessageFilter::OnReadImage(
ui::Clipboard::Buffer buffer, IPC::Message* reply_msg) {
SkBitmap bitmap = GetClipboard()->ReadImage(buffer);
« no previous file with comments | « content/browser/renderer_host/clipboard_message_filter.h ('k') | content/common/clipboard_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698