Class: FastExt::Window
- Inherits:
-
Object
- Object
- FastExt::Window
- Defined in:
- lib/fast_ext/window.rb
Class Attribute Summary collapse
-
.windows ⇒ Object
Returns the value of attribute windows.
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#tabs ⇒ Object
Returns the value of attribute tabs.
-
#title ⇒ Object
Returns the value of attribute title.
-
#window_kind ⇒ Object
Returns the value of attribute window_kind.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name, opts = {}, &block) ⇒ Window
constructor
:opts => => ‘m_window’, tabs:.
- #tab(name, opts = {}) ⇒ Object
- #wrap_tab ⇒ Object
Constructor Details
#initialize(name, opts = {}, &block) ⇒ Window
:opts => => ‘m_window’, tabs:
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/fast_ext/window.rb', line 17 def initialize(name, opts = {}, &block) self.name = name opts.each_pair do |k,v| self.send "#{k}=", v end self.tabs = self.tabs || [] block.call(self) if block_given? self.wrap_tab self.class.windows[name.to_s] = self end |
Class Attribute Details
.windows ⇒ Object
Returns the value of attribute windows.
8 9 10 |
# File 'lib/fast_ext/window.rb', line 8 def windows @windows end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
14 15 16 |
# File 'lib/fast_ext/window.rb', line 14 def name @name end |
#tabs ⇒ Object
Returns the value of attribute tabs.
14 15 16 |
# File 'lib/fast_ext/window.rb', line 14 def tabs @tabs end |
#title ⇒ Object
Returns the value of attribute title.
14 15 16 |
# File 'lib/fast_ext/window.rb', line 14 def title @title end |
#window_kind ⇒ Object
Returns the value of attribute window_kind.
14 15 16 |
# File 'lib/fast_ext/window.rb', line 14 def window_kind @window_kind end |
Class Method Details
.find(name) ⇒ Object
9 10 11 |
# File 'lib/fast_ext/window.rb', line 9 def find(name) @windows[name.to_s] end |