package net.alcuria.umbracraft.engine.windows;

import net.alcuria.umbracraft.editor.Drawables;

import com.badlogic.gdx.scenes.scene2d.Actor;
import com.badlogic.gdx.scenes.scene2d.ui.Cell;
import com.badlogic.gdx.scenes.scene2d.ui.Table;
import com.badlogic.gdx.scenes.scene2d.utils.TiledDrawable;

public class WindowTable extends Table {

	private Table content;

	public WindowTable() {

		stack(new Table() {
			{
				add(new Table() {
					{
						setBackground(new TiledDrawable(Drawables.skin("ui/bg")));
					}
				}).expand().fill().pad(3);
			}
		}, new Table() {
			{
				setBackground(Drawables.ninePatch("ui/frame"));
				add(content = new Table()).expand().fill();
			}
		});

	}

	public <T extends Actor> Cell<T> put(T actor) {
		return content.add(actor);
	}
}

@@ -294,16 +294,176 @@
 wable;%0A%0A
+/** A table with the background set to the game's window styling. Use%0A * %7B@link WindowTable#put(Actor)%7D to add things to the table.%0A * @author Andrew Keturi */%0A
 public c
@@ -850,16 +850,160 @@
 );%0A%0A%09%7D%0A%0A
+%09/** Equivalent to add, but puts the content in the correct spot.%0A%09 * @param actor the actor to add to the table.%0A%09 * @return a %7B@link Cell%7D */%0A
 %09public 

Add WindowTable javadocs