summaryrefslogtreecommitdiffstats
path: root/o3d
diff options
context:
space:
mode:
authorgman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-15 10:26:59 +0000
committergman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-15 10:26:59 +0000
commitbf9c004226d2c830367f442aa6068d67319d21c8 (patch)
tree1e1cfb8547631fc04bef3337c0982c368f959220 /o3d
parent104f8da823407fec983b5cbabcd94425c5c2daa9 (diff)
downloadchromium_src-bf9c004226d2c830367f442aa6068d67319d21c8.zip
chromium_src-bf9c004226d2c830367f442aa6068d67319d21c8.tar.gz
chromium_src-bf9c004226d2c830367f442aa6068d67319d21c8.tar.bz2
Fix o3djs.loader.loadScene so it has opt_options argument.
Review URL: http://codereview.chromium.org/118366 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18378 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'o3d')
-rw-r--r--o3d/samples/o3djs/loader.js16
1 files changed, 10 insertions, 6 deletions
diff --git a/o3d/samples/o3djs/loader.js b/o3d/samples/o3djs/loader.js
index abfd1d9..6a8760b2 100644
--- a/o3d/samples/o3djs/loader.js
+++ b/o3d/samples/o3djs/loader.js
@@ -116,6 +116,8 @@ o3djs.loader.Loader.prototype.loadTexture = function(pack,
* @param {!o3d.Pack} pack Pack to load texture into.
* @param {!o3d.Transform} parent Transform to parent scene under.
* @param {string} url URL of scene to load.
+ * @param {!o3djs.serialization.Options} opt_options Options passed into the
+ * loader.
* @param {!function(!o3d.Pack, !o3d.Transform, *): void}
* opt_onSceneLoaded optional callback when scene is loaded. It will be
* passed the pack and parent and an exception which is null on success.
@@ -124,16 +126,18 @@ o3djs.loader.Loader.prototype.loadScene = function(client,
pack,
parent,
url,
- opt_onSceneLoaded) {
+ opt_onSceneLoaded,
+ opt_options) {
var that = this; // so the function below can see "this".
++this.count_;
var loadInfo = o3djs.scene.loadScene(
client, pack, parent, url, function(pack, parent, exception) {
- if (opt_onSceneLoaded) {
- opt_onSceneLoaded(pack, parent, exception);
- }
- that.countDown_();
- });
+ if (opt_onSceneLoaded) {
+ opt_onSceneLoaded(pack, parent, exception);
+ }
+ that.countDown_();
+ },
+ opt_options);
this.loadInfo.addChild(loadInfo);
};