less code is more better
This commit is contained in:
@@ -142,7 +142,6 @@ namespace FlaxEditor.Windows
|
|||||||
private string _cacheFolder;
|
private string _cacheFolder;
|
||||||
private AssetItem _item;
|
private AssetItem _item;
|
||||||
private Surface _surface;
|
private Surface _surface;
|
||||||
private AssetNode _rootAssetNode;
|
|
||||||
private Label _loadingLabel;
|
private Label _loadingLabel;
|
||||||
private CancellationTokenSource _token;
|
private CancellationTokenSource _token;
|
||||||
private Task _task;
|
private Task _task;
|
||||||
@@ -196,9 +195,6 @@ namespace FlaxEditor.Windows
|
|||||||
var node = new AssetNode((uint)_nodes.Count + 1, _surface.Context, GraphNodes[0], GraphGroups[0], assetId);
|
var node = new AssetNode((uint)_nodes.Count + 1, _surface.Context, GraphNodes[0], GraphGroups[0], assetId);
|
||||||
_nodes.Add(node);
|
_nodes.Add(node);
|
||||||
|
|
||||||
if (assetId == _item.ID)
|
|
||||||
_rootAssetNode = node;
|
|
||||||
|
|
||||||
return node;
|
return node;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -406,12 +402,9 @@ namespace FlaxEditor.Windows
|
|||||||
return;
|
return;
|
||||||
_progress = 100.0f;
|
_progress = 100.0f;
|
||||||
|
|
||||||
if (_rootAssetNode != null)
|
var commentRect = assetNode.EditorBounds;
|
||||||
{
|
commentRect.Expand(80f);
|
||||||
var commentRect = _rootAssetNode.EditorBounds;
|
_surface.Context.CreateComment(ref commentRect, _item.ShortName, Color.Green);
|
||||||
commentRect.Expand(80f);
|
|
||||||
_surface.Context.CreateComment(ref commentRect, _item.ShortName, Color.Green);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update UI
|
// Update UI
|
||||||
FlaxEngine.Scripting.InvokeOnUpdate(() =>
|
FlaxEngine.Scripting.InvokeOnUpdate(() =>
|
||||||
|
|||||||
Reference in New Issue
Block a user