misc: small fix or general refactoring i did not bother commenting

This commit is contained in:
Simone Margaritelli
2019-11-05 14:48:26 +01:00
parent 0830e0c74b
commit aba5b938bc
5 changed files with 15 additions and 14 deletions

View File

@ -4,8 +4,6 @@ import threading
import pwnagotchi.plugins as plugins
import pwnagotchi.ui.hw as hw
import pwnagotchi.ui.web as web
from pwnagotchi.ui.web.server import Server
from pwnagotchi.ui.view import View
@ -16,7 +14,6 @@ class Display(View):
self._enabled = config['enabled']
self._rotation = config['rotation']
self._webui = Server(config)
self.init_display()
@ -28,6 +25,9 @@ class Display(View):
)
self._render_thread_instance.start()
def set_ready(self):
self._webui.start()
def is_inky(self):
return self._implementation.name == 'inky'
@ -90,7 +90,6 @@ class Display(View):
self._implementation.render(self._canvas_next)
def _on_view_rendered(self, img):
web.update_frame(img)
try:
if self._config['ui']['display']['video']['on_frame'] != '':
os.system(self._config['ui']['display']['video']['on_frame'])