annotate vixm/player.py @ 30:860c891de6bb master

Remove lots of xmms-related code & get ready to make the whole program a standalone player
author Josef "Jeff" Sipek <jeffpc@josefsipek.net>
date Fri, 03 Nov 2006 22:49:09 -0500
parents
children f97eb9f0c207
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
30
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
1 import time
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
2 from threading import Thread
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
3
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
4 class playerThread(Thread):
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
5 def __init__(self, lists):
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
6 Thread.__init__(self)
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
7
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
8 self.shutdown = False
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
9
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
10 self.lists = lists
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
11
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
12 def run(self):
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
13 while not self.shutdown:
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
14 time.sleep(0.5)
860c891de6bb Remove lots of xmms-related code & get ready to make the whole program a
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
diff changeset
15