fixed exit from app and focus at start