Call to te appropiate download function depending in the extractor used

This commit is contained in:
Manuel Cortez 2018-02-25 04:55:15 -06:00
parent f7c886a0eb
commit aa8d4dfc0c

View File

@ -146,8 +146,11 @@ class Controller(object):
item.get_download_url() item.get_download_url()
path = self.window.get_destination_path(f) path = self.window.get_destination_path(f)
if path != None: if path != None:
log.debug("downloading %s URL to %s filename" % (item.download_url, path,)) if self.extractor.needs_transcode == True: # Send download to vlc based transcoder
utils.call_threaded(utils.download_file, item.download_url, path) utils.call_threaded(player.player.transcode_audio, item, path)
else:
log.debug("downloading %s URL to %s filename" % (item.download_url, path,))
utils.call_threaded(utils.download_file, item.download_url, path)
def on_set_volume(self, *args, **kwargs): def on_set_volume(self, *args, **kwargs):
volume = self.window.vol_slider.GetValue() volume = self.window.vol_slider.GetValue()