public bool? IsBrowserActive(BrowserEnum browser) { BrowserEnum currentBrowser; switch (_current.GetCurrentBrowser()) { case "FirefoxURL": currentBrowser = BrowserEnum.FireFox; break; case "ChromeHTML": currentBrowser = BrowserEnum.Chrome; break; case "SafariURL": currentBrowser = BrowserEnum.Safari; break; case "Opera.Protocol": currentBrowser = BrowserEnum.Opera; break; case "IE.HTTP": currentBrowser = BrowserEnum.InternetExplorer; break; default: return false; } return currentBrowser == browser; }