Implementing the first stream presenter
[watersofshiloah] / src / player.py
1 import logging
2
3 import gobject
4
5
6 _moduleLogger = logging.getLogger(__name__)
7
8
9 class Player(gobject.GObject):
10
11         __gsignals__ = {
12                 'state_change' : (
13                         gobject.SIGNAL_RUN_LAST,
14                         gobject.TYPE_NONE,
15                         (gobject.TYPE_PYOBJECT, ),
16                 ),
17                 'navigate_change' : (
18                         gobject.SIGNAL_RUN_LAST,
19                         gobject.TYPE_NONE,
20                         (gobject.TYPE_PYOBJECT, ),
21                 ),
22                 'title_change' : (
23                         gobject.SIGNAL_RUN_LAST,
24                         gobject.TYPE_NONE,
25                         (gobject.TYPE_PYOBJECT, ),
26                 ),
27         }
28
29         def __init__(self):
30                 gobject.GObject.__init__(self)
31
32         @property
33         def title(self):
34                 return ""
35
36         @property
37         def subtitle(self):
38                 return ""
39
40         @property
41         def can_navigate(self):
42                 return True
43
44         @property
45         def state(self):
46                 return "play"
47
48         @property
49         def background(self):
50                 return "conference_background"
51
52         def play(self):
53                 _moduleLogger.info("play")
54
55         def pause(self):
56                 _moduleLogger.info("pause")
57
58         def stop(self):
59                 _moduleLogger.info("stop")
60
61         def back(self):
62                 _moduleLogger.info("back")
63
64         def next(self):
65                 _moduleLogger.info("next")
66
67
68 gobject.type_register(Player)