Class: Shul::Shule::Radio

Inherits:
Component show all
Defined in:
lib/shul.rb

Instance Method Summary collapse

Methods inherited from Box

#append_child, #deep_clone, #obj, #obj=, #remove

Constructor Details

#initialize(name = 'radio', attributes: nil, rexle: nil) ⇒ Radio

Returns a new instance of Radio.



192
193
194
195
196
197
# File 'lib/shul.rb', line 192

def initialize(name='radio', attributes: nil, rexle: nil)

  h = {label: '', value: ''}
  h.merge!(attributes) if attributes
  super(name, attributes: VisualAttributes.new(h), rexle: rexle)
end

Instance Method Details

#checkedObject



199
200
201
202
203
# File 'lib/shul.rb', line 199

def checked

  self.obj.contents[0].checked = true

end