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

Side by Side Diff: LayoutTests/fast/images/drag-image.html

Issue 886323005: Pass InterpolationQuality into DragImage to respect image-rendering:pixelated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Update test for changes in test_runner CL. Created 5 years, 10 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
« no previous file with comments | « no previous file | LayoutTests/fast/images/drag-image-expected.png » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <style>
3 #image {
4 width: 22px;
5 height: 22px;
6 image-rendering: pixelated;
7 }
8 </style>
9 <body>
10 <!-- Simulate dragging an image and dump the generated drag image. -->
11 <img id="image" src="resources/grid-small.png">
12 </body>
13 <script>
14 function drag() {
15 testRunner.dumpDragImage();
Justin Novosad 2015/02/11 04:30:47 Awesome!
16
17 var image = document.getElementById('image');
18 var startX = image.offsetLeft + image.offsetWidth / 2;
19 var startY = image.offsetTop + image.offsetHeight / 2;
20 var positionX = startX + image.offsetWidth;
21 var positionY = startY + image.offsetHeight;
22
23 eventSender.dragMode = true;
24 eventSender.mouseMoveTo(startX, startY);
25 eventSender.mouseDown();
26 eventSender.mouseMoveTo(positionX, positionY);
27 eventSender.mouseUp();
28 }
29
30 if (!window.testRunner || !window.eventSender) {
31 document.write("This test does not work in manual mode.");
32 } else {
33 window.onload = drag;
34 }
35 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/images/drag-image-expected.png » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698