Skip to content

Commit

Permalink
Fix compile error (#9)
Browse files Browse the repository at this point in the history
* Fix compile error for Quixel Bridge

Widget SizeHint is not longer accessible

* Convert assets to a list so collection isn't modified during enumeration
  • Loading branch information
trundlr authored May 29, 2023
1 parent 2f97edc commit 5b73450
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .addon
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,7 @@
"ResourcePaths": null,
"HasCode": true,
"CodePath": "/code/",
"PackageReferences": [],
"EditorReferences": null,
"Metadata": {}
}
3 changes: 2 additions & 1 deletion code/BridgeImporter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ public async Task ImportFrom( BridgeAsset quixelAsset )
var mdlPath = Path.Join( relativePath, $"{quixelAsset.Name.ToSourceName()}_{quixelAsset.Id}.vmdl" );

// Locate imported s&box asset
var engineAsset = AssetSystem.All.FirstOrDefault( x => x.Path.NormalizeFilename() == mdlPath.NormalizeFilename() );
var assets = AssetSystem.All.ToList();
var engineAsset = assets.FirstOrDefault( x => x.Path.NormalizeFilename() == mdlPath.NormalizeFilename() );

if ( engineAsset == null )
{
Expand Down
1 change: 0 additions & 1 deletion code/Progress/ProgressWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ protected override void DoLayout()
base.DoLayout();

Content.Size = Size;
Content.Height = Content.Children.Where( x => x.Visible ).Sum( x => MathF.Max( x.SizeHint.y, x.MinimumSize.y ) + 1 ) - 1;

Content.Position = new Vector2( 0, MenuWidget.Height );
Size = Content.Position + Content.Size + new Vector2( 0, 4 );
Expand Down

0 comments on commit 5b73450

Please sign in to comment.