9.17提交
This commit is contained in:
@@ -131,6 +131,7 @@ Component({
|
||||
this.setData({
|
||||
width: false, // 是否开启宽度调整栏
|
||||
color: false,
|
||||
isSmall:false,
|
||||
clear: false, // 是否开启清空栏
|
||||
eraser: false, // 是否开启橡皮擦
|
||||
saving: false,
|
||||
@@ -146,7 +147,7 @@ Component({
|
||||
title: '图片上传中',
|
||||
mask: true
|
||||
})
|
||||
utils.tapBtn(e, this, 2,this.data.paintFrom);
|
||||
utils.tapBtn(e, this, 2,this.data.paintFrom,this.data.isSmall);
|
||||
this.hideBarsHandler()
|
||||
},
|
||||
showBarsHandler(e) {
|
||||
@@ -192,6 +193,11 @@ Component({
|
||||
wx.getImageInfo({
|
||||
src: res.tempFilePaths[0],
|
||||
success: function (res) {
|
||||
if(res.size/1024<1024){
|
||||
this.setData({
|
||||
isSmall:true
|
||||
})
|
||||
}
|
||||
// 获取图片信息,主要为宽高,选择合适的自适应方式(将最大边完整显示)
|
||||
let [height, width] = [that.data.canvasWidth / res.width * res.height, that.data.canvasWidth];
|
||||
if (height > that.data.windowHeight - 50) {
|
||||
|
||||
Reference in New Issue
Block a user