Simple Bug Fixing and Simple Linux Support
This commit is contained in:
parent
79259d80ae
commit
0a1772ea5e
8
main.py
8
main.py
|
@ -1,4 +1,5 @@
|
|||
import customtkinter as Ctk
|
||||
import platform
|
||||
from icons.icons import Icons
|
||||
|
||||
import scripts.get_sys_info as system_code
|
||||
|
@ -25,9 +26,10 @@ class App(Ctk.CTk):
|
|||
self.font_entry = Ctk.CTkFont(family="Berlin Sans FB", size=18)
|
||||
self.minsize(1000, 750)
|
||||
self.geometry(f"{system_code.window_width}x{system_code.window_height}")
|
||||
icon_path = self.icons.get_icon_path()
|
||||
self.iconbitmap(icon_path)
|
||||
self.after(1, self.wm_state, system_code.window_state)
|
||||
if platform.system() == "Windows":
|
||||
icon_path = self.icons.get_icon_path()
|
||||
self.iconbitmap(icon_path)
|
||||
self.after(1, self.wm_state, system_code.window_state)
|
||||
self.back_btn_image = self.icons.get_image("BackButton")
|
||||
self.title("MPENN")
|
||||
self.protocol('WM_DELETE_WINDOW', self.close_attempt)
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import customtkinter as Ctk
|
||||
import scripts.get_sys_info as system_code
|
||||
import platform
|
||||
from icons.icons import Icons
|
||||
|
||||
|
||||
|
@ -11,9 +12,10 @@ class ClosePopup(Ctk.CTkToplevel):
|
|||
self.my_font = Ctk.CTkFont(family="Berlin Sans FB", size=22)
|
||||
self.geometry("400x300")
|
||||
self.resizable(False, False)
|
||||
icon_path = self.icons.get_icon_path()
|
||||
self.iconbitmap(icon_path)
|
||||
self.after(201, lambda: self.iconbitmap(icon_path))
|
||||
if platform.system() == "Windows":
|
||||
icon_path = self.icons.get_icon_path()
|
||||
self.iconbitmap(icon_path)
|
||||
self.after(201, lambda: self.iconbitmap(icon_path))
|
||||
self.callback = callback
|
||||
self.label = Ctk.CTkLabel(self, text="Do you want to leave?\n You might lose some Data", font=self.my_font)
|
||||
# Add exit button
|
||||
|
|
|
@ -156,7 +156,7 @@ def set_theme():
|
|||
|
||||
|
||||
data_path = create_folder("MPENNconfigs")
|
||||
json_file_path = data_path + "./program.json"
|
||||
json_file_path = data_path + "/program.json"
|
||||
theme = Theme(path=data_path)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue