- setItemSize : function(item, size){
- this.container.addClass('ux-layout-center');
- item.addClass('ux-layout-center-item');
- if(item && size.height > 0){
- if(item.width){
- size.width = item.width;
+ setItemSize : function(item, width, height){
+ this.owner.addCls('ux-layout-center');
+ item.addCls('ux-layout-center-item');
+ if(item && height > 0) {
+ if (width) {
+ width = item.width;
+ if (Ext.isNumber(item.widthRatio)) {
+ width = Math.round(this.owner.el.getWidth() * item.widthRatio);
+ }