Class: Glimmer::SWT::CommandHandlers::WidgetCommandHandler
- Inherits:
-
Object
- Object
- Glimmer::SWT::CommandHandlers::WidgetCommandHandler
- Includes:
- CommandHandler
- Defined in:
- lib/glimmer/swt/command_handlers/widget_command_handler.rb
Instance Method Summary collapse
- #can_handle?(parent, command_symbol, *args, &block) ⇒ Boolean
- #do_handle(parent, command_symbol, *args, &block) ⇒ Object
Instance Method Details
#can_handle?(parent, command_symbol, *args, &block) ⇒ Boolean
13 14 15 16 17 |
# File 'lib/glimmer/swt/command_handlers/widget_command_handler.rb', line 13 def can_handle?(parent, command_symbol, *args, &block) (parent.is_a?(GWidget) || parent.is_a?(SWT::CustomWidget)) and command_symbol.to_s != "shell" and GWidget.(command_symbol.to_s) end |
#do_handle(parent, command_symbol, *args, &block) ⇒ Object
19 20 21 22 |
# File 'lib/glimmer/swt/command_handlers/widget_command_handler.rb', line 19 def do_handle(parent, command_symbol, *args, &block) Glimmer.logger.debug "widget styles are: " + args.inspect GWidget.new(command_symbol.to_s, parent., args) end |