-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathui.py
More file actions
30 lines (27 loc) · 925 Bytes
/
ui.py
File metadata and controls
30 lines (27 loc) · 925 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import tkinter as tk
from tkinter import *
from tkinter import ttk
class Aero( Frame ):
def __init__( self ):
tk.Frame.__init__(self)
self.pack()
self.master.title("My_First_App")
self.button1 = Button( self, text = "CLICK HERE", width = 25,
command = self.new_window )
self.button1.grid( row = 0, column = 1, columnspan = 2, sticky = W+E+N+S )
def new_window(self):
self.newWindow = Aero_Uwu()
class Aero_Uwu(Frame):
def __init__(self):
new =tk.Frame.__init__(self)
new = Toplevel(self)
new.title("Windows_HeHe")
new.button = tk.Button( text = "PRESS TO CLOSE", width = 25,
command = self.close_window )
new.button.pack()
def close_window(self):
self.destroy()
def main():
Aero().mainloop()
if __name__ == '__main__':
main()