Restore non-expandable SectionWidget
This commit is contained in:
parent
fe74b80426
commit
5004f0b401
1 changed files with 6 additions and 3 deletions
|
|
@ -53,11 +53,11 @@ namespace MatterHackers.MatterControl.CustomWidgets
|
|||
arrowRight = AggContext.StaticData.LoadIcon("fa-angle-right_12.png", theme.InvertIcons);
|
||||
arrowDown = AggContext.StaticData.LoadIcon("fa-angle-down_12.png", theme.InvertIcons);
|
||||
|
||||
imageButton = new IconButton(arrowRight, theme)
|
||||
imageButton = new IconButton(expandable ? arrowRight : new ImageBuffer(), theme)
|
||||
{
|
||||
MinimumSize = new Vector2((expandable) ? theme.ButtonHeight : 10, theme.ButtonHeight),
|
||||
VAnchor = VAnchor.Center,
|
||||
Selectable = false,
|
||||
Selectable = false
|
||||
};
|
||||
this.AddChild(imageButton);
|
||||
|
||||
|
|
@ -123,7 +123,10 @@ namespace MatterHackers.MatterControl.CustomWidgets
|
|||
{
|
||||
_checked = value;
|
||||
|
||||
imageButton.SetIcon(value ? arrowDown : arrowRight);
|
||||
if (this.Expandable)
|
||||
{
|
||||
imageButton.SetIcon(value ? arrowDown : arrowRight);
|
||||
}
|
||||
|
||||
Invalidate();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue