UNPKG

lazy-widgets

Version:

Typescript retained mode GUI for the HTML canvas API

24 lines 771 B
import { FocusType } from '../core/FocusType.js'; import { TargetableTricklingEvent } from './TargetableTricklingEvent.js'; /** * An event which contains text pasted by the clipboard. * * Has a focus type of {@link FocusType.Keyboard} and does not need focus. * * @category Event */ export class TextPasteEvent extends TargetableTricklingEvent { constructor(text, target = null) { super(target); this.type = TextPasteEvent.type; this.focusType = FocusType.Keyboard; this.needsFocus = false; this.userCapturable = true; this.text = text; } cloneWithTarget(target) { return new TextPasteEvent(this.text, target); } } TextPasteEvent.type = 'text-paste'; //# sourceMappingURL=TextPasteEvent.js.map