import tkinter
import customtkinter
import webbrowser
from netlicensing import NetLicensing
from PIL import ImageTk, Image
customtkinter.set_appearance_mode("dark")
customtkinter.set_default_color_theme("green")
app = customtkinter.CTk()
app.geometry("500x400")
app.title('N Spoofer - Login')
app.iconbitmap("utils/appico.ico")
app.resizable(False, False)
def Support():
url = "https://t.me/nsoooooooooo"
webbrowser.open(url)
def register():
print("register")
def show_error_window():
error_window = customtkinter.CTk()
error_window.geometry("300x150")
error_window.title("N Spoofer - Error")
error_window.iconbitmap("utils/appico.ico")
error_window.resizable(False, False)
label = customtkinter.CTkLabel(master=error_window, text="Invalid License")
label.configure(font=('Century Gothic', 15, 'underline'))
label.place(relx=0.5, rely=0.5, anchor=tkinter.CENTER)
button1 = customtkinter.CTkButton(master=error_window, width=120, text="Support", command=Support, corner_radius=8)
button1.place(x=90, y=110)
error_window.mainloop()
def button_function():
key = entry1.get()
API_KEY = '96c612ef-40a8-4016-8365-64c19fb6925b'
image = Image.open("utils/pattern.png")
image = image.resize((500, 400), Image.LANCZOS)
img1 = ImageTk.PhotoImage(image)
l1 = customtkinter.CTkLabel(master=app, image=img1)
l1.pack()
frame = customtkinter.CTkFrame(master=l1, width=220, height=260, corner_radius=15)
frame.place(relx=0.5, rely=0.5, anchor=tkinter.CENTER)
entry1 = customtkinter.CTkEntry(master=frame, width=120, placeholder_text='License Key')
entry1.place(x=50, y=90)
button1 = customtkinter.CTkButton(master=frame, width=120, text="Login", command=button_function, corner_radius=6)
button1.place(x=50, y=170)
button2 = customtkinter.CTkButton(master=frame, width=120, text="Register", command=register, corner_radius=6)
button2.place(x=50, y=210)
app.deiconify()
app.mainloop()