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

Side by Side Diff: chrome/test/data/drag_and_drop/page.html

Issue 2478583005: Browser tests for starting a drag-and-drop out of an OOPIF. (Closed)
Patch Set: Should work on Windows and ChromeOS now. Created 4 years, 1 month 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
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <!-- Page to help with testing of drag-and-drop scenarios. 2 <!-- Page to help with testing of drag-and-drop scenarios.
3 3
4 Left frame is at (100,100) to (299,299) coordinates. 4 Left frame is at (100,100) to (299,299) coordinates.
5 Right frame is at (300,100) to (499,299) coordinates. 5 Right frame is at (300,100) to (499,299) coordinates.
6
7 Left frame will load whatever is specified in "left"
8 query parameter (similarily for right frame and "right").
9 Example:
10 .../mouse-tests/page.html?left=image_source.html&right=drop_target.html
11 --> 6 -->
12 <head> 7 <head>
13 <meta charset="utf-8"> 8 <meta charset="utf-8">
14 <style> 9 <style>
15 iframe { 10 iframe {
16 position: absolute; 11 position: absolute;
17 top: 100px; 12 top: 100px;
18 width: 200px; 13 width: 200px;
19 height: 200px; 14 height: 200px;
20 border: 0px; 15 border: 0px;
21 margin: 0px; 16 margin: 0px;
22 padding: 0px; 17 padding: 0px;
23 } 18 }
24 #left { left: 100px; background: green; } 19 #left { left: 100px; background: green; }
25 #right { left: 300px; background: cyan; } 20 #right { left: 300px; background: cyan; }
26 </style> 21 </style>
27 </head> 22 </head>
28 <body> 23 <body>
29 <iframe id="left" name="left" srcdoc="blank left frame"></iframe> 24 <iframe id="left" name="left" srcdoc="<body>blank left frame</body>"></iframe>
30 <iframe id="right" name="right" srcdoc="blank right frame"></iframe> 25 <iframe id="right" name="right" srcdoc="<body>blank right frame</body>"></ifra me>
31 <script>
32 function navigateFrame(id) {
33 var query = new URLSearchParams(window.location.search);
34 if (!query.has(id)) return;
35
36 var url = query.get(id);
37 if (!url) return;
38
39 console.log("Navigating " + id + " to " + url);
40 var frame = document.getElementById(id);
41 frame.contentWindow.location.href = url;
42 }
43 navigateFrame("left");
44 navigateFrame("right");
45 </script>
Łukasz Anforowicz 2016/11/10 19:26:24 This got removed, because navigating from within C
46 </body> 26 </body>
OLDNEW
« no previous file with comments | « chrome/test/data/drag_and_drop/image_source.html ('k') | content/browser/frame_host/frame_tree_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698