mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-12-24 01:09:23 +01:00
also don't display the tooltip if all o its children are hidden
This commit is contained in:
parent
fde243ed8b
commit
eeedb0ae5c
1 changed files with 1 additions and 1 deletions
|
@ -40,7 +40,7 @@ namespace MLEM.Ui.Elements {
|
|||
if (elementToHover != null) {
|
||||
elementToHover.OnMouseEnter += element => {
|
||||
// only display the tooltip if there is anything in it
|
||||
if (!this.Children.Any())
|
||||
if (this.Children.All(c => c.IsHidden))
|
||||
return;
|
||||
element.System.Add(element.GetType().Name + "Tooltip", this);
|
||||
this.SnapPositionToMouse();
|
||||
|
|
Loading…
Reference in a new issue