This commit is contained in:
j 2011-04-23 01:15:43 +02:00
parent 0d5de4332f
commit 68d1861671

View file

@ -45,11 +45,11 @@
Ox.UI = {}; Ox.UI = {};
Ox.UI.ready = function(callback) { Ox.UI.ready = function(callback) {
if (!ready) { if (!ready) {
readyCallbacks.push(callback); readyCallbacks.push(callback);
} else { } else {
callback(); callback();
} }
}; };
$(function() { $(function() {
Ox.UI.$body = $('body'); Ox.UI.$body = $('body');
@ -99,7 +99,7 @@
var sizes = { var sizes = {
small: 20, small: 20,
medium: 24, medium: 24,
large: 28, large: 28
}; };
return sizes[size]; return sizes[size];
}; };
@ -176,10 +176,7 @@
var dfd = new $.Deferred(); var dfd = new $.Deferred();
var script = document.createElement('script'); var script = document.createElement('script');
script.onload = function() { script.onload = function() {
//setTimeout(function() { dfd.resolve();
console.log('onload', src)
dfd.resolve();
//}, 1000)
}; };
script.src = Ox.UI.PATH + src; script.src = Ox.UI.PATH + src;
script.type = 'text/javascript'; script.type = 'text/javascript';
@ -191,7 +188,7 @@
promises = []; promises = [];
// fixme: find a better way to not wait for flags // fixme: find a better way to not wait for flags
data = data.filter(function(image) { data = data.filter(function(image) {
return !Ox.startsWith(image, 'svg/ox.map/') return !Ox.startsWith(image, 'svg/ox.map/');
}); });
data.forEach(function(src) { data.forEach(function(src) {
if (/\.js$/(src)) { if (/\.js$/(src)) {