Fix timing problem with Jax startup sequence so that the required array can be modified in the Config method (as it is in the HTML-CSS jax). This resolves a timing ising with IE
This commit is contained in:
parent
065acfd10a
commit
45dd111fe9
File diff suppressed because one or more lines are too long
|
@ -30,7 +30,7 @@ if (!window.MathJax) {window.MathJax= {}}
|
||||||
if (!MathJax.Hub) { // skip if already loaded
|
if (!MathJax.Hub) { // skip if already loaded
|
||||||
|
|
||||||
MathJax.version = "1.1a";
|
MathJax.version = "1.1a";
|
||||||
MathJax.fileversion = "1.1.6";
|
MathJax.fileversion = "1.1.7";
|
||||||
|
|
||||||
/**********************************************************/
|
/**********************************************************/
|
||||||
|
|
||||||
|
@ -1794,21 +1794,17 @@ MathJax.Hub.Startup = {
|
||||||
Startup: function () {},
|
Startup: function () {},
|
||||||
loadComplete: function (file) {
|
loadComplete: function (file) {
|
||||||
if (file === "config.js") {
|
if (file === "config.js") {
|
||||||
return AJAX.loadComplete(this.directory+"/"+file);
|
AJAX.loadComplete(this.directory+"/"+file);
|
||||||
} else {
|
} else {
|
||||||
var queue = CALLBACK.Queue();
|
var queue = CALLBACK.Queue();
|
||||||
queue.Push(
|
queue.Push(
|
||||||
HUB.Register.StartupHook("End Config",{}), // wait until config complete
|
HUB.Register.StartupHook("End Config",{}), // wait until config complete
|
||||||
["Post",HUB.Startup.signal,this.id+" Jax Config"],
|
["Post",HUB.Startup.signal,this.id+" Jax Config"],
|
||||||
["Config",this],
|
["Config",this],
|
||||||
["Post",HUB.Startup.signal,this.id+" Jax Require"]
|
["Post",HUB.Startup.signal,this.id+" Jax Require"],
|
||||||
);
|
// Config may set the required and extensions array,
|
||||||
if (this.require) {
|
// so use functions to delay making the reference until needed
|
||||||
var require = this.require; if (!(require instanceof Array)) {require = [require]}
|
[function (THIS) {return MathJax.Hub.Startup.loadArray(THIS.require,this.directory)},this],
|
||||||
for (var i = 0, m = require.length; i < m; i++) {queue.Push(AJAX.Require(require[i]))}
|
|
||||||
}
|
|
||||||
return queue.Push(
|
|
||||||
// Config may set the extensions, so use a function to delay making the reference
|
|
||||||
[function (config,id) {return MathJax.Hub.Startup.loadArray(config.extensions,"extensions/"+id)},this.config||{},this.id],
|
[function (config,id) {return MathJax.Hub.Startup.loadArray(config.extensions,"extensions/"+id)},this.config||{},this.id],
|
||||||
["Post",HUB.Startup.signal,this.id+" Jax Startup"],
|
["Post",HUB.Startup.signal,this.id+" Jax Startup"],
|
||||||
["Startup",this],
|
["Startup",this],
|
||||||
|
|
Loading…
Reference in New Issue
Block a user