- Fixed some tooltip regressions
- Defined signatures where necessary
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using FlaxEditor.Scripting;
|
||||
using FlaxEditor.Surface.Elements;
|
||||
using FlaxEditor.Utilities;
|
||||
@@ -62,7 +63,7 @@ namespace FlaxEditor.Surface.ContextMenu
|
||||
Group = group;
|
||||
_groupArchetype = groupArchetype;
|
||||
_archetype = archetype;
|
||||
TooltipText = $"{_archetype.Signature}\n{_archetype.Description}";
|
||||
TooltipText = GetTooltip();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -323,6 +324,15 @@ namespace FlaxEditor.Surface.ContextMenu
|
||||
Group.ContextMenu.SetDescriptionPanelArchetype(_archetype);
|
||||
}
|
||||
|
||||
private string GetTooltip()
|
||||
{
|
||||
StringBuilder sb = new StringBuilder();
|
||||
if (!string.IsNullOrEmpty(_archetype.Signature))
|
||||
sb.Append(_archetype.Signature + "\n");
|
||||
sb.Append(_archetype.Description);
|
||||
return sb.ToString();
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override bool OnMouseDown(Float2 location, MouseButton button)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user