summaryrefslogtreecommitdiffstats
path: root/webkit/glue/chromium_bridge_impl.cc
diff options
context:
space:
mode:
authortc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-08 19:58:25 +0000
committertc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-08 19:58:25 +0000
commita2c257166578102f6874dace42dcbbfdb1441231 (patch)
tree7abee6a1303a1d67929be32b28c5a36ea5be921a /webkit/glue/chromium_bridge_impl.cc
parentb715cb38fd23cb3abb0b09df35cd0ac6076e7332 (diff)
downloadchromium_src-a2c257166578102f6874dace42dcbbfdb1441231.zip
chromium_src-a2c257166578102f6874dace42dcbbfdb1441231.tar.gz
chromium_src-a2c257166578102f6874dace42dcbbfdb1441231.tar.bz2
Only copy image data to the clipboard when users select
"Copy Image" from the context menu. BUG=1176 Review URL: http://codereview.chromium.org/13253 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6531 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/chromium_bridge_impl.cc')
-rw-r--r--webkit/glue/chromium_bridge_impl.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/webkit/glue/chromium_bridge_impl.cc b/webkit/glue/chromium_bridge_impl.cc
index 8ebba8d..d13d866 100644
--- a/webkit/glue/chromium_bridge_impl.cc
+++ b/webkit/glue/chromium_bridge_impl.cc
@@ -186,9 +186,13 @@ void ChromiumBridge::clipboardWriteImage(const NativeImageSkia* bitmap,
GURL gurl = webkit_glue::KURLToGURL(url);
scw.WriteBookmark(webkit_glue::StringToStdWString(title), gurl.spec());
+#if defined(OS_MACOSX) || defined(OS_LINUX)
+ // We intentionally don't write HTML or text to the clipboard on Windows
+ // because some apps prefer HTML or text to the image data but we want the
+ // image data to take priority.
scw.WriteHTML(UrlToImageMarkup(url, title), "");
-
scw.WriteText(ASCIIToWide(gurl.spec()));
+#endif
}
}