Method: Player#initialize
- Defined in:
- lib/mdisc/player.rb
#initialize ⇒ Player
Returns a new instance of Player.
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/mdisc/player.rb', line 10 def initialize self.ui = Ui.new @datatype = 'songs' @mpg123_thread = nil @mpg123_pid = nil = false @pause_flag = false @songs = [] @idx = 0 @carousel = ->(left, right, x){x < left ? right : (x > right ? left : x)} end |