From 1a9b71298b5a9cc098521186feb06a1c876e8e9c Mon Sep 17 00:00:00 2001 From: Juan Pablo Kutianski Date: Thu, 27 May 2021 23:32:50 -0300 Subject: [PATCH] Remove the first tab until the list of tabs is empty --- src/main/python/macro_recorder.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/python/macro_recorder.py b/src/main/python/macro_recorder.py index 039ee8e..83c8e5b 100644 --- a/src/main/python/macro_recorder.py +++ b/src/main/python/macro_recorder.py @@ -90,8 +90,8 @@ class MacroRecorder(BasicEditor): self.keyboard = self.device.keyboard # only show the number of macro editors that keyboard supports - for x in range(self.tabs.count()): - self.tabs.removeTab(x) + while self.tabs.count() > 0: + self.tabs.removeTab(0) for x, w in enumerate(self.macro_tab_w[:self.keyboard.macro_count]): self.tabs.addTab(w, "")