Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | <!DOCTYPE HTML> |
michael@0 | 2 | <html> |
michael@0 | 3 | <head> |
michael@0 | 4 | <meta charset="utf-8"> |
michael@0 | 5 | <title>Test for canvas drawWindow</title> |
michael@0 | 6 | <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script> |
michael@0 | 7 | <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/WindowSnapshot.js"></script> |
michael@0 | 8 | <script type="application/javascript" src="file_drawWindow_common.js"></script> |
michael@0 | 9 | <link rel="stylesheet" type="text/css" href="chrome://mochikit/content/tests/SimpleTest/test.css"/> |
michael@0 | 10 | <script type="application/javascript"> |
michael@0 | 11 | |
michael@0 | 12 | SimpleTest.waitForExplicitFinish(); |
michael@0 | 13 | window.addEventListener("load", openSourceWindow, false); |
michael@0 | 14 | |
michael@0 | 15 | var sourceWindow; |
michael@0 | 16 | |
michael@0 | 17 | function openSourceWindow(event) { |
michael@0 | 18 | if (event.target != document) { |
michael@0 | 19 | return; |
michael@0 | 20 | } |
michael@0 | 21 | |
michael@0 | 22 | // Need to open as a toplevel chrome window so that |
michael@0 | 23 | // DRAWWINDOW_USE_WIDGET_LAYERS is honored. |
michael@0 | 24 | sourceWindow = window.open("file_drawWindow_source.html", "", |
michael@0 | 25 | "chrome,width=200,height=100"); |
michael@0 | 26 | sourceWindow.addEventListener("load", runTests, false); |
michael@0 | 27 | } |
michael@0 | 28 | |
michael@0 | 29 | function runTests(event) { |
michael@0 | 30 | if (event.target != sourceWindow.document) { |
michael@0 | 31 | return; |
michael@0 | 32 | } |
michael@0 | 33 | |
michael@0 | 34 | var cxInterfaceWrap = SpecialPowers.wrap(CanvasRenderingContext2D); |
michael@0 | 35 | var flags = cxInterfaceWrap.DRAWWINDOW_USE_WIDGET_LAYERS | |
michael@0 | 36 | cxInterfaceWrap.DRAWWINDOW_DRAW_CARET | |
michael@0 | 37 | cxInterfaceWrap.DRAWWINDOW_DRAW_VIEW; |
michael@0 | 38 | runDrawWindowTests(sourceWindow, flags, true); |
michael@0 | 39 | |
michael@0 | 40 | sourceWindow.close(); |
michael@0 | 41 | |
michael@0 | 42 | SimpleTest.finish(); |
michael@0 | 43 | } |
michael@0 | 44 | |
michael@0 | 45 | </script> |
michael@0 | 46 | </head> |
michael@0 | 47 | <body> |
michael@0 | 48 | <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=">Mozilla Bug </a> |
michael@0 | 49 | </body> |
michael@0 | 50 | </html> |