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

Side by Side Diff: content/test/data/paste_listener.html

Issue 2146323002: Expose RTF content on the clipboard as strings to pages when pasting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: BrowserTestClipboardScope. Created 4 years, 5 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 unified diff | Download patch
OLDNEW
(Empty)
1 <title>Waiting for paste</title>
2 <body>
3 <script>
4 document.body.contentEditable = true;
5 document.body.addEventListener('paste', (event) => {
6 Array.prototype.forEach.call(event.clipboardData.items, (item) => {
7 if (item.type != 'text/rtf') {
8 return;
9 }
10 item.getAsString((s) => {
11 document.title = s;
12 });
13 });
14 });
15 </script>
OLDNEW
« no previous file with comments | « content/renderer/webclipboard_impl_browsertest.cc ('k') | third_party/WebKit/Source/core/clipboard/DataObjectItem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698