Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

port opengl demo to new chromeless events

  • Loading branch information...
commit 76c9035dc4670e71ef5649b0ac30654de7ddd99f 1 parent 05cf280
@lloyd lloyd authored
Showing with 5 additions and 8 deletions.
  1. +5 −8 examples/webgl/index.html
View
13 examples/webgl/index.html
@@ -1,4 +1,4 @@
-<html>
+ <html>
<head>
<title>WebGL Demo</title>
@@ -45,14 +45,11 @@
function launchBrowser() {
myBrowser = document.createElement("iframe");
- require("iframe-as-browser").bind(myBrowser,document);
- myBrowser.addEventListener("experimental-dom-progress", function (e) {
- if(e.percentage>=100) {
- thumbnailUpdate();
- }
+ myBrowser.addEventListener("ChromelessLoadStop", function (e) {
+ thumbnailUpdate();
},false);
document.body.appendChild(myBrowser);
- myBrowser.src = "http://www.google.com/";
+ myBrowser.src = "http://mozillalabs.com/chromeless";
}
function thumbnailUpdate() {
@@ -70,7 +67,7 @@
//document.body.appendChild(gThumbImageRef);
}
/* We do this because we need a 64x64 picture even to make a
- texture, required by the webgl demo */
+ * texture, required by the webgl demo */
var square = document.createElement("canvas");
ctx = square.getContext("2d");
Please sign in to comment.
Something went wrong with that request. Please try again.