internal BackgroundRecorder(IWebDriver driver, IBrowserActionLogger logger, TimeSpan scanInterval)
 {
     this.Driver       = driver;
     this.ScanInterval = scanInterval;
     this.Logger       = logger;
     this.IsRecording  = false;
 }
        public void Record(IBrowserActionLogger logger)
        {
            if (this.IsRecording)
            {
                return;
            }

            this.recorder       = new BackgroundRecorder(this.Driver, logger, Options.RecordingScanInterval);
            this.recorderThread = new Thread(recorder.DoWork)
            {
                IsBackground = true,
                Name         = "BrowserRecorder"
            };

            this.recorder.Start();
            this.recorderThread.Start();
        }