Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 31368a4 commit a80af77Copy full SHA for a80af77
1 file changed
Doc/library/tkinter.rst
@@ -205,6 +205,7 @@ A Simple Hello World Program
205
class Application(tk.Frame):
206
def __init__(self, master=None):
207
super().__init__(master)
208
+ self.master = master
209
self.pack()
210
self.create_widgets()
211
@@ -215,7 +216,7 @@ A Simple Hello World Program
215
216
self.hi_there.pack(side="top")
217
218
self.quit = tk.Button(self, text="QUIT", fg="red",
- command=root.destroy)
219
+ command=self.master.destroy)
220
self.quit.pack(side="bottom")
221
222
def say_hi(self):
0 commit comments