X-Git-Url: http://git.maemo.org/git/?p=jamaendo;a=blobdiff_plain;f=jamaui%2Fconsole.py;h=56e795c944a494b999ee2ab72b2016c6bf9abeb7;hp=828558d1d7197c70d88347c6bb4e5700ce3a91be;hb=448d0e465aa5aab0be8c7dab7bfbdaf05be181ac;hpb=e8623acc6ea3b0b3d09d2cc9275b5c574a3887f6 diff --git a/jamaui/console.py b/jamaui/console.py index 828558d..56e795c 100644 --- a/jamaui/console.py +++ b/jamaui/console.py @@ -1,3 +1,26 @@ +#!/usr/bin/env python +# +# This file is part of Jamaendo. +# Copyright (c) 2010 Kristoffer Gronlund +# +# Jamaendo is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# Jamaendo is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Jamaendo. If not, see . +# +# Player code heavily based on http://thpinfo.com/2008/panucci/: +# A resuming media player for Podcasts and Audiobooks +# Copyright (c) 2008-05-26 Thomas Perl +# (based on http://pygstdocs.berlios.de/pygst-tutorial/seeking.html) +# # console interface to jamaui/jamaendo # debugging hack - add . to path @@ -7,7 +30,7 @@ if os.path.isdir(local_module_dir): sys.path.append(local_module_dir) import jamaendo -from jamaui.player import Player, Playlist +from jamaui.player import Player, Playlist, the_player import time import gobject @@ -52,7 +75,7 @@ class Console(object): def play_tracks(self, tracks): playlist = Playlist(tracks) - player = Player() + player = the_player player.play(playlist) while player.playing():