~andrewsomething/exaile/karmic

« back to all changes in this revision

Viewing changes to xlgui/prefs/playback_prefs.py

  • Committer: Aren Olson
  • Date: 2009-09-12 00:36:59 UTC
  • Revision ID: reacocard@gmail.com-20090912003659-w373sg0n04uoa8op
remove useless files, add soem of the fixes from lp bug 420019

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2006 Adam Olsen
2
 
#
3
 
# This program is free software; you can redistribute it and/or modify
4
 
# it under the terms of the GNU General Public License as published by
5
 
# the Free Software Foundation; either version 1, or (at your option)
6
 
# any later version.
7
 
#
8
 
# This program is distributed in the hope that it will be useful,
9
 
# but WITHOUT ANY WARRANTY; without even the implied warranty of
10
 
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
 
# GNU General Public License for more details.
12
 
#
13
 
# You should have received a copy of the GNU General Public License
14
 
# along with this program; if not, write to the Free Software
15
 
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
 
 
17
 
from xlgui.prefs import widgets
18
 
from xl import xdg
19
 
from xl.nls import gettext as _
20
 
from xlgui import commondialogs
21
 
 
22
 
name = _('Playback')
23
 
glade = xdg.get_data_path('glade/playback_prefs_pane.glade')
24
 
 
25
 
class EnginePreference(widgets.ComboPrefsItem):
26
 
    default = "normal"
27
 
    name = 'player/engine'
28
 
    map = ["normal", "unified"]
29
 
    def __init__(self, prefs, widget):
30
 
        widgets.ComboPrefsItem.__init__(self, prefs, widget, use_map=True)
31
 
 
32
 
class AudioSinkPreference(widgets.ComboPrefsItem):
33
 
    default = "auto"
34
 
    name = 'player/audiosink'
35
 
    map = ["auto", "gconf", "alsa", "oss", "pulse", "jack"]
36
 
    def __init__(self, prefs, widget):
37
 
        widgets.ComboPrefsItem.__init__(self, prefs, widget, use_map=True)
38
 
 
39
 
class ResumePreference(widgets.CheckPrefsItem):
40
 
    default = True
41
 
    name = 'player/resume_playback'
42
 
 
43
 
class PausedPreference(widgets.CheckPrefsItem):
44
 
    default = False
45
 
    name = 'player/resume_paused' 
46
 
 
47
 
# The following only work on the Unified engine
48
 
 
49
 
class UserFadeTogglePreference(widgets.CheckPrefsItem):
50
 
    default = False
51
 
    name = 'player/user_fade_enabled' 
52
 
 
53
 
class UserFadeDurationPreference(widgets.SpinPrefsItem):
54
 
    default = 1000
55
 
    name = 'player/user_fade'
56
 
 
57
 
class CrossfadingPreference(widgets.CheckPrefsItem):
58
 
    default = False
59
 
    name = 'player/crossfading'
60
 
 
61
 
class CrossfadeDurationPreference(widgets.SpinPrefsItem):
62
 
    default = 1000
63
 
    name = 'player/crossfade_duration'
64