4341d048de4a0a0a0107408099d061bc0b8bd82d3109cc4dee36afeeba53e48b.json 4.2 KB

1
  1. {"ast":null,"code":"/**\n * Gather the list of clipboard event types as constants.\n */\nexport class ClipboardEventTypes {}\n/**\n * The clipboard event is fired when a copy command is active (pressed).\n */\nClipboardEventTypes.COPY = 0x01; //\n/**\n * The clipboard event is fired when a cut command is active (pressed).\n */\nClipboardEventTypes.CUT = 0x02;\n/**\n * The clipboard event is fired when a paste command is active (pressed).\n */\nClipboardEventTypes.PASTE = 0x03;\n/**\n * This class is used to store clipboard related info for the onClipboardObservable event.\n */\nexport class ClipboardInfo {\n /**\n *Creates an instance of ClipboardInfo.\n * @param type Defines the type of event (BABYLON.ClipboardEventTypes)\n * @param event Defines the related dom event\n */\n constructor(\n /**\n * Defines the type of event (BABYLON.ClipboardEventTypes)\n */\n type,\n /**\n * Defines the related dom event\n */\n event) {\n this.type = type;\n this.event = event;\n }\n /**\n * Get the clipboard event's type from the keycode.\n * @param keyCode Defines the keyCode for the current keyboard event.\n * @returns {number}\n */\n static GetTypeFromCharacter(keyCode) {\n const charCode = keyCode;\n //TODO: add codes for extended ASCII\n switch (charCode) {\n case 67:\n return ClipboardEventTypes.COPY;\n case 86:\n return ClipboardEventTypes.PASTE;\n case 88:\n return ClipboardEventTypes.CUT;\n default:\n return -1;\n }\n }\n}","map":{"version":3,"names":["ClipboardEventTypes","COPY","CUT","PASTE","ClipboardInfo","constructor","type","event","GetTypeFromCharacter","keyCode","charCode"],"sources":["F:/workspace/202226701027/huinongbao-app/node_modules/@babylonjs/core/Events/clipboardEvents.js"],"sourcesContent":["/**\n * Gather the list of clipboard event types as constants.\n */\nexport class ClipboardEventTypes {\n}\n/**\n * The clipboard event is fired when a copy command is active (pressed).\n */\nClipboardEventTypes.COPY = 0x01; //\n/**\n * The clipboard event is fired when a cut command is active (pressed).\n */\nClipboardEventTypes.CUT = 0x02;\n/**\n * The clipboard event is fired when a paste command is active (pressed).\n */\nClipboardEventTypes.PASTE = 0x03;\n/**\n * This class is used to store clipboard related info for the onClipboardObservable event.\n */\nexport class ClipboardInfo {\n /**\n *Creates an instance of ClipboardInfo.\n * @param type Defines the type of event (BABYLON.ClipboardEventTypes)\n * @param event Defines the related dom event\n */\n constructor(\n /**\n * Defines the type of event (BABYLON.ClipboardEventTypes)\n */\n type, \n /**\n * Defines the related dom event\n */\n event) {\n this.type = type;\n this.event = event;\n }\n /**\n * Get the clipboard event's type from the keycode.\n * @param keyCode Defines the keyCode for the current keyboard event.\n * @returns {number}\n */\n static GetTypeFromCharacter(keyCode) {\n const charCode = keyCode;\n //TODO: add codes for extended ASCII\n switch (charCode) {\n case 67:\n return ClipboardEventTypes.COPY;\n case 86:\n return ClipboardEventTypes.PASTE;\n case 88:\n return ClipboardEventTypes.CUT;\n default:\n return -1;\n }\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAO,MAAMA,mBAAmB,CAAC;AAEjC;AACA;AACA;AACAA,mBAAmB,CAACC,IAAI,GAAG,IAAI,CAAC,CAAC;AACjC;AACA;AACA;AACAD,mBAAmB,CAACE,GAAG,GAAG,IAAI;AAC9B;AACA;AACA;AACAF,mBAAmB,CAACG,KAAK,GAAG,IAAI;AAChC;AACA;AACA;AACA,OAAO,MAAMC,aAAa,CAAC;EACvB;AACJ;AACA;AACA;AACA;EACIC,WAAWA;EACX;AACJ;AACA;EACIC,IAAI;EACJ;AACJ;AACA;EACIC,KAAK,EAAE;IACH,IAAI,CAACD,IAAI,GAAGA,IAAI;IAChB,IAAI,CAACC,KAAK,GAAGA,KAAK;EACtB;EACA;AACJ;AACA;AACA;AACA;EACI,OAAOC,oBAAoBA,CAACC,OAAO,EAAE;IACjC,MAAMC,QAAQ,GAAGD,OAAO;IACxB;IACA,QAAQC,QAAQ;MACZ,KAAK,EAAE;QACH,OAAOV,mBAAmB,CAACC,IAAI;MACnC,KAAK,EAAE;QACH,OAAOD,mBAAmB,CAACG,KAAK;MACpC,KAAK,EAAE;QACH,OAAOH,mBAAmB,CAACE,GAAG;MAClC;QACI,OAAO,CAAC,CAAC;IACjB;EACJ;AACJ","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]}