<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def run(self):
 """Ejecute the main loop."""


        self.toplevel.protocol("WM_DELETE_WINDOW", self.__on_window_close)
        self.toplevel.mainloop()