[gnome-music] Restart current track when postion more than 3 seconds
- From: Vadim Rutkovsky <vrutkovsky src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music] Restart current track when postion more than 3 seconds
- Date: Mon, 3 Mar 2014 09:49:27 +0000 (UTC)
commit b73ba4b51de9b8d89f8b4826647abf45315a190d
Author: Anton Belka <antonbelka gmail com>
Date: Sun Mar 2 22:05:59 2014 +0300
Restart current track when postion more than 3 seconds
https://bugzilla.gnome.org/show_bug.cgi?id=707457
gnomemusic/player.py | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/gnomemusic/player.py b/gnomemusic/player.py
index c153c27..01e4e2b 100644
--- a/gnomemusic/player.py
+++ b/gnomemusic/player.py
@@ -435,8 +435,12 @@ class Player(GObject.GObject):
if self.prevBtn.get_sensitive() is False:
return
+ position = self.get_position() / 1000000;
+
self.stop()
- self.currentTrack = self._get_previous_track()
+
+ if position < 5:
+ self.currentTrack = self._get_previous_track()
if self.currentTrack:
self.play()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]