First try at starting on the UI
[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 can_navigate(self):
38                 return True
39
40         @property
41         def state(self):
42                 return "play"
43
44         @property
45         def background(self):
46                 return "night_temple_background"
47
48         def play(self):
49                 _moduleLogger.info("play")
50
51         def pause(self):
52                 _moduleLogger.info("pause")
53
54         def stop(self):
55                 _moduleLogger.info("stop")
56
57         def back(self):
58                 _moduleLogger.info("back")
59
60         def next(self):
61                 _moduleLogger.info("next")
62
63
64 gobject.type_register(Player)