Skip to content

Commit

Permalink
fix(g-base): event => ev (#524)
Browse files Browse the repository at this point in the history
  • Loading branch information
dengfuping authored May 10, 2020
1 parent 3fdf9e2 commit b9a305b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/g-base/src/abstract/canvas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ abstract class Canvas extends Container implements ICanvas {

// 获取 touch 事件的 clientX 和 clientY 需要单独处理
getClientByEvent(ev: Event) {
let clientInfo: MouseEvent | Touch = event as MouseEvent;
let clientInfo: MouseEvent | Touch = ev as MouseEvent;
if ((ev as TouchEvent).touches) {
if (ev.type === 'touchend') {
clientInfo = (ev as TouchEvent).changedTouches[0];
Expand Down

0 comments on commit b9a305b

Please sign in to comment.