Class: Soundcloud2000::Views::PlayerView
- Defined in:
- lib/soundcloud2000/views/player_view.rb
Constant Summary
Constants inherited from UI::View
UI::View::INTERSECTION, UI::View::LINE_SEPARATOR, UI::View::ROW_SEPARATOR
Instance Attribute Summary
Attributes inherited from UI::View
Instance Method Summary collapse
-
#initialize(*attrs) ⇒ PlayerView
constructor
A new instance of PlayerView.
- #player(instance) ⇒ Object
- #toggle_spectrum ⇒ Object
Methods inherited from UI::View
#body_width, #clear, #padding, #render, #with_color
Constructor Details
#initialize(*attrs) ⇒ PlayerView
Returns a new instance of PlayerView.
8 9 10 11 12 13 |
# File 'lib/soundcloud2000/views/player_view.rb', line 8 def initialize(*attrs) super @spectrum = true padding 2 end |
Instance Method Details
#player(instance) ⇒ Object
15 16 17 |
# File 'lib/soundcloud2000/views/player_view.rb', line 15 def player(instance) @player = instance end |
#toggle_spectrum ⇒ Object
19 20 21 |
# File 'lib/soundcloud2000/views/player_view.rb', line 19 def toggle_spectrum @spectrum = !@spectrum end |