Class: Conjoin::Widgets::Events
- Inherits:
-
Struct
- Object
- Struct
- Conjoin::Widgets::Events
- Includes:
- Observable
- Defined in:
- lib/conjoin/widgets.rb
Instance Attribute Summary collapse
-
#req ⇒ Object
Returns the value of attribute req.
-
#res ⇒ Object
Returns the value of attribute res.
-
#settings ⇒ Object
Returns the value of attribute settings.
Instance Method Summary collapse
Instance Attribute Details
#req ⇒ Object
Returns the value of attribute req
115 116 117 |
# File 'lib/conjoin/widgets.rb', line 115 def req @req end |
#res ⇒ Object
Returns the value of attribute res
115 116 117 |
# File 'lib/conjoin/widgets.rb', line 115 def res @res end |
#settings ⇒ Object
Returns the value of attribute settings
115 116 117 |
# File 'lib/conjoin/widgets.rb', line 115 def settings @settings end |
Instance Method Details
#trigger(event, widget_name, user_data = {}) ⇒ Object
118 119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/conjoin/widgets.rb', line 118 def trigger event, , user_data = {} # data = OpenStruct.new({ # settings: settings, # data: user_data # }) data = user_data.to_ostruct # THIS IS WHAT WILL MAKE SURE EVENTS ARE TRIGGERED changed ################################################## notify_observers event, , data end |