title: How to dismiss an AlertDialog on a FlatButton click?
body: <p>I have the following <code>AlertDialog</code>.</p>
  
  <pre><code>showDialog(
              context: context,
              child: new AlertDialog(
                title: const Text("Location disabled"),
                content: const Text(
                    """
  Location is disabled on this device. Please enable it and try again.
                    """),
                actions: [
                  new FlatButton(
                    child: const Text("Ok"),
                    onPressed: _dismissDialog,
                  ),
                ],
              ),
          );
  </code></pre>
  
  <p>How can I make <code>_dismissDialog()</code> dismiss said <code>AlertDialog</code>?</p>