Class: Glimmer::DSL::Libui::PropertyExpression
- Inherits:
-
Expression
- Object
- Expression
- Glimmer::DSL::Libui::PropertyExpression
- Defined in:
- lib/glimmer/dsl/libui/property_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
31 32 33 34 35 36 37 38 39 40 |
# File 'lib/glimmer/dsl/libui/property_expression.rb', line 31 def can_interpret?(parent, keyword, *args, &block) ( parent.is_a?(Glimmer::LibUI::ControlProxy) or parent.is_a?(Glimmer::LibUI::Shape) or parent.is_a?(Glimmer::LibUI::AttributedString) or parent.is_a?(Glimmer::LibUI::CustomControl) ) and block.nil? and parent.respond_to?("#{keyword}=", *args) end |
#interpret(parent, keyword, *args, &block) ⇒ Object
42 43 44 |
# File 'lib/glimmer/dsl/libui/property_expression.rb', line 42 def interpret(parent, keyword, *args, &block) parent.send("#{keyword}=", *args) end |