$("#recordIcon").on('touchstart', function(event) {
wx.startRecord({
success : function() {
//弹出窗口,正在录音
var $recording = $('#recording');
$recording.fadeIn(200);
},
cancel : function() {
alert("用户拒绝授权录音");
}
});
}
$("#recordIcon").on('touchend', function(event) {
wx.stopRecord({
success : function(res) {
playId = voice.localId;
uploadVoice(voice.localId);
},
fail : function(res) {
weui.toast('请长按录音!', {
duration : 1000,
className : "bears"
});
}
});
}
新用户首次录音时,微信会弹出是否允许录音的提示。此时若松开手去点允许或者不允许,那么touchend事件不执行是为什么。或者说如何监听到微信弹出的这个提示框呢,求大神指教