Upd: put insight_rows in the loop when select_row

This commit is contained in:
Hengyu 2023-06-30 12:56:20 +08:00
parent 019215f81d
commit 30433ac4f6

View File

@ -178,7 +178,7 @@ class DraggableList:
# Wait for bottoming out
main.wait_until_stable(self.search_button, timer=Timer(
0.3, count=1), timeout=Timer(1.5, count=5))
0, count=0), timeout=Timer(1.5, count=5))
skip_first_screenshot = True
return True
@ -200,14 +200,6 @@ class DraggableList:
Returns:
If success
"""
result = self.insight_row(
row, main=main, skip_first_screenshot=skip_first_screenshot)
if not result:
return False
button = self.keyword2button(row)
if not button:
return False
logger.info(f'Select row: {row}')
skip_first_screenshot = True
interval = Timer(5)
@ -217,6 +209,14 @@ class DraggableList:
else:
main.device.screenshot()
result = self.insight_row(
row, main=main, skip_first_screenshot=skip_first_screenshot)
if not result:
return False
button = self.keyword2button(row)
if not button:
return False
# End
if self.is_row_selected(button, main=main):
logger.info('Row selected')