Commit 417e64f3c93971adae00d9f0a138d8ad3c9fcda3

Authored by xp.Huang
2 parents 0eef5f3a f157160d

Merge branch 'fix/DEFECT-1355' into 'main_dev'

fix: DEFECT-1355修复根据平台信息设置的网页徽标使用错误

See merge request yunteng/thingskit-scada!79
... ... @@ -614,7 +614,7 @@
614 614 if (platfromInfo.logo) {
615 615 const icoLink = document.querySelectorAll('link[rel*="ico"]')
616 616 icoLink.forEach(item => {
617   - item.setAttribute('href', platfromInfo.logo)
  617 + item.setAttribute('href', platfromInfo.icon)
618 618 })
619 619 }
620 620
... ...
... ... @@ -2579,28 +2579,28 @@ EditorUi.prototype.initCanvas = function()
2579 2579 }), Editor.zoomInImage, mxResources.get('zoomIn') + ' (Alt+Mousewheel)');
2580 2580
2581 2581 // TODO thingsKit 隐藏自适应按钮
2582   - // addButton(mxUtils.bind(this, function(evt)
2583   - // {
2584   - // if (graph.isLightboxView())
2585   - // {
2586   - // if (graph.view.scale == 1)
2587   - // {
2588   - // this.lightboxFit();
2589   - // }
2590   - // else
2591   - // {
2592   - // graph.zoomTo(1);
2593   - // }
  2582 + addButton(mxUtils.bind(this, function(evt)
  2583 + {
  2584 + if (graph.isLightboxView())
  2585 + {
  2586 + if (graph.view.scale == 1)
  2587 + {
  2588 + this.lightboxFit();
  2589 + }
  2590 + else
  2591 + {
  2592 + graph.zoomTo(1);
  2593 + }
2594 2594
2595   - // this.chromelessResize(false);
2596   - // }
2597   - // else
2598   - // {
2599   - // this.chromelessResize(true);
2600   - // }
  2595 + this.chromelessResize(false);
  2596 + }
  2597 + else
  2598 + {
  2599 + this.chromelessResize(true);
  2600 + }
2601 2601
2602   - // mxEvent.consume(evt);
2603   - // }), Editor.zoomFitImage, mxResources.get('fit'));
  2602 + mxEvent.consume(evt);
  2603 + }), Editor.zoomFitImage, mxResources.get('fit'));
2604 2604
2605 2605 // Changes toolbar opacity on hover
2606 2606 var fadeThread = null;
... ...