diff options
author | Eddy Pedroni <eddy@0xf7.com> | 2021-12-22 11:50:49 +0100 |
---|---|---|
committer | Eddy Pedroni <eddy@0xf7.com> | 2021-12-22 11:50:49 +0100 |
commit | d2c7f3d44cb791a7db9ed9a11b0fa30d1eee5f0e (patch) | |
tree | 8fb1caa5c79b7d4f5c666d42151e0768e00a4cfc /solo_tool.py | |
parent | 96a574d317ccbbff3af3f1a20755c3b79f873510 (diff) |
Added integration test, updated diagram
Diffstat (limited to 'solo_tool.py')
-rw-r--r-- | solo_tool.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/solo_tool.py b/solo_tool.py index 53670fb..538d558 100644 --- a/solo_tool.py +++ b/solo_tool.py @@ -1,3 +1,5 @@ +import os + from playlist import Playlist from abcontroller import ABController from session_manager import SessionManager @@ -22,7 +24,8 @@ class SoloTool: self._abController.positionChanged(position) def addSong(self, path): - self._sessionManager.addSong(path) + if os.path.isfile(path): + self._sessionManager.addSong(path) def setSong(self, index): self._playlist.setCurrentSong(index) @@ -44,7 +47,6 @@ class SoloTool: with open(path, "w") as f: self._sessionManager.saveSession(f) - # Playback control def play(self): self._player.play() |