| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <title>Test for crbug.com/190880</title> | 2 <title>Test for crbug.com/190880</title> |
| 3 <script src="resources/text-based-repaint.js"></script> | 3 <script src="resources/text-based-repaint.js"></script> |
| 4 <style> | 4 <style> |
| 5 video { width: 700px; } | 5 video { width: 700px; } |
| 6 </style> | 6 </style> |
| 7 | 7 |
| 8 <video id="v" controls autoload src="../../media/content/test.ogv"> | 8 <video id="v" controls autoload src="../../media/content/test.ogv"> |
| 9 </video> | 9 </video> |
| 10 | 10 |
| 11 <p>This tests that we repaint the mute button when we change the volume</p> | 11 <p>This tests that we repaint the mute button when we change the volume</p> |
| 12 | 12 |
| 13 <script> | 13 <script> |
| 14 // Disable under-invalidation checking because we allow short period of |
| 15 // under-invalidation of buffered ranges. |
| 16 if (window.internals) |
| 17 internals.runtimeFlags.paintUnderInvalidationCheckingEnabled = false; |
| 18 |
| 14 window.testIsAsync = true; | 19 window.testIsAsync = true; |
| 15 | 20 |
| 16 var video = document.getElementById("v"); | 21 var video = document.getElementById("v"); |
| 17 video.addEventListener("canplaythrough", runTest, true); | 22 video.addEventListener("canplaythrough", runTest, true); |
| 18 function repaintTest() { | 23 function repaintTest() { |
| 19 video.volume = 0.5; | 24 video.volume = 0.5; |
| 20 finishRepaintTest(); | 25 finishRepaintTest(); |
| 21 } | 26 } |
| 22 | 27 |
| 23 function runTest() { | 28 function runTest() { |
| 24 video.volume = 0; | 29 video.volume = 0; |
| 25 runRepaintTest(); | 30 runRepaintTest(); |
| 26 } | 31 } |
| 27 </script> | 32 </script> |
| OLD | NEW |