Updated to use windows by process only if top window of application was asked.