Check for isFinishing flag before showing dialog