From f0ffb8fa725d4c8f2548fb832629965704b726b0 Mon Sep 17 00:00:00 2001 From: leon Date: Tue, 5 Jul 2022 14:47:06 +0800 Subject: [PATCH] roojs-core.js roojs-core-debug.js roojs-ui.js roojs-ui-debug.js roojs-all.js roojs-debug.js --- roojs-all.js | 8 ++++---- roojs-debug.js | 5 +---- roojs-ui-debug.js | 5 +---- roojs-ui.js | 8 ++++---- 4 files changed, 10 insertions(+), 16 deletions(-) diff --git a/roojs-all.js b/roojs-all.js index d7db531008..5a1bf101c1 100644 --- a/roojs-all.js +++ b/roojs-all.js @@ -2897,10 +2897,10 @@ this.setCanvasPosition();}},onFooterButtonClick:function(e,el,o,A){switch(A){cas break;case 'download':this.download(e);break;default:break;}this.fireEvent('footerbuttonclick',this,A);},beforeSelectFile: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;}var A=this.selectorEl.dom.files[0];if(this.fireEvent('inspect',this,A)!=false){this.prepare(A);}},trash:function(e){this.fireEvent('trash',this);},download:function(e){this.fireEvent('download',this); },loadCanvas:function(A){if(this.fireEvent('beforeloadcanvas',this,A)!=false){this.reset();this.imageEl=document.createElement('img');var B=this;this.imageEl.addEventListener("load",function(){B.onLoadCanvas();});this.imageEl.src=A;}},onLoadCanvas:function(){this.imageEl.OriginWidth=this.imageEl.naturalWidth||this.imageEl.width; -this.imageEl.OriginHeight=this.imageEl.naturalHeight||this.imageEl.height;var A=this;if(this.imageEl.OriginWidthE)?C:E);F=(BF)?D:F);this.previewEl.setLeft(E);this.previewEl.setTop(F);this.mouseX=Roo.isTouch?e.browserEvent.touches[0].pageX:e.getPageX(); diff --git a/roojs-debug.js b/roojs-debug.js index b5ed3a05be..66a6493c44 100644 --- a/roojs-debug.js +++ b/roojs-debug.js @@ -68502,10 +68502,7 @@ Roo.extend(Roo.dialog.UploadCropbox, Roo.Component, { msg: "Image width should be at least 720", buttons: {ok : true}, fn: function(res) { - if(res == 'ok'){ - console.log("OK"); - _this.selectorEl.dom.click(); - } + _this.selectorEl.dom.click(); } }); } diff --git a/roojs-ui-debug.js b/roojs-ui-debug.js index e916938002..4b5122b5c9 100644 --- a/roojs-ui-debug.js +++ b/roojs-ui-debug.js @@ -44010,10 +44010,7 @@ Roo.extend(Roo.dialog.UploadCropbox, Roo.Component, { msg: "Image width should be at least 720", buttons: {ok : true}, fn: function(res) { - if(res == 'ok'){ - console.log("OK"); - _this.selectorEl.dom.click(); - } + _this.selectorEl.dom.click(); } }); } diff --git a/roojs-ui.js b/roojs-ui.js index 53edbcf074..834a3b65e6 100644 --- a/roojs-ui.js +++ b/roojs-ui.js @@ -1951,10 +1951,10 @@ this.setCanvasPosition();}},onFooterButtonClick:function(e,el,o,A){switch(A){cas break;case 'download':this.download(e);break;default:break;}this.fireEvent('footerbuttonclick',this,A);},beforeSelectFile: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;}var A=this.selectorEl.dom.files[0];if(this.fireEvent('inspect',this,A)!=false){this.prepare(A);}},trash:function(e){this.fireEvent('trash',this);},download:function(e){this.fireEvent('download',this); },loadCanvas:function(A){if(this.fireEvent('beforeloadcanvas',this,A)!=false){this.reset();this.imageEl=document.createElement('img');var B=this;this.imageEl.addEventListener("load",function(){B.onLoadCanvas();});this.imageEl.src=A;}},onLoadCanvas:function(){this.imageEl.OriginWidth=this.imageEl.naturalWidth||this.imageEl.width; -this.imageEl.OriginHeight=this.imageEl.naturalHeight||this.imageEl.height;var A=this;if(this.imageEl.OriginWidthE)?C:E);F=(BF)?D:F);this.previewEl.setLeft(E);this.previewEl.setTop(F);this.mouseX=Roo.isTouch?e.browserEvent.touches[0].pageX:e.getPageX(); -- 2.39.2