Class: W3C::DOM4::Event

Inherits:
Object
  • Object
show all
Defined in:
lib/w3c/dom4/event.rb

Overview

Direct Known Subclasses

W3C::DOM3::UIEvent

Constant Summary collapse

NONE =
0
CAPTURING_PHASE =
1
AT_TARGET =
2
BUBBLING_PHASE =
3

Instance Method Summary collapse

Constructor Details

#initialize(type, eventInitDict = {}) ⇒ Event

Returns a new instance of Event.

Parameters:

  • type (String)
  • eventInitDict (Hash) (defaults to: {})


14
15
16
17
18
19
20
# File 'lib/w3c/dom4/event.rb', line 14

def initialize(type, eventInitDict={})
  @type = type
  @bubbles = eventInitDict[:bubbles] || false
  @cancelable = eventInitDict[:cancelable] || false
  @timeStamp = Time.now.to_i
  @isTrusted = true
end

Instance Method Details

#preventDefaultObject



31
# File 'lib/w3c/dom4/event.rb', line 31

def preventDefault() end

#stopImmediatePropagationObject



30
# File 'lib/w3c/dom4/event.rb', line 30

def stopImmediatePropagation() end

#stopPropagationObject



29
# File 'lib/w3c/dom4/event.rb', line 29

def stopPropagation() end