Package com.badlogic.gdx.scenes.scene2d

Examples of com.badlogic.gdx.scenes.scene2d.Layout.layout()


      actor.width = width;
      actor.height = height;
      if (actor instanceof Layout) {
        Layout layout = (Layout)actor;
        layout.invalidate();
        layout.layout();
      }
    }
  }

  public void draw (SpriteBatch batch, float parentAlpha) {
View Full Code Here


      widget.width = widgetWidth;
      widget.height = widgetHeight;
      if (widget instanceof Layout) {
        Layout layout = (Layout)widget;
        layout.invalidate();
        layout.layout();
      }
    }

    // Set the bounds and scroll knob sizes if scrollbars are needed.
    if (hasHScroll) {
View Full Code Here

    if (!needsLayout) return;
    needsLayout = false;
    if (widget instanceof Layout) {
      Layout layout = (Layout)widget;
      layout.invalidate();
      layout.layout();
    }
  }

  @Override
  public void invalidate () {
View Full Code Here

      actor.width = c.getWidgetWidth();
      actor.height = widgetHeight;
      if (actor instanceof Layout) {
        Layout layout = (Layout)actor;
        layout.invalidate();
        layout.layout();
      }
    }
  }

  /** Invalidates the layout, forcing the next call to {@link #layout()} to relayout. If a widget is resized or otherwise changed
View Full Code Here

    if (!invalidated) return;
    invalidated = false;

    if (firstWidget instanceof Layout) {
      Layout layout = (Layout)firstWidget;
      layout.layout();
      firstWidget.width = layout.getPrefWidth();
      firstWidget.height = layout.getPrefHeight();
    }
    if (secondWidget instanceof Layout) {
      Layout layout = (Layout)secondWidget;
View Full Code Here

      firstWidget.width = layout.getPrefWidth();
      firstWidget.height = layout.getPrefHeight();
    }
    if (secondWidget instanceof Layout) {
      Layout layout = (Layout)secondWidget;
      layout.layout();
      secondWidget.width = layout.getPrefWidth();
      secondWidget.height = layout.getPrefHeight();
    }
  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.