diff --git a/mopidy_touchscreen/graphic_utils/list_view.py b/mopidy_touchscreen/graphic_utils/list_view.py index 28c74ec..22fe9d1 100644 --- a/mopidy_touchscreen/graphic_utils/list_view.py +++ b/mopidy_touchscreen/graphic_utils/list_view.py @@ -87,7 +87,8 @@ class ListView(): self.move_to(direction) else: return int(key) - elif touch_event.type == InputManager.key and self.selected is not None: + elif (touch_event.type == InputManager.key and + self.selected is not None): if touch_event.direction == InputManager.enter: if self.selected is not None: return self.selected diff --git a/mopidy_touchscreen/touch_screen.py b/mopidy_touchscreen/touch_screen.py index d5c19b6..fb0c350 100644 --- a/mopidy_touchscreen/touch_screen.py +++ b/mopidy_touchscreen/touch_screen.py @@ -25,18 +25,19 @@ class TouchScreen(pykka.ThreadingActor, core.CoreListener): self.fullscreen = config['touchscreen']['fullscreen'] self.screen_size = (config['touchscreen']['screen_width'], config['touchscreen']['screen_height']) - + if config['touchscreen']['sdl_fbdev'].lower() != "none": os.environ["SDL_FBDEV"] = config['touchscreen']['sdl_fbdev'] if config['touchscreen']['sdl_mousdrv'].lower() != "none": - os.environ["SDL_MOUSEDRV"] = config['touchscreen'][ - 'sdl_mousdrv'] + os.environ["SDL_MOUSEDRV"] = ( + config['touchscreen']['sdl_mousdrv']) if config['touchscreen']['sdl_mousedev'].lower() != "none": os.environ["SDL_MOUSEDEV"] = config['touchscreen']['sdl_mousedev'] if config['touchscreen']['sdl_audiodriver'].lower() != "none": - os.environ["SDL_AUDIODRIVER"] = config['touchscreen']['sdl_audiodriver'] + os.environ["SDL_AUDIODRIVER"] = ( + config['touchscreen']['sdl_audiodriver']) os.environ["SDL_PATH_DSP"] = config['touchscreen']['sdl_path_dsp'] pygame.init() diff --git a/tox.ini b/tox.ini index f7bed52..25991bd 100644 --- a/tox.ini +++ b/tox.ini @@ -15,4 +15,5 @@ commands = nosetests -v --with-xunit --xunit-file=xunit-{envname}.xml --with-cov deps = flake8 flake8-import-order -commands = flake8 \ No newline at end of file +skip_install = true +commands = flake8