Changing to await able create methods
issue: MatterHackers/MCCentral#4966 async Rebuild calls must be awaited in Create methods
This commit is contained in:
parent
457e31ef10
commit
a055192700
18 changed files with 88 additions and 86 deletions
|
|
@ -58,7 +58,7 @@ namespace MatterHackers.MatterControl.DesignTools.Operations
|
|||
}
|
||||
}
|
||||
|
||||
public static TranslateObject3D Create(IObject3D itemToTranslate)
|
||||
public static async Task<TranslateObject3D> Create(IObject3D itemToTranslate)
|
||||
{
|
||||
var translate = new TranslateObject3D();
|
||||
var aabb = itemToTranslate.GetAxisAlignedBoundingBox();
|
||||
|
|
@ -67,6 +67,8 @@ namespace MatterHackers.MatterControl.DesignTools.Operations
|
|||
translate.Children.Add(translateItem);
|
||||
translateItem.Children.Add(itemToTranslate);
|
||||
|
||||
await translate.Rebuild();
|
||||
|
||||
return translate;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue