fix bug when there is no screen active