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

Unified Diff: webkit/plugins/ppapi/ppb_flash_impl.cc

Issue 10539028: Only paste the fragment of text which was copied to the clipboard. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: . Created 8 years, 6 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 | « ui/base/dragdrop/os_exchange_data_win_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_flash_impl.cc
diff --git a/webkit/plugins/ppapi/ppb_flash_impl.cc b/webkit/plugins/ppapi/ppb_flash_impl.cc
index aa911d72502ef314fffa3c791f1c81c8345a2897..f2c33270bdefeb4b35f86e2c3322f4c8195ed567 100644
--- a/webkit/plugins/ppapi/ppb_flash_impl.cc
+++ b/webkit/plugins/ppapi/ppb_flash_impl.cc
@@ -326,16 +326,17 @@ PP_Var PPB_Flash_Impl::ReadClipboardData(
return PP_MakeNull();
}
case PP_FLASH_CLIPBOARD_FORMAT_HTML: {
- string16 html_stdstr;
+ string16 html;
GURL gurl;
uint32 fragment_start;
uint32 fragment_end;
clipboard_client_->ReadHTML(buffer_type,
- &html_stdstr,
+ &html,
&gurl,
&fragment_start,
&fragment_end);
- return StringVar::StringToPPVar(UTF16ToUTF8(html_stdstr));
+ return StringVar::StringToPPVar(UTF16ToUTF8(
+ html.substr(fragment_start, fragment_end - fragment_start)));
}
case PP_FLASH_CLIPBOARD_FORMAT_RTF: {
std::string result;
« no previous file with comments | « ui/base/dragdrop/os_exchange_data_win_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698