diff --git a/main.py b/main.py index 38d594c..c69d6f9 100644 --- a/main.py +++ b/main.py @@ -67,7 +67,6 @@ def saveSettings() -> None : backend.suddenSet(dirSetting.get(),tokenSetting.get()) - VERSION_MENU.destroy() updateVersionList() FRONTEND.event_generate('<>',when='tail') settingsWindow.destroy() @@ -94,13 +93,14 @@ global VERSION_MENU global strvar updatedList = backend.verOptions(mono.get(),CUR_VERSION) - if CUR_VERSION != updatedList : + if CUR_VERSION != updatedList or VERSION_MENU.winfo_exists() : CUR_VERSION = updatedList strvar = tk.StringVar(CANVAS,CUR_VERSION[0]) VERSION_MENU = ttk.Combobox(master=CANVAS,textvariable=strvar,values=CUR_VERSION,state='readonly',font="Sans 12",style='M.TCombobox') VERSION_MENU.bind('<>',isInstalled) VERSION_MENU.bind('',isInstalled) VERSION_MENU.place(width=256,height=36,relx=0.31,y=120) + isInstalled() def setMono() -> None :