Class: Glimmer::DSL::Opal::LayoutExpression
- Inherits:
-
Expression
- Object
- Expression
- Glimmer::DSL::Opal::LayoutExpression
- Includes:
- ParentExpression
- Defined in:
- lib/glimmer/dsl/opal/layout_expression.rb
Instance Method Summary collapse
- #can_interpret?(parent, keyword, *args, &block) ⇒ Boolean
- #interpret(parent, keyword, *args, &block) ⇒ Object
Instance Method Details
#can_interpret?(parent, keyword, *args, &block) ⇒ Boolean
11 12 13 14 |
# File 'lib/glimmer/dsl/opal/layout_expression.rb', line 11 def can_interpret?(parent, keyword, *args, &block) (parent.is_a?(Glimmer::SWT::CompositeProxy) or (parent.is_a?(Glimmer::UI::CustomWidget) and parent.body_root.is_a?(Glimmer::SWT::CompositeProxy))) and Glimmer::SWT::LayoutProxy.layout_exists?(keyword) end |
#interpret(parent, keyword, *args, &block) ⇒ Object
16 17 18 |
# File 'lib/glimmer/dsl/opal/layout_expression.rb', line 16 def interpret(parent, keyword, *args, &block) Glimmer::SWT::LayoutProxy.for(keyword, parent, args) end |