Sha256: 2a4ed860891540d728b489e5163f3c7ff7e3ed773fcbb8a5ec266f95a1841eae

Contents?: true

Size: 673 Bytes

Versions: 5

Compression:

Stored size: 673 Bytes

Contents

require_relative "window"
require_relative "view/javascript"
require_relative "view/erb"
require_relative "view/resources"

module WebConsole
  class View < Window

    # Properties
    def initialize(window_id = nil, view_id = nil)
      super(window_id)
      @view_id = view_id
    end

    def view_id
      if !@view_id
        if ENV.has_key?(SPLIT_ID_KEY)
          @view_id = ENV[SPLIT_ID_KEY]
        else
          @view_id = split_id
        end
      end
      return @view_id
    end

    private
    
    # Web

    def arguments_with_target(arguments)
      arguments = super(arguments)
      arguments.push(view_id)
      return arguments
    end

  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
webconsole-0.1.18 lib/webconsole/lib/view.rb
webconsole-0.1.17 lib/webconsole/lib/view.rb
webconsole-0.1.16 lib/webconsole/lib/view.rb
webconsole-0.1.15 lib/webconsole/lib/view.rb
webconsole-0.1.14 lib/webconsole/lib/view.rb