Roo/bootstrap/ComboBox.js
[roojs1] / Roo / bootstrap / ComboBox.js
index 08b7336..deb94cb 100644 (file)
@@ -1513,6 +1513,7 @@ Roo.extend(Roo.bootstrap.ComboBox, Roo.bootstrap.TriggerField, {
     onEmptyResults : function(){
         
         if(this.tickable && this.editable){
+            this.hasFocus = false;
             this.restrictHeight();
             return;
         }
@@ -2129,6 +2130,10 @@ Roo.extend(Roo.bootstrap.ComboBox, Roo.bootstrap.TriggerField, {
     
     validate : function()
     {
+        if(this.getVisibilityEl().hasClass('hidden') || !this.getVisibilityEl().isVisible(true)){
+            return true;
+        }
+        
         var v = this.getRawValue();
         
         if(this.multiple){
@@ -2840,7 +2845,7 @@ Roo.extend(Roo.bootstrap.ComboBox, Roo.bootstrap.TriggerField, {
             }
             
             if(this.emptyTitle.length){
-                default_text = ' - ' + this.emptyTitle + ' -';
+                default_text += ' - ' + this.emptyTitle + ' -';
             }
             
             var opt = this.inputEl().createChild({