-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwindow.py
executable file
·44 lines (26 loc) · 950 Bytes
/
window.py
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import tkinter
class Window():
def __init__(self, message):
self.mainWindow = tkinter.Tk()
self.v = tkinter.StringVar()
self.v.set(message)
self.label = tkinter.Label(self.mainWindow, text='Current Activity: ', font=("Helvetica", 60))
self.label.pack()
self.label2 = tkinter.Label(self.mainWindow, textvariable=self.v, font=("Helvetica", 50), fg='green')
self.label2.pack()
button = tkinter.Button(self.mainWindow, text='Continue...', command=self.mainWindow.destroy).pack()
self.mainWindow.mainloop()
def close(self):
self.mainWindow.destroy()
def changeActivity(self, mess):
global v
v.set(mess)
# windowCreated = False
# try: mainWindow
# except NameError: mainWindow = None
# if mainWindow is None:
# mainWindow = tkinter.Tk()
# windowCreated = True
def changeActivity(mess):
w = Window(mess)
w = Window(' ')