Description of problem: When adding entities with GuideMe menu, when we get to configure storage tooltip appears that cannot be dismissed until storage is added. Version-Release number of selected component (if applicable): 4.1.0-0.0.master.20161117231327.gitdbe2e8a.el7.centos.noarch How reproducible: 100% Steps to Reproduce: 1. Click Guide Me 2. Click Configure Storage in the last step Actual results: Tooltip appears ', There should be at least 1 active host in the datacenter' even if there are active hosts. Expected results: Should appear only on hover over
Greg, please also check if 4.0 is affected.
This is a typical issue that happens with tooltips. They are hidden when the mouse leaves an element. If you click and the click caused the element to leave the page, there is no way for the mouse to leave the element -- the element is gone. To solve this in the past, IIRC, we globally listened for clicks and hid all tooltips upon any click. @Vojtech, do you recall seeing this? How would you like me to approach solving this?
(In reply to Greg Sheremeta from comment #2) > This is a typical issue that happens with tooltips. They are hidden when the > mouse leaves an element. If you click and the click caused the element to > leave the page, there is no way for the mouse to leave the element -- the > element is gone. > > To solve this in the past, IIRC, we globally listened for clicks and hid all > tooltips upon any click. Before tooltip refactor, we had a global (GWT RootPanel) click handler to hide all tooltip instances, see [1] line 425. [1] https://gerrit.ovirt.org/#/c/65566/17/frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/widget/tooltip/Tooltip.java We need to add similar behavior to post-tooltip-refactor code. > @Vojtech, do you recall seeing this? How would you like me to approach > solving this? One approach is to add equivalent global click handler that calls ElementTooltipUtils#hideAllTooltips. [Note that `hideAllTooltips` only affects tooltips whose DOM elements are currently attached to live DOM.] Another approach is to modify WidgetTooltip: in decorateWidget method, add widget click handler that calls WidgetTooltip#hide. I'd suggest to go with the former approach, which covers all kinds of tooltips (both ones created directly via ElementTooltipUtils & ones created via WidgetTooltip). The class to host relevant code should reside in ElementTooltipUtils. [Also, please use RootLayoutPanel instead of RootPanel.] Example code: // ElementTooltipUtils.java public static class TooltipHideOnRootPanelClick { public TooltipHideOnRootPanelClick() { RootLayoutPanel.get().addDomHandler(new ClickHandler() { @Override public void onClick(ClickEvent event) { ElementTooltipUtils.hideAllTooltips(); } }, ClickEvent.getType()); } } To put above code into effect, bind it as eager singleton: // BaseSystemModule.java bind(ElementTooltipUtils.TooltipHideOnRootPanelClick.class).asEagerSingleton();
*** Bug 1401581 has been marked as a duplicate of this bug. ***
ok, ovirt-engine-webadmin-portal-4.1.0-0.4.master.20170111151514.git3d62579.el7.centos.noarch