kopia lustrzana https://github.com/c9/core
Set state before firing event
Otherwise e.g. preview won't work yet in tabs.on("ready")pull/248/head
rodzic
6c632543c1
commit
b52cca8bc3
|
@ -220,13 +220,14 @@ define(function(require, module, exports) {
|
||||||
}
|
}
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
// Only set the state if we're not testing something else
|
var wasReady = isReady;
|
||||||
if (options.testing != 2 && !isReady) {
|
isReady = true;
|
||||||
|
if (options.testing != 2 && !wasReady) {
|
||||||
|
// Only fire if we're not testing something else
|
||||||
setState(state, !isReady, function(){
|
setState(state, !isReady, function(){
|
||||||
emit.sticky("ready");
|
emit.sticky("ready");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
isReady = true;
|
|
||||||
|
|
||||||
showTabs = settings.getBool("user/tabs/@show");
|
showTabs = settings.getBool("user/tabs/@show");
|
||||||
toggleButtons(showTabs);
|
toggleButtons(showTabs);
|
||||||
|
|
Ładowanie…
Reference in New Issue