public ExitToCharacterSelectionHandler( IMediator mediator, INativeProcess nativeProcess) { this.mediator = mediator; this.nativeProcess = nativeProcess; }
public WhisperService( INativeProcess pathOfExileProcess, IChatService chatService) { this.pathOfExileProcess = pathOfExileProcess; this.chatService = chatService; }
public KeybindsProvider( INativeProcess nativeProcess, ISidekickSettings settings) { this.nativeProcess = nativeProcess; this.settings = settings; }
protected override async void OnStartup(StartupEventArgs e) { MainWindow = new SplashScreen.SplashScreen(); MainWindow.Show(); base.OnStartup(e); AttachErrorHandlers(); // Tooltip opened indefinitely until mouse is moved. ToolTipService.ShowDurationProperty.OverrideMetadata(typeof(DependencyObject), new FrameworkPropertyMetadata(int.MaxValue)); serviceProvider = Wpf.Startup.InitializeServices(this); logger = serviceProvider.GetRequiredService <ILogger <App> >(); nativeProcess = serviceProvider.GetRequiredService <INativeProcess>(); mediator = serviceProvider.GetRequiredService <IMediator>(); TrayIcon = (TaskbarIcon)FindResource("TrayIcon"); TrayIcon.DataContext = serviceProvider.GetRequiredService <TrayIconViewModel>(); EnsureSingleInstance(); MainWindow.Close(); await mediator.Send(new InitializeCommand(true)); }
public ScrollStashDownHandler( IKeybindsProvider keybindsProvider, INativeProcess nativeProcess) { this.keybindsProvider = keybindsProvider; this.nativeProcess = nativeProcess; }
public GoToHideoutHandler( IMediator mediator, INativeProcess nativeProcess) { this.mediator = mediator; this.nativeProcess = nativeProcess; }
public CustomChatHandler( IMediator mediator, INativeProcess nativeProcess) { this.mediator = mediator; this.nativeProcess = nativeProcess; }
public KeybindsInitializationStartedHandler( INativeProcess nativeProcess, IKeybindsProvider keybindsProvider, IKeybindsExecutor keybindsExecutor) { this.nativeProcess = nativeProcess; this.keybindsProvider = keybindsProvider; this.keybindsExecutor = keybindsExecutor; }
public KeybindEvents(ILogger logger, INativeProcess nativeProcess, SidekickSettings configuration, INativeKeyboard nativeKeyboard) { this.logger = logger; this.nativeProcess = nativeProcess; this.configuration = configuration; this.nativeKeyboard = nativeKeyboard; }
public LeavePartyHandler( ISidekickSettings settings, ILogger <LeavePartyHandler> logger, IMediator mediator, INativeProcess nativeProcess) { this.settings = settings; this.logger = logger; this.mediator = mediator; this.nativeProcess = nativeProcess; }
public UpdateManager(IHttpClientFactory httpClientFactory, IInitializer initializer, INativeProcess nativeProcess) { _httpClient = httpClientFactory.CreateClient(); _httpClient.BaseAddress = new Uri("https://api.github.com"); _httpClient.DefaultRequestHeaders.UserAgent.TryParseAdd("request"); _httpClient.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json")); this.initializer = initializer; this.nativeProcess = nativeProcess; }
public KeybindEvents(ILogger logger, INativeProcess nativeProcess, SidekickSettings configuration, INativeKeyboard nativeKeyboard, IStashService stashService, HookProvider hookProvider) { this.logger = logger.ForContext(GetType()); this.nativeProcess = nativeProcess; this.configuration = configuration; this.nativeKeyboard = nativeKeyboard; this.stashService = stashService; this.hookProvider = hookProvider; }
protected override async void OnStartup(StartupEventArgs e) { Instance = this; base.OnStartup(e); AttachErrorHandlers(); // Tooltip opened indefinitely until mouse is moved. ToolTipService.ShowDurationProperty.OverrideMetadata(typeof(DependencyObject), new FrameworkPropertyMetadata(int.MaxValue)); serviceProvider = Sidekick.Startup.InitializeServices(this); logger = serviceProvider.GetRequiredService <ILogger>(); nativeProcess = serviceProvider.GetRequiredService <INativeProcess>(); nativeBrowser = serviceProvider.GetRequiredService <INativeBrowser>(); leagueDataService = serviceProvider.GetRequiredService <ILeagueDataService>(); initializer = serviceProvider.GetRequiredService <IInitializer>(); viewLocator = serviceProvider.GetRequiredService <IViewLocator>(); settings = serviceProvider.GetRequiredService <SidekickSettings>(); trayIcon = (TaskbarIcon)FindResource("TrayIcon"); trayIcon.DataContext = serviceProvider.GetRequiredService <TrayIconViewModel>(); await RunAutoUpdate(); EnsureSingleInstance(); leagueDataService.OnNewLeagues += () => { Dispatcher.Invoke(() => { AdonisUI.Controls.MessageBox.Show(InitializerResources.Warn_NewLeagues, buttons: AdonisUI.Controls.MessageBoxButton.OK); }); }; if (settings.ShowSplashScreen) { initializer.OnProgress += (a) => { if (!viewLocator.IsOpened <SplashScreenView>()) { Dispatcher.Invoke(() => { viewLocator.Open <SplashScreenView>(); }); } }; } initializer.OnError += (error) => { AdonisUI.Controls.MessageBox.Show(InitializerResources.ErrorDuringInit, buttons: AdonisUI.Controls.MessageBoxButton.OK); base.Shutdown(1); }; await initializer.Initialize(); trayIcon.ShowBalloonTip( TrayResources.Notification_Title, string.Format(TrayResources.Notification_Message, settings.Key_CheckPrices.ToKeybindString(), settings.Key_CloseWindow.ToKeybindString()), trayIcon.Icon, largeIcon: true); serviceProvider.GetRequiredService <EventsHandler>(); }
public GetLatestWhisperCharacterNameHandler( INativeProcess nativeProcess) { this.nativeProcess = nativeProcess; }
public WhisperService(INativeProcess pathOfExileProcess) { this.pathOfExileProcess = pathOfExileProcess; }