nktsitas/kineticjs-editable-text

Kinetic.EditableText.focus() Throws an Uncaught TypeError If the Mouse Cursor Is Not on the Canvas

Closed this issue · 0 comments

If the mouse cursor is not on the canvas when Kinetic.EditableText.focus() is called, the following error will be thrown: Uncaught TypeError: Cannot read property 'y' of undefined.

The problem is with var pos = that.stage.getPointerPosition(); in Kinetic.EditableText.findCursorPosFromClick() and the if statement directly beneath it. I will take a closer look at this later.