From 69003682515cdd482b3f3582f28c0e6349dcf48d Mon Sep 17 00:00:00 2001 From: MichaelFitzurka Date: Thu, 31 Mar 2022 10:25:00 -0400 Subject: [PATCH] Displaying invalid value with Error indicator, that way the user can see what is the invalid value and has the option to leave it or change it. --- comictaggerlib/pagelisteditor.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/comictaggerlib/pagelisteditor.py b/comictaggerlib/pagelisteditor.py index 43aa817..8c40bb7 100644 --- a/comictaggerlib/pagelisteditor.py +++ b/comictaggerlib/pagelisteditor.py @@ -284,7 +284,10 @@ class PageListEditor(QWidget): def listEntryText(self, page_dict): text = str(int(page_dict['Image']) + 1) if 'Type' in page_dict: - text += " (" + self.pageTypeNames[page_dict['Type']] + ")" + if page_dict["Type"] in self.pageTypeNames.keys(): + text += " (" + self.pageTypeNames[page_dict['Type']] + ")" + else: + text += " (Error: " + page_dict["Type"] + ")" return text def getPageList(self):