title: wxpython textentrydialog won't appear
body: <p>I am following a tutorial to try to learn to use Wxpython, so I do not fully understand what is going on yet, but when I run the following code it seems like a text dialog box should appear and ask me for my name, however the dialog box does not appear and thus the nameA variable is not assigned a value so I get the error below. What am I doing wrong?</p>
  
  <p>Python Program:</p>
  
  <pre><code>import wx
  
  class main(wx.Frame):
      def __init__(self, parent, id):
          wx.Frame.__init__(self, parent, id, "Test Window", size = (300, 200))
          panel = wx.Panel(self)
  
          text= wx.TextEntryDialog(None, "What is your name?", "Title", " ")
          if text.ShowModal == wx.ID_OK:
              nameA = text.GetValue()
  
          wx.StaticText(panel, -1, nameA, (10, 10))
  
  
  if __name__ == "__main__":
      app = wx.PySimpleApp()
      frame = main(parent=None, id= -1)
      frame.Show()
      app.MainLoop()
  </code></pre>
  
  <p>The error I recieve:</p>
  
  <pre><code>Traceback (most recent call last):
    File "C:\Users\Taylor Lunt\Desktop\deleteme.py", line 17, in &lt;module&gt;
      frame = main(parent=None, id= -1)
    File "C:\Users\Taylor Lunt\Desktop\deleteme.py", line 12, in __init__
      wx.StaticText(panel, -1, nameA, (10, 10))
  UnboundLocalError: local variable 'nameA' referenced before assignment
  </code></pre>