title: iconify in tkinter in python
body: <p>I have written a code in python 2.7 and i have created a root window with two buttons: <strong>submit</strong> and <strong>cancel</strong> when i press <strong>submit</strong> button, a new window opens and previous parent/root window gets iconify. Now i want that when i cut the child window, parent window should be deiconify, i am in a trouble that where to put the condition so that parent window gets deiconify? </p>
  
  <pre><code>from Tkinter import *
  
  root = Tk()
  root.title("test window")
  root.geometry('400x220+500+250')
  root.configure(background="dark gray")
  
  def submit(*args):
      root.iconify()
      popup_root_window = Toplevel()
      popup_root_window.geometry('300x50+550+300')
      popup_root_window.resizable(width=False, height=False)
      popup_root_window.focus_force()
      popup_root_window.grab_set()
      popup_root_window_label = Label(popup_root_window, text="new window open successfully.")
      popup_root_window_label.pack(anchor=CENTER, padx=10, pady=20)
  
  frame = Frame(root, bd=4, relief="raise", height=100, width=250)
  frame.pack(fill="both", padx=70, pady=35)
  frame.pack_propagate(0)
  
  submit_button = Button(frame, text="Submit", command=submit, width=10)
  submit_button.grid(row=0, column=0)
  
  cancel_button = Button(frame, text="Cancel", width=10)
  cancel_button.grid(row=0, column=1)
  
  root.mainloop()
  </code></pre>