Class: MethodsController
- Inherits:
-
Shirka::Qt::TreeController
- Object
- Shirka::Controller
- Shirka::Qt::TreeController
- MethodsController
- Defined in:
- lib/troshka/methods/controller.rb
Instance Attribute Summary
Attributes inherited from Shirka::Controller
#app, #components, #data, #parent, #view
Instance Method Summary collapse
Methods inherited from Shirka::Qt::TreeController
#add_item, #init, #item_controller_class, #on_component_added, #on_double_clicked, #view_class
Methods inherited from Shirka::Controller
#add_component, #add_item, #init, #initialize, #item_controller_class, #on_component_added, #on_component_adding, #view_class
Methods included from Shirka::Eventalk
#add_watcher, #fire, #forward, #watch, #watchers
Constructor Details
This class inherits a constructor from Shirka::Controller
Instance Method Details
#on_code_evaluated(e) ⇒ Object
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/troshka/methods/controller.rb', line 6 def on_code_evaluated(e) view.clear obj = e.msg[:obj] #obj.methods.sort.each {|m| puts m.to_s} #obj.methods.sort.each {|m| add_item m.to_s} add_item ["class", obj.class.to_s] add_item ["object_id", obj.object_id.to_s] add_item ["methods", obj.methods.size.to_s] add_item ["count", obj.count.to_s] rescue nil end |
#on_starting(e) ⇒ Object
2 3 4 |
# File 'lib/troshka/methods/controller.rb', line 2 def on_starting(e) watch app.components[:editor] end |