entering foreground works