MCPcopy Create free account
hub / github.com/CoderOpen/waimai / moveDraw

Method moveDraw

front/components/mpvueGestureLock/gestureLock.js:126–140  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

124
125 // 移动 绘制
126 moveDraw(e) {
127 // 画经过的圆
128 const x = e.touches[0].pageX - this.offsetX;
129 const y = e.touches[0].pageY - this.offsetY;
130 this.checkTouch({
131 x,
132 y
133 });
134
135 // 画 最后一个激活的锁与当前位置之间的线段
136 this.activeLine = this.drawLine(this.lastCheckPoint, {
137 x,
138 y
139 });
140 }
141
142 // 使 画布 恢复初始状态
143 reset() {

Callers 1

onTouchMoveMethod · 0.95

Calls 2

checkTouchMethod · 0.95
drawLineMethod · 0.95

Tested by

no test coverage detected