This function is arguably nicer than calling NS_ProcessNextEvent manually, is slightly more efficient, and will enable better auditing for NS_ProcessNextEvent when we do Quantum DOM scheduling changes.