Class: Fet::Ui::CustomEvent
- Inherits:
-
Object
- Object
- Fet::Ui::CustomEvent
- Defined in:
- lib/fet/ui/custom_event.rb
Overview
Custom events for the event loop
Constant Summary collapse
- EVENT_TYPE_NOTE_SELECTED =
:note_selected
- EVENT_TYPE_LEVEL_STARTED =
:level_started
- EVENT_TYPE_LEVEL_COMPLETE =
:level_complete
- EVENT_TYPES =
[ EVENT_TYPE_NOTE_SELECTED, EVENT_TYPE_LEVEL_STARTED, EVENT_TYPE_LEVEL_COMPLETE, ].deep_freeze
Instance Attribute Summary collapse
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(type) ⇒ CustomEvent
constructor
A new instance of CustomEvent.
Constructor Details
#initialize(type) ⇒ CustomEvent
Returns a new instance of CustomEvent.
18 19 20 21 |
# File 'lib/fet/ui/custom_event.rb', line 18 def initialize(type) self.type = type validate_type! end |
Instance Attribute Details
#type ⇒ Object
Returns the value of attribute type.
7 8 9 |
# File 'lib/fet/ui/custom_event.rb', line 7 def type @type end |