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

Side by Side Diff: chrome/test/data/extensions/canvas/background.html

Issue 9624013: Re-enable extension GPU features (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove AURA qualifier Created 8 years, 9 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 <html>
Aaron Boodman 2012/03/09 01:00:06 Add a license header.
Josh Horwich 2012/03/09 01:21:56 Will do
Josh Horwich 2012/03/09 02:26:25 Done.
2 <head>
3 <title>Background page using 2d canvas</title>
4 </head>
5 <body>
6 <div>Below should be a canvas rendered with canvas2D</div>
7 <canvas id="my-canvas" width="100" height="100"></canvas>
8 <script type="application/javascript">
9 var succeeded = false;
10 function test() {
11 if (succeeded) {
12 window.domAutomationController.send(true);
13 } else {
14 window.domAutomationController.send(false);
15 }
16 }
17
18 canvas = document.getElementById("my-canvas");
19 if (canvas) {
20 if (canvas.getContext) {
21 context = canvas.getContext("2d");
22 if (context) {
23 context.fillStyle = 'red';
24 context.fillRect(20, 20, 40, 40);
25 succeeded = true;
26 }
27 }
28 }
29 </script>
30 </body>
31 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698