Host editor panel in BottomResizeContainer

- Issue MatterHackers/MCCentral#3424
This commit is contained in:
John Lewin 2018-05-22 13:40:13 -07:00
parent 7c29214d20
commit 2602fef4c7
2 changed files with 8 additions and 4 deletions

View file

@ -86,10 +86,11 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
this.AddChild(scrollable);
var editorColumn = new FlowLayoutWidget(FlowDirection.TopToBottom)
var editorColumn = new BottomResizeContainer(theme)
{
HAnchor = HAnchor.Stretch,
VAnchor = VAnchor.Fit
VAnchor = VAnchor.Absolute,
Height = 250 //////////////////////// Load persisted user value
};
var toolbar = new Toolbar(theme)
@ -199,6 +200,9 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
if (editorSection.Children.FirstOrDefault() is ExpandCheckboxButton checkbox)
{
checkbox.ReplaceChild(checkbox.Children[1], inlineTitleEdit);
// Override default constructor behavior - force back to Absolute after add
editorSection.ContentPanel.VAnchor = VAnchor.Absolute;
}
this.ContentPanel.AddChild(editorSection);

View file

@ -184,9 +184,9 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
treeSection = new BottomResizeContainer(theme)
{
HAnchor = HAnchor.Stretch,
VAnchor = VAnchor.Absolute
VAnchor = VAnchor.Absolute,
Height = 250 //////////////////////// Load persisted user value
};
treeSection.Height = 250; //////////////////////// Load persisted user value
modelViewSidePanel.AddChild(treeSection);
// add the tree view