Przeglądaj źródła

透明度修改

haojianlong 4 lat temu
rodzic
commit
629e9db6f9

+ 3 - 3
src/components/floorMap/index.vue

@@ -386,7 +386,7 @@ export default {
         },
         getEvent() {
             bus.$on('changeShow', res => {
-                this.topologyParser.zoneLegendList.forEach(t => {
+                this.topologyParser && this.topologyParser.zoneLegendList.forEach(t => {
                     let id = t.data.GraphElementId
                     t.maskFlag = !(res.indexOf(id) > -1)
                 })
@@ -402,11 +402,11 @@ export default {
                 //     let id = t.data.GraphElementId
                 //     t.maskFlag = !(res.indexOf(id) > -1)
                 // })
-                this.topologyParser.imageLegendList.forEach(t => {
+                this.topologyParser && this.topologyParser.imageLegendList.forEach(t => {
                     let id = t.data.GraphElementId
                     t.maskFlag = !(res.indexOf(id) > -1)
                 })
-                this.topologyParser.relationList.forEach(t => {
+                this.topologyParser && this.topologyParser.relationList.forEach(t => {
                     let id = t.data.GraphElementId || t.data.GraphElementID
                     t.maskFlag = !(res.indexOf(id) > -1)
                 })

+ 3 - 3
src/lib/items/SFHFQZoneLegendItem.ts

@@ -230,12 +230,12 @@ export class SFHFQZoneLegendItem extends SPolygonItem {
     onDraw(painter: SPainter) {
         if (this.maskFlag && this.status == SItemStatus.Normal) {
             let color = new SColor(this.strokeColor)
-            color.alpha = color.alpha / 2
+            color.alpha = color.alpha / 5
             let brushcolor = new SColor(this.fillColor)
-            brushcolor.alpha = brushcolor.alpha / 2
+            brushcolor.alpha = brushcolor.alpha / 5
             painter.pen.color = color
             painter.pen.lineCapStyle = SLineCapStyle.Square
-            painter.pen.lineWidth = painter.toPx(this._lineWidth)
+            painter.pen.lineWidth = painter.toPx(this.lineWidth)
             painter.brush.color = brushcolor
             if (this.selected) {
                 painter.pen.lineWidth = painter.toPx(this.lineWidth * 2);

+ 3 - 3
src/lib/items/SSCPZZoneLegendItem.ts

@@ -238,12 +238,12 @@ export class SSCPZZoneLegendItem extends SPolygonItem {
     onDraw(painter: SPainter) {
         if (this.maskFlag && this.status == SItemStatus.Normal) {
             let color = new SColor(this.strokeColor)
-            color.alpha = color.alpha / 2
+            color.alpha = color.alpha / 5
             let brushcolor = new SColor(this.fillColor)
-            brushcolor.alpha = brushcolor.alpha / 2
+            brushcolor.alpha = brushcolor.alpha / 5
             painter.pen.color = color
             painter.pen.lineCapStyle = SLineCapStyle.Square
-            painter.pen.lineWidth = painter.toPx(this._lineWidth)
+            painter.pen.lineWidth = painter.toPx(this.lineWidth)
             painter.brush.color = brushcolor
             if (this.selected) {
                 painter.pen.lineWidth = painter.toPx(this.lineWidth * 2);

+ 3 - 3
src/lib/items/SZoneLegendItem.ts

@@ -231,12 +231,12 @@ export class SZoneLegendItem extends SPolygonItem {
     onDraw(painter: SPainter) {
         if (this.maskFlag && this.status == SItemStatus.Normal) {
             let color = new SColor(this.strokeColor)
-            color.alpha = color.alpha / 2
+            color.alpha = color.alpha / 5
             let brushcolor = new SColor(this.fillColor)
-            brushcolor.alpha = brushcolor.alpha / 2
+            brushcolor.alpha = brushcolor.alpha / 5
             painter.pen.color = color
             painter.pen.lineCapStyle = SLineCapStyle.Square
-            painter.pen.lineWidth = painter.toPx(this._lineWidth)
+            painter.pen.lineWidth = painter.toPx(this.lineWidth)
             painter.brush.color = brushcolor
             if (this.selected) {
                 painter.pen.lineWidth = painter.toPx(this.lineWidth * 2);