don't look at a device's settings if they aren'y being displayed

avoids unnecessary hid++ calls from the main thread
This commit is contained in:
Daniel Pavel 2012-12-12 20:56:13 +02:00
parent a370afe94b
commit 7617a1ef8e
1 changed files with 4 additions and 4 deletions

View File

@ -155,12 +155,12 @@ def update(frame):
box.foreach(lambda x, _: box.remove(x), None)
return
if not device.settings:
# nothing to do here
if not box.get_visible():
# no point in doing this right now, is there?
return
if not box.get_visible():
# no point in doing this, is there?
if not device.settings:
# nothing to do here
return
force_read = False