canvas.draw在iPhone上面不执行,微信版本7.0.5,有人遇到吗?
发布于 6 年前 作者 min29 11345 次浏览 来自 官方Issues

canvas.draw在iPhone上面不执行,微信版本7.0.5

相同的小程序代码,在安卓上是好的,在iPhone的微信7.0.3版本上也是好的,但是的iPhone上微信版本7.0.4或者7.0.5上面该方法就不执行了,有人遇到相同的问题吗?

4 回复

我也遇到同样的问题,解决了吗?

麻烦提供出现问题的具体机型、微信版本号、系统版本号,以及能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

才碰到吗?前几天就被客户说了,后来我试着让画布显示出来才可以走通了

myCanvas.draw(false, () => {
        setTimeout(() => {
          wx.canvasToTempFilePath({
            canvasId: 'myCanvas',
            x: canvasWidth * 0.4,
            y: canvasHeight * 0.1,
            width: 80,
            height: canvasHeight * 0.8,
            destWidth: 80,
            destHeight: canvasHeight * 0.8,
            success: res => {
              this.getVin(path, res.tempFilePath);
            },
            fail: err => {
              console.log(err);
            }
          })
        }, 500)
 

      })


线上代码是不加setTimeout的,出现了刚刚描述的问题


在本地加上了setTimeout,还是不管用,时间加到1000也不管用



回到顶部