Display the dialog, wait until the user presses a button or closes the window, and return the index of the chosen button.
tkinter.simpledialog/SimpleDialog.go
SimpleDialog.go