Updated code so that timeline window closes if it is open when the case is
closed.