public ForegroundWindowGuard() { foregroundMutex.WaitOne(); savedForegroundWindow = Utils.GetForegroundWindow(); }