Event.hx 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. /* This file is generated, do not edit! Visit http://api.jquery.com/ for API documentation. */
  2. package js.jquery;
  3. @:native("$.Event") extern class Event extends js.html.Event {
  4. /**
  5. An optional object of data passed to an event method when the current executing handler is bound.
  6. **/
  7. public var data : Dynamic;
  8. /**
  9. The element where the currently-called jQuery event handler was attached.
  10. **/
  11. public var delegateTarget : js.html.Element;
  12. /**
  13. Returns whether <a href="/event.preventDefault/">event.preventDefault()</a> was ever called on this event object.
  14. **/
  15. public function isDefaultPrevented():Bool;
  16. /**
  17. Returns whether event.stopImmediatePropagation() was ever called on this event object.
  18. **/
  19. public function isImmediatePropagationStopped():Bool;
  20. /**
  21. Returns whether <a href="/event.stopPropagation/">event.stopPropagation()</a> was ever called on this event object.
  22. **/
  23. public function isPropagationStopped():Bool;
  24. /**
  25. Indicates whether the META key was pressed when the event fired.
  26. **/
  27. public var metaKey : Bool;
  28. /**
  29. The namespace specified when the event was triggered.
  30. **/
  31. public var namespace : String;
  32. /**
  33. The mouse position relative to the left edge of the document.
  34. **/
  35. public var pageX : Float;
  36. /**
  37. The mouse position relative to the top edge of the document.
  38. **/
  39. public var pageY : Float;
  40. /**
  41. The other DOM element involved in the event, if any.
  42. **/
  43. public var relatedTarget : js.html.Element;
  44. /**
  45. The last value returned by an event handler that was triggered by this event, unless the value was <code>undefined</code>.
  46. **/
  47. public var result : Dynamic;
  48. /**
  49. For key or mouse events, this property indicates the specific key or button that was pressed.
  50. **/
  51. public var which : Float;
  52. /**
  53. Returns a `Boolean` that is `true` if the Alt ( Option or ⌥ on OS X) key was active when the key event was generated.
  54. **/
  55. public var altKey : Bool;
  56. /**
  57. The button number that was pressed when the mouse event was fired. 
  58. **/
  59. public var button : Int;
  60. /**
  61. The buttons being pressed when the mouse event was fired
  62. **/
  63. public var buttons : Int;
  64. public var char : Int;
  65. /**
  66. Returns a `Number` representing the Unicode reference number of the key; this attribute is used only by the `keypress` event. For keys whose `char` attribute contains multiple characters, this is the Unicode value of the first character in that attribute. In Firefox 26 this returns codes for printable characters.
  67. Warning: This attribute is deprecated; you should use `KeyboardEvent.key` instead, if available.
  68. **/
  69. public var charCode : Int;
  70. /**
  71. The X coordinate of the mouse pointer in local (DOM content) coordinates.
  72. **/
  73. public var clientX : Int;
  74. /**
  75. The Y coordinate of the mouse pointer in local (DOM content) coordinates.
  76. **/
  77. public var clientY : Int;
  78. /**
  79. Returns a `Boolean` that is `true` if the Ctrl key was active when the key event was generated.
  80. **/
  81. public var ctrlKey : Bool;
  82. /**
  83. Returns a `long` with details about the event, depending on the event type.
  84. **/
  85. public var detail : Int;
  86. /**
  87. Returns a `DOMString` representing the key value of the key represented by the event.
  88. **/
  89. public var key : String;
  90. /**
  91. Returns a `Number` representing a system and implementation dependent numerical code identifying the unmodified value of the pressed key.
  92. Warning: This attribute is deprecated; you should use `KeyboardEvent.key` instead, if available.
  93. **/
  94. public var keyCode : Int;
  95. public var offsetX : Int;
  96. public var offsetY : Int;
  97. /**
  98. The X coordinate of the mouse pointer in global (screen) coordinates.
  99. **/
  100. public var screenX : Int;
  101. /**
  102. The Y coordinate of the mouse pointer in global (screen) coordinates.
  103. **/
  104. public var screenY : Int;
  105. /**
  106. Returns a `Boolean` that is `true` if the Shift key was active when the key event was generated.
  107. **/
  108. public var shiftKey : Bool;
  109. public var toElement : js.html.Element;
  110. /**
  111. Returns a `WindowProxy` that contains the view that generated the event.
  112. **/
  113. public var view : js.html.Window;
  114. /**
  115. A convenient method of getting `$(this)`, which is typically the same as `$(evt.currentTarget)`.
  116. For detail, refer to https://api.jquery.com/event.currenttarget/.
  117. **/
  118. inline public function getThis():js.jquery.JQuery return new js.jquery.JQuery(js.Lib.nativeThis);
  119. }