diff --git a/Source/Editor/Windows/Search/SearchItem.cs b/Source/Editor/Windows/Search/SearchItem.cs index 5336c2855..4d610159e 100644 --- a/Source/Editor/Windows/Search/SearchItem.cs +++ b/Source/Editor/Windows/Search/SearchItem.cs @@ -20,6 +20,11 @@ namespace FlaxEditor.Windows.Search /// protected Image _icon; + /// + /// The color of the accent strip. + /// + protected Color _accentColor; + /// /// The item name. /// @@ -56,7 +61,7 @@ namespace FlaxEditor.Windows.Search var icon = new Image { Size = new Float2(logoSize), - Location = new Float2(5, (height - logoSize) / 2) + Location = new Float2(7, (height - logoSize) / 2) }; _icon = icon; @@ -146,6 +151,7 @@ namespace FlaxEditor.Windows.Search { _asset = item; _asset.AddReference(this); + _accentColor = Editor.Instance.ContentDatabase.GetProxy(item).AccentColor; } /// @@ -228,6 +234,10 @@ namespace FlaxEditor.Windows.Search // Draw icon var iconRect = _icon.Bounds; _asset.DrawThumbnail(ref iconRect); + + // Draw icon color strip + var rect = iconRect with { Width = 2, Height = Height, Location = Float2.Zero }; + Render2D.FillRectangle(rect, _accentColor); } ///