});\r
},\r
hideSplash: function() {\r
+ console.log('hide splash');\r
if ($("#splash").length == 0) {\r
return;\r
}\r
var $this = this;\r
setTimeout(function() {\r
+ $this._hideSplash();\r
try {\r
navigator.splashscreen.hide();\r
} catch (err) {\r
\r
}\r
- $this._hideSplash();\r
}, 3000);\r
},\r
_hideSplash: function() {\r
that.regenerate(callback);
};
- console.log('fs init');
-
// Callback when the filesystem API has granted quota
var quotaCallback = function(grantedBytes) {
var persistent = LocalFileSystem.PERSISTENT;
var that = this;
// And then recreate it
var fs = this.fs;
-
- console.log('regenerate');
-
createDir_(fs.root, ROOT_DIR.split('/'), function(res) {
// Create a directory for the root of the GAL
fs.root.getDirectory(ROOT_DIR, {create: true}, function(dirEntry) {
that.root = dirEntry;
- console.log('root created');
callback();
}, onError);
});
var that = this;
// Start by downloading the first bundle, then download subsequent ones.
(function loop(bundleIndex) {
- console.log(bundleIndex);
if (bundleIndex == that.bundleOrder.length) {
// We're done downloading stuff!
return;
}
- console.log('cordova ready');
- console.log(fsprefix);
- console.log(manifest);
-
if (navigator.onLine && manifest) {
var readyToLoad = false;
var finishedLoading = false;
gal = new GameAssetLoader(JSON.parse(manifest), fsprefix);
- console.log(gal);
gal.init(function() {
- console.log('gal inited');
startAfterLoading = true;
init();
});
gal.onLoaded(function(info) {
+ console.log('loaded ' + info.bundleName);
$(window).trigger('GALBundleLoaded', [info]);
});
} catch (err) {
}
-
-
});
- console.log('gal waiting...');
} else {
init();
}