Replace CustomOutput with override for LocalOutput

This commit is contained in:
Thomas Adamcik 2011-04-25 17:14:31 +02:00
parent ebe9bba9a9
commit 1c233a3f8a
3 changed files with 6 additions and 8 deletions

View File

@ -1,14 +1,12 @@
from mopidy import settings
from mopidy.gstreamer import BaseOutput
class LocalAudioOutput(BaseOutput):
class LocalOutput(BaseOutput):
def describe_bin(self):
if settings.LOCALOUTPUT_OVERRIDE:
return settings.LOCALOUTPUT_OVERRIDE
return 'autoaudiosink'
class CustomOutput(BaseOutput):
def describe_bin(self):
return settings.CUSTOM_OUTPUT
class NullOutput(BaseOutput):
def describe_bin(self):
return 'fakesink'

View File

@ -70,8 +70,8 @@ FRONTENDS = (
#:
#: Default::
#:
#: CUSTOM_OUTPUT = None
CUSTOM_OUTPUT= None
#: LOCALOUTPUT_OVERRIDE = None
LOCALOUTPUT_OVERRIDE = None
#: Your `Last.fm <http://www.last.fm/>`_ username.
#:

View File

@ -97,7 +97,7 @@ def validate_settings(defaults, settings):
'DUMP_LOG_FILENAME': 'DEBUG_LOG_FILENAME',
'DUMP_LOG_FORMAT': 'DEBUG_LOG_FORMAT',
'FRONTEND': 'FRONTENDS',
'GSTREAMER_AUDIO_SINK': 'CUSTOM_OUTPUT',
'GSTREAMER_AUDIO_SINK': 'LOCALOUTPUT_OVERRIDE',
'LOCAL_MUSIC_FOLDER': 'LOCAL_MUSIC_PATH',
'LOCAL_PLAYLIST_FOLDER': 'LOCAL_PLAYLIST_PATH',
'LOCAL_TAG_CACHE': 'LOCAL_TAG_CACHE_FILE',