Do I have to clean up all dialogs 'show' by my activity
<p>In my activity, I show a dialog under some condition like this:</p>

<pre><code>public void showADialog(String title, String msg) {
    if (mIsActivityRunning) {
        new AlertDialog.Builder(this)
        .show();
    }
} 
</code></pre>

<p>My question is what do I need to do to ensure there is no resource leak? From the logcat, i see there is a case where it said a window is leaking or something like that.</p>
