[FIX] hw_drivers: Display slowed IoT Box down

In DisplayDriver, we setup a loop to refresh the display every minute
if the url shown is not the customer display. If the customer display
was used, the loop didn't wait a minute and looped indefinitely,
without sleeping. This slowed down the whole box and explains why
receipts took a long time to print with older versions of Odoo and why
the framerate of the curomer display was so low.

closes odoo/odoo#36670

Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
This commit is contained in:
Antoine Prieels
2019-09-11 08:38:36 +00:00
parent 570566b674
commit 0bf6fb0519
+1 -1
View File
@@ -68,9 +68,9 @@ class DisplayDriver(Driver):
def run(self):
while True:
time.sleep(60)
if self.url != 'http://localhost:8069/point_of_sale/display/':
# Refresh the page every minute
time.sleep(60)
self.call_xdotools('F5')
def update_url(self, url=None):