Class: ActiveWindow::ActiveCompositeColumn
- Inherits:
-
ActiveColumn
- Object
- ActiveColumn
- ActiveWindow::ActiveCompositeColumn
- Defined in:
- lib/active_window/active_column.rb
Overview
pack multiple columns into one
Constant Summary
Constants inherited from ActiveColumn
ActiveWindow::ActiveColumn::ClassesToSymbols
Instance Attribute Summary
Attributes inherited from ActiveColumn
Instance Method Summary collapse
- #add(child_column, expand = true) ⇒ Object
-
#initialize(name, opts = {}) ⇒ ActiveCompositeColumn
constructor
A new instance of ActiveCompositeColumn.
- #view ⇒ Object
Methods inherited from ActiveColumn
create, #data_class, #data_value, #hide!, #renderer, #virtual?, #visible?
Constructor Details
#initialize(name, opts = {}) ⇒ ActiveCompositeColumn
Returns a new instance of ActiveCompositeColumn.
199 200 201 202 203 |
# File 'lib/active_window/active_column.rb', line 199 def initialize(name, opts={}) self.name = name @virtual = true @visible = true end |
Instance Method Details
#add(child_column, expand = true) ⇒ Object
207 208 209 210 211 212 213 |
# File 'lib/active_window/active_column.rb', line 207 def add(child_column, =true) raise ArgumentError, "give an ActiveColumn, not #{child_column.inspect}" unless child_column.is_a?(ActiveColumn) child_column.hide! rend = child_column.renderer column.pack_start(rend, ) column.add_attribute(rend, child_column.attribute, child_column.id) end |
#view ⇒ Object
204 205 206 |
# File 'lib/active_window/active_column.rb', line 204 def view column end |