active application detection