mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-14 01:15:44 +01:00
resize grids on browserwindow resize, see #10
This commit is contained in:
@@ -99,13 +99,30 @@ Sonia.user.Grid = Ext.extend(Sonia.rest.Grid, {
|
||||
|
||||
var config = {
|
||||
store: userStore,
|
||||
colModel: userColModel
|
||||
colModel: userColModel,
|
||||
listeners: {
|
||||
fallBelowMinHeight: {
|
||||
fn: this.onFallBelowMinHeight,
|
||||
scope: this
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Ext.apply(this, Ext.apply(this.initialConfig, config));
|
||||
Sonia.user.Grid.superclass.initComponent.apply(this, arguments);
|
||||
},
|
||||
|
||||
onFallBelowMinHeight: function(height, minHeight){
|
||||
var p = Ext.getCmp('userEditPanel');
|
||||
this.setHeight(minHeight);
|
||||
var epHeight = p.getHeight();
|
||||
p.setHeight(epHeight - (minHeight - height));
|
||||
// rerender
|
||||
this.doLayout();
|
||||
p.doLayout();
|
||||
this.ownerCt.doLayout();
|
||||
},
|
||||
|
||||
selectItem: function(item){
|
||||
if ( debug ){
|
||||
console.debug( item.name + ' selected' );
|
||||
|
||||
Reference in New Issue
Block a user