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

Unified Diff: samples/simplegl/web/gl_driver.dart

Issue 12021025: Merge the openglui samples into one. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix emulator sample build Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « samples/simplegl/web/gl.dart ('k') | samples/simplegl/web/raytrace.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/simplegl/web/gl_driver.dart
diff --git a/samples/simplegl/web/gl_driver.dart b/samples/simplegl/web/gl_driver.dart
deleted file mode 100644
index a18da4fe816d279bde15663091563c69a55cb188..0000000000000000000000000000000000000000
--- a/samples/simplegl/web/gl_driver.dart
+++ /dev/null
@@ -1,37 +0,0 @@
-// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-library gl_driver;
-
-import 'dart:html';
-import 'gl.dart';
-
-/**
- * A driver to run GL applications in the browser.
- */
-void glMain(setup, resize, draw) {
- // Setup a Canvas for GL to run inside.
- final canvas = new CanvasElement(width: window.innerWidth, height: window.innerHeight);
- document.body.nodes.add(canvas);
-
- gl = canvas.getContext('experimental-webgl');
-
- // The first 'setup' entry point is called once.
- setup(canvas.width, canvas.height);
-
- // The second 'render' entry point is called each time the canvas should
- // be re-drawn.
- var render;
- render = (n) {
- draw();
- window.requestAnimationFrame(render);
- };
- render(0);
-
- window.on.resize.add((e) {
- canvas.width = window.innerWidth;
- canvas.height = window.innerHeight;
- resize(canvas.width, canvas.height);
- });
-}
« no previous file with comments | « samples/simplegl/web/gl.dart ('k') | samples/simplegl/web/raytrace.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698