catch problem with missing this.list during resize
authorPhilipp Schüle <p.schuele@metaways.de>
Tue, 12 Jan 2016 15:16:09 +0000 (16:16 +0100)
committerPhilipp Schüle <p.schuele@metaways.de>
Wed, 13 Jan 2016 12:23:57 +0000 (13:23 +0100)
Change-Id: I90fc33333de6b88bb8a961c8873f698657de5519
Reviewed-on: http://gerrit.tine20.com/customers/2574
Tested-by: Jenkins CI (http://ci.tine20.com/)
Reviewed-by: Philipp Schüle <p.schuele@metaways.de>
Tested-by: Philipp Schüle <p.schuele@metaways.de>
tine20/Tinebase/js/widgets/form/RecordPickerComboBox.js

index 28c5703..11ca5be 100644 (file)
@@ -145,8 +145,17 @@ Tine.Tinebase.widgets.form.RecordPickerComboBox = Ext.extend(Ext.ux.form.Clearab
             });
         }
     },
-    
-    
+
+    // TODO re-init this.list if it goes away?
+    // NOTE: we sometimes lose this.list (how?). prevent error by checking existence.
+    doResize: function(w){
+        if(!Ext.isDefined(this.listWidth) && this.list){
+            var lw = Math.max(w, this.minListWidth);
+            this.list.setWidth(lw);
+            this.innerList.setWidth(lw - this.list.getFrameWidth('lr'));
+        }
+    },
+
     /**
      * prepare paging and sort
      *