mirror of
https://github.com/octoleo/syncthing.git
synced 2025-02-02 11:58:28 +00:00
gui: Load modals before calling initController() (fixes #3301)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3319
This commit is contained in:
parent
b779e22205
commit
55fc3cb2c5
@ -67,6 +67,9 @@ angular.module('syncthing.core')
|
|||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// inform syncthingContoller that a modal is ready
|
||||||
|
scope.$parent.modalLoaded();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
@ -221,9 +221,7 @@ angular.module('syncthing.core')
|
|||||||
document.cookie = "firstVisit=" + Date.now() + ";max-age=" + 30 * 24 * 3600;
|
document.cookie = "firstVisit=" + Date.now() + ";max-age=" + 30 * 24 * 3600;
|
||||||
} else {
|
} else {
|
||||||
if (+firstVisit < Date.now() - 4 * 3600 * 1000) {
|
if (+firstVisit < Date.now() - 4 * 3600 * 1000) {
|
||||||
setTimeout(function () {
|
$('#ur').modal();
|
||||||
$('#ur').modal();
|
|
||||||
}, 2500);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1623,6 +1621,14 @@ angular.module('syncthing.core')
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// pseudo main. called on all definitions assigned
|
$scope.modalLoaded = function () {
|
||||||
initController();
|
|
||||||
|
// once all modal elements have been processed
|
||||||
|
if ($('modal').length === 0) {
|
||||||
|
|
||||||
|
// pseudo main. called on all definitions assigned
|
||||||
|
initController();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user