kktix_status allow run on linux server without tkinter

master
Your Name 2024-03-15 16:05:56 +08:00
parent 133c3c86c2
commit e1884b9f2a
3 changed files with 22 additions and 13 deletions

View File

@ -8,10 +8,13 @@ try:
from Tkinter import * from Tkinter import *
except ImportError: except ImportError:
# for Python3 # for Python3
try:
from tkinter import * from tkinter import *
from tkinter import ttk from tkinter import ttk
from tkinter import messagebox from tkinter import messagebox
from tkinter import filedialog from tkinter import filedialog
except Exception as e:
pass
import base64 import base64
import json import json

View File

@ -9,10 +9,13 @@ try:
from Tkinter import * from Tkinter import *
except ImportError: except ImportError:
# for Python3 # for Python3
try:
from tkinter import * from tkinter import *
from tkinter import ttk from tkinter import ttk
from tkinter import messagebox from tkinter import messagebox
from tkinter import filedialog from tkinter import filedialog
except Exception as e:
pass
import argparse import argparse
import base64 import base64

View File

@ -7,11 +7,14 @@ try:
from Tkinter import * from Tkinter import *
except ImportError: except ImportError:
# for Python3 # for Python3
try:
from tkinter import * from tkinter import *
from tkinter import ttk from tkinter import ttk
import tkinter.font as tkfont import tkinter.font as tkfont
from tkinter import messagebox from tkinter import messagebox
from tkinter.filedialog import asksaveasfilename from tkinter.filedialog import asksaveasfilename
except Exception as e:
pass
''' '''
try: try:
import customtkinter import customtkinter