Use GridUtil.
git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@496 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
@@ -25,10 +25,11 @@ import mx.core.Container;
|
||||
import mx.core.UIComponent;
|
||||
|
||||
import mx.containers.Grid;
|
||||
import mx.containers.GridItem;
|
||||
import mx.containers.GridRow;
|
||||
import mx.containers.HBox;
|
||||
|
||||
import com.threerings.flex.GridUtil;
|
||||
|
||||
import com.threerings.parlor.game.data.GameConfig;
|
||||
import com.threerings.parlor.util.ParlorContext;
|
||||
|
||||
@@ -71,20 +72,13 @@ public /*abstract*/ class FlexGameConfigurator extends GameConfigurator
|
||||
_gridRow = new GridRow();
|
||||
_grid.addChild(_gridRow);
|
||||
}
|
||||
_gridRow.addChild(wrapItem(label));
|
||||
_gridRow.addChild(wrapItem(control));
|
||||
GridUtil.addToRow(_gridRow, label);
|
||||
GridUtil.addToRow(_gridRow, control);
|
||||
if (_gridRow.numChildren == _columns * 2) {
|
||||
_gridRow = null;
|
||||
}
|
||||
}
|
||||
|
||||
protected function wrapItem (component :UIComponent) :GridItem
|
||||
{
|
||||
var item :GridItem = new GridItem();
|
||||
item.addChild(component);
|
||||
return item;
|
||||
}
|
||||
|
||||
/** The grid on which the config options are placed. */
|
||||
protected var _grid :Grid = new Grid();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user