Class: Shoes::Radio
Instance Method Summary collapse
-
#checked=(bool) ⇒ Object
Marks or unmarks the radio button.
-
#checked? ⇒ Boolean
Returns whether the radio button is checked or not.
-
#click(&blk) ⇒ Object
When the radio button is clicked, its click block is called.
-
#focus ⇒ Object
Moves focus to the radio.
Methods inherited from Native
#displace, #height, #hide, #left, #move, #parent, #remove, #show, #style, #toggle, #top, #width
Instance Method Details
#checked=(bool) ⇒ Object
Marks or unmarks the radio button. Using checked = false, for instance, clears the radio.
221 222 223 |
# File 'lib/blue_shoes/native.rb', line 221 def checked=(bool) throw NotImplementedErrror end |
#checked? ⇒ Boolean
Returns whether the radio button is checked or not. So, true means “yes, it is checked!”
215 216 217 218 |
# File 'lib/blue_shoes/native.rb', line 215 def checked? # returns true or false throw NotImplementedErrror end |
#click(&blk) ⇒ Object
When the radio button is clicked, its click block is called. The block is handed self, which is an object representing the radio which was clicked.
226 227 228 229 |
# File 'lib/blue_shoes/native.rb', line 226 def click(&blk) # returns self throw NotImplementedErrror end |
#focus ⇒ Object
Moves focus to the radio. The radio will be highlighted and, if the user hits Enter, the radio will be toggled between its marked and unmarked states.
232 233 234 235 |
# File 'lib/blue_shoes/native.rb', line 232 def focus # returns self throw NotImplementedErrror end |