- interface_root = tk.Tk()\r
- interface_root.protocol("WM_DELETE_WINDOW", on_closing)\r
- interface_root.iconphoto(False, tk.PhotoImage(file=os.path.dirname(os.path.realpath(__file__)) + r'''\static\icons\ppt.png'''))\r
- interface_root.geometry("600x300+300+300")\r
- app = Interface(interface_root)\r
- interface_thread = threading.Thread(target=interface_root.mainloop())\r
- interface_thread.setDaemon(True)\r
- interface_thread.start()\r
+ if interface_root is None:\r
+ interface_root = tk.Tk()\r
+ interface_root.protocol("WM_DELETE_WINDOW", on_closing)\r
+ interface_root.iconphoto(False, tk.PhotoImage(file=os.path.dirname(os.path.realpath(__file__)) + r'''\static\icons\ppt.png'''))\r
+ interface_root.geometry("600x300+300+300")\r
+ app = Interface(interface_root)\r
+ interface_thread = threading.Thread(target=interface_root.mainloop())\r
+ interface_thread.setDaemon(True)\r
+ interface_thread.start()\r