mirror of
https://github.com/Febbweiss/mopidy-touchscreen.git
synced 2026-03-04 22:25:39 +00:00
Lower CPU usage
Screen will not be always updated
This commit is contained in:
@@ -37,8 +37,12 @@ class LibraryScreen(BaseScreen):
|
||||
self.current_directory = directory
|
||||
self.browse_uri(directory)
|
||||
|
||||
def update(self, screen):
|
||||
self.list_view.render(screen)
|
||||
def should_update(self):
|
||||
return self.list_view.should_update()
|
||||
|
||||
def update(self, screen, update_type, rects):
|
||||
update_all = (update_type == BaseScreen.update_all)
|
||||
self.list_view.render(screen, update_all, rects)
|
||||
|
||||
def touch_event(self, touch_event):
|
||||
clicked = self.list_view.touch_event(touch_event)
|
||||
|
||||
Reference in New Issue
Block a user