|
|
@ -2,11 +2,13 @@ function initAllSwitch() {
|
|
|
|
switchs.forEach(function (element) {
|
|
|
|
switchs.forEach(function (element) {
|
|
|
|
let switche = stage.findOne("#" + element);
|
|
|
|
let switche = stage.findOne("#" + element);
|
|
|
|
switche.on('click', function () {
|
|
|
|
switche.on('click', function () {
|
|
|
|
|
|
|
|
|
|
|
|
let colorrect = switche.fill() == colorSwitchInnactiveBackground ? colorSwitchActiveBackground : colorSwitchInnactiveBackground;
|
|
|
|
let colorrect = switche.fill() == colorSwitchInnactiveBackground ? colorSwitchActiveBackground : colorSwitchInnactiveBackground;
|
|
|
|
switche.fill(colorrect);
|
|
|
|
switche.fill(colorrect);
|
|
|
|
changeLineColor(switche.id3);
|
|
|
|
changeLineColor(switche.id3);
|
|
|
|
checkAllSortieLogique();
|
|
|
|
checkAllSortieLogique();
|
|
|
|
layer.draw();
|
|
|
|
layer.draw();
|
|
|
|
|
|
|
|
checkEnd();
|
|
|
|
});
|
|
|
|
});
|
|
|
|
switche.on('mouseover', function () {
|
|
|
|
switche.on('mouseover', function () {
|
|
|
|
document.body.style.cursor = "pointer";
|
|
|
|
document.body.style.cursor = "pointer";
|
|
|
@ -16,6 +18,7 @@ function initAllSwitch() {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
function initLayer() {
|
|
|
|
function initLayer() {
|
|
|
|
|
|
|
|
|
|
|
|