Bug 994040 - Properly wait for notification popups and panels. r=aeftimie, r=amatei, r=hskupin