Class: Wx::EvtHandler
- Inherits:
-
Object
- Object
- Wx::EvtHandler
- Defined in:
- lib/fugit/messages.rb,
lib/fugit/main_frame.rb
Instance Method Summary collapse
- #register_for_message(message, method = nil, &block) ⇒ Object
- #repo ⇒ Object
- #repo=(val) ⇒ Object
- #send_message(message, *args) ⇒ Object
Instance Method Details
#register_for_message(message, method = nil, &block) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/fugit/messages.rb', line 4 def (, method = nil, &block) raise "Must pass method or block" unless block || method block ||= Proc.new {|*args| self.send(method, *args)} ||= {} [] ||= [] [] << block end |
#repo ⇒ Object
6 7 8 |
# File 'lib/fugit/main_frame.rb', line 6 def repo @@repo end |
#repo=(val) ⇒ Object
10 11 12 |
# File 'lib/fugit/main_frame.rb', line 10 def repo=(val) @@repo = val end |
#send_message(message, *args) ⇒ Object
13 14 15 16 |
# File 'lib/fugit/messages.rb', line 13 def (, *args) blocks = [] || [] blocks.each {|block| block.call(*args)} end |