zc故障灯状态修改

This commit is contained in:
joylink_cuiweidong 2020-07-07 10:00:55 +08:00
parent 421e591f52
commit 92da104ad0
4 changed files with 21 additions and 3 deletions

View File

@ -494,7 +494,8 @@ class SkinCode extends defaultStyle {
},
lamp: {
radiusR: 6, // 灯大小
controlColor: '#00FF00' // 灯颜色
controlColor: '#00FF00', // 灯颜色
activeColor:'#ff0000' // 控制灯激活颜色
},
mouseOverStyle: {
fontSize: 10,

View File

@ -449,7 +449,8 @@ class SkinCode extends defaultStyle {
},
lamp: {
radiusR: 6, // 控制灯大小
controlColor: '#00FF00' // 控制灯颜色
controlColor: '#00FF00', // 控制灯颜色
activeColor:'#ff0000' // 控制灯激活颜色
}
};

View File

@ -487,7 +487,8 @@ class SkinCode extends defaultStyle {
},
lamp: {
radiusR: 6, // 控制灯大小
controlColor: '#00FF00' // 控制灯颜色
controlColor: '#00FF00', // 控制灯颜色
activeColor:'#ff0000' // 控制灯激活颜色
}
};

View File

@ -61,8 +61,23 @@ export default class ZcControl extends Group {
// 设置状态
setState(model) {
this.recover();
model.fault == 'FAULT' && this.fault();
if (!this.isShowShape) return;
}
recover() {
if (this.style.ZcControl.visible) {
this.control.setControlColor(this.style.ZcControl.lamp.controlColor);
}
}
fault() {
if (this.style.ZcControl.visible) {
this.control.setControlColor(this.style.ZcControl.lamp.activeColor);
}
}
createMouseEvent() {
if (this.style.ZcControl.mouseOverStyle) {
this.mouseEvent = new EMouse(this);