roojs-bootstrap.js
authorEdward <edward@roojs.com>
Fri, 30 Nov 2018 03:41:48 +0000 (11:41 +0800)
committerEdward <edward@roojs.com>
Fri, 30 Nov 2018 03:41:48 +0000 (11:41 +0800)
roojs-bootstrap-debug.js

roojs-bootstrap-debug.js
roojs-bootstrap.js

index c6c8a68..6593c99 100644 (file)
@@ -29253,10 +29253,10 @@ Roo.extend(Roo.bootstrap.DocumentManager, Roo.bootstrap.Component,  {
             this.files = this.files.slice(0, this.boxes);
         }
         
-        this.uploader.show();
+        this.uploader.show(false);
         
         if(this.boxes > 0 && this.files.length > this.boxes - 1){
-            this.uploader.hide();
+            this.uploader.hide(false);
         }
         
         var _this = this;
@@ -29310,14 +29310,14 @@ Roo.extend(Roo.bootstrap.DocumentManager, Roo.bootstrap.Component,  {
     arrange : function()
     {
         if(!this.delegates.length){
-            this.progressDialog.hide();
+            this.progressDialog.hide(false);
             this.refresh();
             return;
         }
         
         var delegate = this.delegates.shift();
         
-        this.progressDialog.show();
+        this.progressDialog.show(false);
         
         this.progressDialog.setTitle((this.progressBar.aria_valuemax - this.delegates.length) + ' / ' + this.progressBar.aria_valuemax);
         
@@ -29328,10 +29328,10 @@ Roo.extend(Roo.bootstrap.DocumentManager, Roo.bootstrap.Component,  {
     
     refresh : function()
     {
-        this.uploader.show();
+        this.uploader.show(false);
         
         if(this.boxes > 0 && this.files.length > this.boxes - 1){
-            this.uploader.hide();
+            this.uploader.hide(false);
         }
         
         Roo.isTouch ? this.closable(false) : this.closable(true);
index 216f7e6..d341a87 100644 (file)
@@ -1247,12 +1247,12 @@ this.uploader.setVisibilityMode(Roo.Element.DISPLAY).originalDisplay='block';thi
 this.hide();}}});this.progressDialog.render(Roo.get(document.body));this.progress=new Roo.bootstrap.Progress({cls:'roo-document-manager-progress',active:true,striped:true});this.progress.render(this.progressDialog.getChildContainer());this.progressBar=new Roo.bootstrap.ProgressBar({cls:'roo-document-manager-progress-bar',aria_valuenow:0,aria_valuemin:0,aria_valuemax:12,panel:'success'}
 );this.progressBar.render(this.progress.getChildContainer());},onUploaderClick:function(e){e.preventDefault();if(this.fireEvent('beforeselectfile',this)!=false){this.selectorEl.dom.click();}},onFileSelected:function(e){e.preventDefault();if(typeof(this.selectorEl.dom.files)=='undefined'||!this.selectorEl.dom.files.length){return;
 }Roo.each(this.selectorEl.dom.files,function(A){if(this.fireEvent('inspect',this,A)!=false){this.files.push(A);}},this);this.queue();},queue:function(){this.selectorEl.dom.value='';if(!this.files||!this.files.length){return;}if(this.boxes>0&&this.files.length>this.boxes){this.files=this.files.slice(0,this.boxes);
-}this.uploader.show();if(this.boxes>0&&this.files.length>this.boxes-1){this.uploader.hide();}var A=this;var B=[];var C=[];Roo.each(this.files,function(D){if(typeof(D.id)!='undefined'&&D.id*1>0){var f=this.renderPreview(D);B.push(f);return;}if(D.type.indexOf('image')!=-1){this.delegates.push((function(){A.process(D);
+}this.uploader.show(false);if(this.boxes>0&&this.files.length>this.boxes-1){this.uploader.hide(false);}var A=this;var B=[];var C=[];Roo.each(this.files,function(D){if(typeof(D.id)!='undefined'&&D.id*1>0){var f=this.renderPreview(D);B.push(f);return;}if(D.type.indexOf('image')!=-1){this.delegates.push((function(){A.process(D);
 }).createDelegate(this));return;}C.push((function(){A.process(D);}).createDelegate(this));},this);this.files=B;this.delegates=this.delegates.concat(C);if(!this.delegates.length){this.refresh();return;}this.progressBar.aria_valuemax=this.delegates.length;this.arrange();
-return;},arrange:function(){if(!this.delegates.length){this.progressDialog.hide();this.refresh();return;}var A=this.delegates.shift();this.progressDialog.show();this.progressDialog.setTitle((this.progressBar.aria_valuemax-this.delegates.length)+' / '+this.progressBar.aria_valuemax);
-this.progressBar.update(this.progressBar.aria_valuemax-this.delegates.length);A();},refresh:function(){this.uploader.show();if(this.boxes>0&&this.files.length>this.boxes-1){this.uploader.hide();}Roo.isTouch?this.closable(false):this.closable(true);this.fireEvent('refresh',this);
-},onRemove:function(e,el,o){e.preventDefault();this.fireEvent('remove',this,o);},remove:function(o){var A=[];Roo.each(this.files,function(B){if(typeof(B.id)=='undefined'||B.id*1<1||B.id!=o.id){A.push(B);return;}o.target.remove();},this);this.files=A;this.refresh();
-},clear:function(){Roo.each(this.files,function(A){if(!A.target){return;}A.target.remove();},this);this.files=[];this.refresh();},onClick:function(e,el,o){e.preventDefault();this.fireEvent('click',this,o);},closable:function(A){Roo.each(this.managerEl.select('.roo-document-manager-preview > button.close',true).elements,function(el){el.setVisibilityMode(Roo.Element.DISPLAY).originalDisplay='block';
+return;},arrange:function(){if(!this.delegates.length){this.progressDialog.hide(false);this.refresh();return;}var A=this.delegates.shift();this.progressDialog.show(false);this.progressDialog.setTitle((this.progressBar.aria_valuemax-this.delegates.length)+' / '+this.progressBar.aria_valuemax);
+this.progressBar.update(this.progressBar.aria_valuemax-this.delegates.length);A();},refresh:function(){this.uploader.show(false);if(this.boxes>0&&this.files.length>this.boxes-1){this.uploader.hide(false);}Roo.isTouch?this.closable(false):this.closable(true);
+this.fireEvent('refresh',this);},onRemove:function(e,el,o){e.preventDefault();this.fireEvent('remove',this,o);},remove:function(o){var A=[];Roo.each(this.files,function(B){if(typeof(B.id)=='undefined'||B.id*1<1||B.id!=o.id){A.push(B);return;}o.target.remove();
+},this);this.files=A;this.refresh();},clear:function(){Roo.each(this.files,function(A){if(!A.target){return;}A.target.remove();},this);this.files=[];this.refresh();},onClick:function(e,el,o){e.preventDefault();this.fireEvent('click',this,o);},closable:function(A){Roo.each(this.managerEl.select('.roo-document-manager-preview > button.close',true).elements,function(el){el.setVisibilityMode(Roo.Element.DISPLAY).originalDisplay='block';
 if(A){el.show();return;}el.hide();},this);},xhrOnLoad:function(A){Roo.each(this.managerEl.select('.roo-document-manager-loading',true).elements,function(el){el.remove();},this);if(A.readyState!==4){this.arrange();this.fireEvent('exception',this,A);return;
 }var B=Roo.decode(A.responseText);if(!B.success){this.arrange();this.fireEvent('exception',this,A);return;}var C=this.renderPreview(B.data);this.files.push(C);this.arrange();this.fireEvent('afterupload',this,A);},xhrOnError:function(A){Roo.log('xhr on error');
 var B=Roo.decode(A.responseText);Roo.log(B);this.arrange();},process:function(A){if(this.fireEvent('process',this,A)!==false){if(this.editable&&A.type.indexOf('image')!=-1){this.fireEvent('edit',this,A);return;}this.uploadStart(A,false);return;}},uploadStart:function(A,B){this.xhr=new XMLHttpRequest();