Add default values to Fade Effect

Without default values readConfig returns undefined values
causing the effect not to work. This needs to be documented.
This commit is contained in:
Martin Gräßlin 2012-04-09 11:25:31 +02:00
parent 84a6891d79
commit 7c00ab45f7

View file

@ -33,9 +33,9 @@ function isLoginWindow(w) {
var fadeInTime, fadeOutTime, fadeWindows;
function loadConfig() {
fadeInTime = animationTime(effect.readConfig("FadeInTime"));
fadeOutTime = animationTime(effect.readConfig("FadeOutTime"));
fadeWindows = effect.readConfig("FadeWindows");
fadeInTime = animationTime(effect.readConfig("FadeInTime", 150));
fadeOutTime = animationTime(effect.readConfig("FadeOutTime", 150));
fadeWindows = effect.readConfig("FadeWindows", true);
}
loadConfig();
effect.configChanged.connect(function() {