private static async void SplashTimer_TickAsync(object sender, EventArgs e) { if (driver == null && splash.Visible) { splashTimer.Stop(); var update = new ChromeDriverUpdater(".\\"); await update.ExecuteAsync(); Bootstrap(); splash.Close(); } }
public MangaHereTests() { var updater = new ChromeDriverUpdater(".\\"); updater.ExecuteAsync().Wait(); source = new CancellationTokenSource(); var options = new ChromeOptions(); options.AddArgument("--window-size=1920,1080"); options.AddArgument("--start-maximized"); options.AddArgument("--headless"); ChromeDriver = new ChromeDriver(options); Wait = new WebDriverWait(ChromeDriver, TimeSpan.FromSeconds(10)); downloader = new HttpDownloader(new FilenameDetector(new GoogleProxyFilenameDetector())); service = new MangaHere(logger.Object, downloader, new XPathSelector(), new Retry(), ChromeDriver); }
public async void UpdateAsync() { var driverUpdate = new ChromeDriverUpdater(".\\"); await driverUpdate.ExecuteAsync(); }