Commit f78e782f authored by Jean Felder's avatar Jean Felder Committed by Marinus Schraal

player: Remove some unused attributes and methods

parent d8583bf7
......@@ -83,8 +83,6 @@ class PlayerPlaylist(GObject.GObject):
'song-validated': (GObject.SignalFlags.RUN_FIRST, None, (int, int)),
}
_nb_songs_max = 10
repeat_mode = GObject.Property(type=int, default=RepeatMode.NONE)
def __repr__(self):
......@@ -97,8 +95,6 @@ class PlayerPlaylist(GObject.GObject):
GstPbutils.pb_utils_init()
self._app = application
self._songs = []
self._shuffle_indexes = []
self._position = 0
self._type = -1
......@@ -113,25 +109,6 @@ class PlayerPlaylist(GObject.GObject):
self.connect("notify::repeat-mode", self._on_repeat_mode_changed)
@log
def set_playlist(self, playlist_type, playlist_id, model, model_iter=None):
"""Set a new playlist or change the song being played
If no song is requested (through model_iter), a song will be
automatically selected:
* the first song in a linear mode
* a random song in shuffle mode
:param PlayerPlaylist.Type playlist_type: playlist type
:param string playlist_id: unique identifer to recognize the playlist
:param GtkListStore model: list of songs to play
:param GtkTreeIter model_iter: requested song
:return: True if the playlist has been updated. False otherwise
:rtype: bool
"""
pass
@log
def change_position(self, prev_pos, new_pos):
"""Change order of a song in the playlist
......@@ -519,21 +496,6 @@ class Player(GObject.GObject):
else:
self.play()
@log
def set_playlist(self, playlist_type, playlist_id, model, iter_=None):
"""Set a new playlist or change the song being played.
:param PlayerPlaylist.Type playlist_type: playlist type
:param string playlist_id: unique identifer to recognize the playlist
:param GtkListStore model: list of songs to play
:param GtkTreeIter model_iter: requested song
"""
playlist_changed = self._playlist.set_playlist(
playlist_type, playlist_id, model, iter_)
if playlist_changed:
self.emit('playlist-changed')
@log
def playlist_change_position(self, prev_pos, new_pos):
"""Change order of a song in the playlist.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment