Sha256: 7203fffaf81d8debe73de795f2993119cf1aceaca963d6ec9d1a4f361ec0c0f4

Contents?: true

Size: 691 Bytes

Versions: 41

Compression:

Stored size: 691 Bytes

Contents

require 'glimmer/dsl/static_expression'
require 'glimmer/dsl/parent_expression'
require 'glimmer/dsl/top_level_expression'
require 'glimmer/swt/shell_proxy'

module Glimmer
  module DSL
    module SWT
      class ShellExpression < StaticExpression
        include TopLevelExpression
        include ParentExpression

        def can_interpret?(parent, keyword, *args, &block)
          keyword == 'shell' and
            (parent.nil? or parent.is_a?(Glimmer::SWT::ShellProxy))
        end
  
        def interpret(parent, keyword, *args, &block)
          args = [parent] + args unless parent.nil?
          Glimmer::SWT::ShellProxy.send(:new, *args)
        end
      end
    end
  end
end

Version data entries

41 entries across 41 versions & 2 rubygems

Version Path
glimmer-dsl-swt-0.3.0 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.2.4 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.2.3 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.2.2 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.2.1 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.2.0 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.1.3 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.1.2 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.1.1 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-dsl-swt-0.1.0 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.8.2 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.8.1 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.8.0 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.8 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.7 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.6 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.5 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.4 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.3 lib/glimmer/dsl/swt/shell_expression.rb
glimmer-0.7.2 lib/glimmer/dsl/swt/shell_expression.rb