Revert "UI: SCADA symbol editor: fix tag settings tooltip to correctly update add/edit function buttons."
This reverts commit 221e17789a64e7be9814b70389480141e2ec0c43.
This commit is contained in:
parent
0ecc43b088
commit
47ec9496b5
@ -225,8 +225,6 @@ class ScadaSymbolTagPanelComponent extends ScadaSymbolPanelComponent implements
|
|||||||
|
|
||||||
displayTagSettings = true;
|
displayTagSettings = true;
|
||||||
|
|
||||||
private scadaSymbolTagSettingsTooltip: ITooltipsterInstance;
|
|
||||||
|
|
||||||
constructor(public element: ElementRef<HTMLElement>,
|
constructor(public element: ElementRef<HTMLElement>,
|
||||||
private container: ViewContainerRef) {
|
private container: ViewContainerRef) {
|
||||||
super(element);
|
super(element);
|
||||||
@ -244,9 +242,23 @@ class ScadaSymbolTagPanelComponent extends ScadaSymbolPanelComponent implements
|
|||||||
|
|
||||||
if (this.displayTagSettings) {
|
if (this.displayTagSettings) {
|
||||||
const tagSettingsButton = $(this.tagSettingsButton.nativeElement);
|
const tagSettingsButton = $(this.tagSettingsButton.nativeElement);
|
||||||
tagSettingsButton.on('click', () => {
|
tagSettingsButton.tooltipster(
|
||||||
this.createTagSettingsTooltip();
|
{
|
||||||
});
|
parent: this.symbolElement.tooltipContainer,
|
||||||
|
zIndex: 200,
|
||||||
|
arrow: true,
|
||||||
|
theme: ['scada-symbol', 'tb-active'],
|
||||||
|
interactive: true,
|
||||||
|
trigger: 'click',
|
||||||
|
trackOrigin: true,
|
||||||
|
trackerInterval: 100,
|
||||||
|
side: 'top',
|
||||||
|
content: ''
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
const scadaSymbolTagSettingsTooltip = tagSettingsButton.tooltipster('instance');
|
||||||
|
setTooltipComponent(this.symbolElement, this.container, ScadaSymbolTagSettingsComponent, scadaSymbolTagSettingsTooltip);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!this.symbolElement.readonly) {
|
if (!this.symbolElement.readonly) {
|
||||||
@ -283,33 +295,6 @@ class ScadaSymbolTagPanelComponent extends ScadaSymbolPanelComponent implements
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private createTagSettingsTooltip() {
|
|
||||||
if (!this.scadaSymbolTagSettingsTooltip) {
|
|
||||||
const tagSettingsButton = $(this.tagSettingsButton.nativeElement);
|
|
||||||
tagSettingsButton.tooltipster(
|
|
||||||
{
|
|
||||||
parent: this.symbolElement.tooltipContainer,
|
|
||||||
zIndex: 200,
|
|
||||||
arrow: true,
|
|
||||||
theme: ['scada-symbol', 'tb-active'],
|
|
||||||
interactive: true,
|
|
||||||
trigger: 'click',
|
|
||||||
trackOrigin: true,
|
|
||||||
trackerInterval: 100,
|
|
||||||
side: 'top',
|
|
||||||
content: '',
|
|
||||||
functionAfter: () => {
|
|
||||||
this.scadaSymbolTagSettingsTooltip.destroy();
|
|
||||||
this.scadaSymbolTagSettingsTooltip = null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
);
|
|
||||||
this.scadaSymbolTagSettingsTooltip = tagSettingsButton.tooltipster('instance');
|
|
||||||
setTooltipComponent(this.symbolElement, this.container, ScadaSymbolTagSettingsComponent, this.scadaSymbolTagSettingsTooltip);
|
|
||||||
this.scadaSymbolTagSettingsTooltip.open();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public onUpdateTag() {
|
public onUpdateTag() {
|
||||||
this.updateTag.emit();
|
this.updateTag.emit();
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user