mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-09-25 11:16:51 +00:00
Frame initialization exceptions
Don't call initialize inside the try-catch, it ends up sending exceptions thrown inside that method to /dev/null. Change-Id: I8e0945f35c639ec156ee9a163b86fddfaed0ea7b
This commit is contained in:
parent
93cb630aed
commit
bb232a0ee7
|
@ -95,13 +95,16 @@ ve.ui.Frame.prototype.onLoad = function () {
|
||||||
try {
|
try {
|
||||||
// MAGIC: only accessible when the stylesheet is loaded
|
// MAGIC: only accessible when the stylesheet is loaded
|
||||||
rules = style.sheet.cssRules;
|
rules = style.sheet.cssRules;
|
||||||
// If that didn't throw an exception, we're done loading
|
} catch ( e ) {
|
||||||
clearInterval( interval );
|
// Try again in 10ms
|
||||||
// Protect against IE running interval one extra time after clearing
|
return;
|
||||||
if ( !this.initialized ) {
|
}
|
||||||
initialize();
|
// If that didn't throw an exception, we're done loading
|
||||||
}
|
clearInterval( interval );
|
||||||
} catch ( e ) { }
|
// Protect against IE running interval one extra time after clearing
|
||||||
|
if ( !this.initialized ) {
|
||||||
|
initialize();
|
||||||
|
}
|
||||||
}, this ), 10 );
|
}, this ), 10 );
|
||||||
|
|
||||||
// Properties
|
// Properties
|
||||||
|
|
Loading…
Reference in a new issue