+ var items = [];
+ this.items.forEach(function(i) {
+ items.push(i);
+ });
+ this.items = [];
+ items.forEach(function(i,n) {
+ /*
+
+ if (type == 'GtkTable' && i.pack == 'add') {
+ var c = n % _this.config.n_columns;
+ var r = Math.floor(n/_this.config.n_columns);
+ i.pack = [ 'attach', c, c+1, r, r+1,
+ typeof(i.x_options) == 'undefined' ? 5 : i.x_options,
+ typeof(i.y_options) == 'undefined' ? 5 : i.y_options,
+ typeof(i.x_padding) == 'undefined' ? 0 : i.x_padding,
+ typeof(i.x_padding) == 'undefined' ? 0 : i.x_padding
+
+ ]
+ }
+ */
+ var item = (i.constructor == XObject) ? o : new XObject(i);
+ item.parent = _this;
+ _this.items.push(item);
+ //_this.addItem(i);
+ });
+ if (this.onConstruct) {
+ this.onConstruct.call(this);
+ }