ektoplayer 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ektoplayer/application.rb +2 -2
- data/lib/ektoplayer/operations/playlist.rb +8 -6
- data/lib/ektoplayer/trackloader.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: df13d5e7cb639805cb5a974d6c6e139026080839
|
4
|
+
data.tar.gz: fe7d880c84897d5ab4543af17438ea6edcd214b8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 24bf8f5c2f04a43862146b218493716196c29cd4646f0c0db21d79786249178c6a89993975e68660a245265f548efdb5c1aaaf87eaa82862e50f9b873f173b20
|
7
|
+
data.tar.gz: 7bee87109a42bcb4e06be0ea4d50bc1f19243ab315494598fe5f6e540dd874f034e491f6f12f26d38f1fdc05004426757fa8d5c038862fd4f6499786b3d54fb5
|
@@ -10,7 +10,7 @@ require 'date'
|
|
10
10
|
|
11
11
|
module Ektoplayer
|
12
12
|
class Application
|
13
|
-
VERSION = '0.1'.freeze
|
13
|
+
VERSION = '0.1.1'.freeze
|
14
14
|
GITHUB_URL = 'https://github.com/braph/ektoplayer'.freeze
|
15
15
|
EKTOPLAZM_URL = 'http://www.ektoplazm.com'.freeze
|
16
16
|
|
@@ -23,7 +23,7 @@ module Ektoplayer
|
|
23
23
|
$stderr.puts("#{DateTime.now.rfc3339} #{from}.#{func}: " + msgs.join(' '))
|
24
24
|
|
25
25
|
if e = msgs.select { |m| m.kind_of?Exception }[0]
|
26
|
-
$stderr.puts "#{e.backtrace.first}: #{e.message} (#{e.class})", e.backtrace.
|
26
|
+
$stderr.puts "#{e.backtrace.first}: #{e.message} (#{e.class})", e.backtrace.join(?\n)
|
27
27
|
end
|
28
28
|
$stderr.flush
|
29
29
|
end
|
@@ -16,23 +16,25 @@ module Ektoplayer
|
|
16
16
|
def download_album(index)
|
17
17
|
return unless track = @playlist[index]
|
18
18
|
Thread.new do
|
19
|
-
@trackloader.download_album(track['url'])
|
19
|
+
@trackloader.download_album(track['url']) rescue (
|
20
|
+
Application.log(self, $!)
|
21
|
+
)
|
20
22
|
end
|
21
23
|
end
|
22
24
|
|
23
25
|
def reload(index)
|
24
26
|
return unless track = @playlist[index]
|
25
27
|
Thread.new do
|
26
|
-
@trackloader.get_track_file(track['url'], reload: true)
|
28
|
+
@trackloader.get_track_file(track['url'], reload: true) rescue (
|
29
|
+
Application.log(self, $!)
|
30
|
+
)
|
27
31
|
end
|
28
32
|
end
|
29
33
|
|
30
34
|
def play(index)
|
31
35
|
return unless track = @playlist[index]
|
32
|
-
|
33
|
-
|
34
|
-
@player.play(@trackloader.get_track_file(track['url']))
|
35
|
-
end
|
36
|
+
@playlist.current_playing=(index)
|
37
|
+
@player.play(@trackloader.get_track_file(track['url']))
|
36
38
|
end
|
37
39
|
|
38
40
|
def play_next
|