Skip to content

Commit

Permalink
Bugfix hidden expand nodes taking space
Browse files Browse the repository at this point in the history
  • Loading branch information
Soaku committed Aug 28, 2021
1 parent e77123d commit 8203ffb
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions source/glui/space.d
Expand Up @@ -93,8 +93,8 @@ class GluiSpace : GluiNode {
GluiNode[] nodeList;
foreach (child; children) {

// This node expands
if (child.layout.expand) {
// This node expands and isn't hidden
if (child.layout.expand && !child.hidden) {

// Append
nodeList ~= child;
Expand Down Expand Up @@ -231,6 +231,9 @@ class GluiSpace : GluiNode {
/// available = Available space
private Vector2 childSpace(const GluiNode child, Vector2 available) const {

// Hidden, give it no space
if (child.hidden) return Vector2();

// Horizontal
if (directionHorizontal) {

Expand Down

0 comments on commit 8203ffb

Please sign in to comment.