Commit 117a0100 by liuquan

3.1.12

添加备注
parent 46cf8d8f
......@@ -1244,6 +1244,7 @@ Page({
*/
handleLongPress(e) {
var that = this;
//当前是按下状态
that.data.isTouch=true;
console.log("手指按下")
that.data.startPoint = e.touches[0];
......@@ -1281,6 +1282,7 @@ Page({
*/
handleTouchEnd() {
console.log("手指离开")
//当前是手指离开状态
this.data.isTouch=false;
wx.hideLoading()
recorderManager.stop()
......@@ -1315,6 +1317,7 @@ Page({
})
} else if (auth === true) { // 用户已经同意授权
// console.log('this.data.isTouch',this.data.isTouch)
//判断当前按压状态,是按下就执行录音
if(this.data.isTouch){
that.setData({
canSend: true,
......@@ -1323,6 +1326,7 @@ Page({
})
recorderManager.start(recordOptions)
}else{
//否则提示"说话时间短"
that.setData({
errorToptips: '说话时间太短'
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment