Class: Browser::Event::Composition

Inherits:
UI show all
Defined in:
opal/browser/event/composition.rb

Defined Under Namespace

Classes: Definition

Instance Attribute Summary

Attributes inherited from Browser::Event

#callback, #on

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Browser::Event

aliases, #arguments, #arguments=, class_for, create, handlers, handles, #initialize, #name, name_for, new, #off, #prevent, #prevented?, #stop, #stop!, #stopped?, #target

Constructor Details

This class inherits a constructor from Browser::Event

Class Method Details

.construct(name, desc) ⇒ Object



18
19
20
# File 'opal/browser/event/composition.rb', line 18

def self.construct(name, desc)
  `new CompositionEvent(#{name}, #{desc})`
end

.supported?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'opal/browser/event/composition.rb', line 8

def self.supported?
  Browser.supports? 'Event.Composition'
end

Instance Method Details

#end?Boolean

Returns:

  • (Boolean)


44
45
46
# File 'opal/browser/event/composition.rb', line 44

def end?
  name.downcase == 'compositionend'
end

#start?Boolean

Returns:

  • (Boolean)


36
37
38
# File 'opal/browser/event/composition.rb', line 36

def start?
  name.downcase == 'compositionstart'
end

#update?Boolean

Returns:

  • (Boolean)


40
41
42
# File 'opal/browser/event/composition.rb', line 40

def update?
  name.downcase == 'compositionupdate'
end