diff options
author | Anton Khirnov <wyskas@gmail.com> | 2009-04-30 14:31:57 +0200 |
---|---|---|
committer | Anton Khirnov <wyskas@gmail.com> | 2009-04-30 14:31:57 +0200 |
commit | 298bd38348390bbef34c65b9e008a87264ade5e2 (patch) | |
tree | ec76646de3289dcc8056fc955a1aab615ef97c1f | |
parent | de61cf6798d542e9433e6cef6837cdff2501a5f7 (diff) |
PlayControl: support single and consume modes.
-rw-r--r-- | gfx/consume.png | bin | 0 -> 1674 bytes | |||
-rw-r--r-- | gfx/single.png | bin | 0 -> 1580 bytes | |||
-rw-r--r-- | nephilim/plugins/PlayControl.py | 12 |
3 files changed, 12 insertions, 0 deletions
diff --git a/gfx/consume.png b/gfx/consume.png Binary files differnew file mode 100644 index 0000000..4a4b14e --- /dev/null +++ b/gfx/consume.png diff --git a/gfx/single.png b/gfx/single.png Binary files differnew file mode 100644 index 0000000..fcd96d5 --- /dev/null +++ b/gfx/single.png diff --git a/nephilim/plugins/PlayControl.py b/nephilim/plugins/PlayControl.py index 6f0f246..29da5fd 100644 --- a/nephilim/plugins/PlayControl.py +++ b/nephilim/plugins/PlayControl.py @@ -34,6 +34,8 @@ class wgPlayControl(QtGui.QToolBar): vol_slider = None repeat = None random = None + single = None + consume = None p = None class VolumeSlider(QtGui.QSlider): @@ -86,6 +88,16 @@ class wgPlayControl(QtGui.QToolBar): self.connect(self.p.mpclient(), QtCore.SIGNAL('repeat_changed'), self.repeat.setChecked) self.connect(self.repeat, QtCore.SIGNAL('toggled(bool)'), self.p.mpclient().repeat) + self.single = self.addAction(QtGui.QIcon('gfx/single.png'), 'single mode') + self.single.setCheckable(True) + self.connect(self.p.mpclient(), QtCore.SIGNAL('single_changed'), self.single.setChecked) + self.connect(self.single, QtCore.SIGNAL('toggled(bool)'), self.p.mpclient().single) + + self.consume = self.addAction(QtGui.QIcon('gfx/consume.png'), 'consume mode') + self.consume.setCheckable(True) + self.connect(self.p.mpclient(), QtCore.SIGNAL('consume_changed'), self.consume.setChecked) + self.connect(self.consume, QtCore.SIGNAL('toggled(bool)'), self.p.mpclient().consume) + self.connect(self, QtCore.SIGNAL('orientationChanged(Qt::Orientation)'), self.vol_slider.setOrientation) self.connect(self.p.mpclient(), QtCore.SIGNAL('state_changed'), self.onStateChange) |