Public Member Functions | |
| def | __init__ |
| def | AppendTracks |
| def | GetCurrentTrack |
| def | GetSelectedTracks |
| def | GetState |
| def | GotoNextTrack |
| def | RemoveSelected |
| def | ScrollToCurrent |
| def | SetCurrentTrack |
| def | SetState |
| def | Shuffle |
Private Member Functions | |
| def | _DragData |
| def | _DragReceive |
| def | _FillAndHighlight |
| def | _onClick |
| def | _Refresh |
Private Attributes | |
| _curtrackref | |
| _store | |
| _view | |
One of the playlists in tabs on the right of the window.
Definition at line 11 of file playlist.py.
| def __init__ | ( | self, | ||
| widget | ||||
| ) |
| def _DragData | ( | self, | ||
| widget, | ||||
| context, | ||||
| sel, | ||||
| info, | ||||
| time | ||||
| ) | [private] |
Callback for drag and drop. Provides a pickled list of Track objects.
Definition at line 178 of file playlist.py.
| def _DragReceive | ( | self, | ||
| widget, | ||||
| context, | ||||
| x, | ||||
| y, | ||||
| sel, | ||||
| info, | ||||
| time | ||||
| ) | [private] |
Callback for drag and drop. Expects drag data to be a pickled list of Track objects, as provided by CollectionTree.DragData() or by self.DragData().
Definition at line 143 of file playlist.py.
| def _FillAndHighlight | ( | self, | ||
| col, | ||||
| renderer, | ||||
| model, | ||||
| it, | ||||
| data | ||||
| ) | [private] |
Private, for use by the renderer to extract text from the Track object and draw the current track highlighted.
Definition at line 96 of file playlist.py.
| def _onClick | ( | self, | ||
| widget, | ||||
| event | ||||
| ) | [private] |
Handler for clicks on playlist. Responds to right-click by popping-up the context menu.
Definition at line 219 of file playlist.py.
| def _Refresh | ( | self | ) | [private] |
| def AppendTracks | ( | self, | ||
| tracks | ||||
| ) |
Appends 'tracks' to the playlist. Returns an iterator to the first Track appended.
Definition at line 126 of file playlist.py.
| def GetCurrentTrack | ( | self | ) |
Returns the current (highlighted) Track object if it exists, None otherwise.
Definition at line 44 of file playlist.py.
| def GetSelectedTracks | ( | self | ) |
Returns a list of Track objects representing the selected tracks.
Definition at line 171 of file playlist.py.
| def GetState | ( | self | ) |
Returns a representation of the playlist's state. Form is currently ([tracks],currentpath).
Definition at line 183 of file playlist.py.
| def GotoNextTrack | ( | self | ) |
Moves onto the next track in the playlist if possible. Returns a boolean indicating success.
Definition at line 83 of file playlist.py.
| def RemoveSelected | ( | self | ) |
Removes the currently selected tracks from the playlist. Returns whether the currently playing track was removed.
Definition at line 202 of file playlist.py.
| def ScrollToCurrent | ( | self | ) |
Scroll the playlist until the current track is 1/3 of the way down.
Definition at line 119 of file playlist.py.
| def SetCurrentTrack | ( | self, | ||
| it | ||||
| ) |
Sets the current track to the one pointed to by the gtk iterator 'it'. 'it' may be None.
Definition at line 51 of file playlist.py.
| def SetState | ( | self, | ||
| state | ||||
| ) |
Initialises playlist to the state returned by GetState().
Definition at line 191 of file playlist.py.
| def Shuffle | ( | self | ) |
Removes everything from the playlist and puts it back in a random order.
Definition at line 64 of file playlist.py.
_curtrackref [private] |
Definition at line 32 of file playlist.py.
_store [private] |
Definition at line 16 of file playlist.py.
_view [private] |
Definition at line 15 of file playlist.py.
1.5.1