Class: Bowline::Window

Inherits:
Object show all
Defined in:
lib/bowline/window.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(obj = self.class.window) ⇒ Window

Returns a new instance of Window.



7
8
9
# File 'lib/bowline/window.rb', line 7

def initialize(obj = self.class.window)
  @object = obj
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(*args) ⇒ Object



11
12
13
14
15
16
17
# File 'lib/bowline/window.rb', line 11

def method_missing(*args)
  Bowline.logger.info "Sending to Window: #{args.inspect}"
  if defined?(Titanium)        
    @object = @object.send(*args)
  end
  self
end

Class Method Details

.windowObject



3
4
5
# File 'lib/bowline/window.rb', line 3

def self.window
  defined?(Titanium) && Titanium.UI.mainWindow.window
end