Now global showDialog status are blocked.  showDialog will be executed only when it is necessary.