public Shell(IUnityContainer container, IRegionManager regionManager, IAppearanceService appearanceService, IPlaybackService playbackService, IWin32InputService win32InputService, IEventAggregator eventAggregator, INotificationService notificationService, IMetadataService metadataService) { InitializeComponent(); // Dependency injection this.container = container; this.regionManager = regionManager; this.appearanceService = appearanceService; this.playbackService = playbackService; this.win32InputService = win32InputService; this.eventAggregator = eventAggregator; this.notificationService = notificationService; this.metadataService = metadataService; // Flags this.mustPerformClosingTasks = true; // Window this.InitializeWindow(); // Services this.InitializeServicesAsync(); // PubSub Events this.InitializePubSubEvents(); // Commands this.InitializeCommands(); // Tray icon this.InitializeTrayIcon(); }
public Shell(IContainerProvider container, IWindowsIntegrationService windowsIntegrationService, II18nService i18nService, INotificationService notificationService, IWin32InputService win32InputService, IAppearanceService appearanceService, IPlaybackService playbackService, IMetadataService metadataService, ILifetimeService lifetimeService, IEventAggregator eventAggregator) { InitializeComponent(); this.container = container; this.windowsIntegrationService = windowsIntegrationService; this.notificationService = notificationService; this.win32InputService = win32InputService; this.playbackService = playbackService; this.metadataService = metadataService; this.appearanceService = appearanceService; this.i18nService = i18nService; this.lifetimeService = lifetimeService; this.eventAggregator = eventAggregator; this.shellService = container.Resolve <Func <string, string, string, string, string, IShellService> >()( typeof(NowPlaying.NowPlaying).FullName, typeof(FullPlayer.FullPlayer).FullName, typeof(CoverPlayer).FullName, typeof(MicroPlayer).FullName, typeof(NanoPlayer).FullName); this.InitializeServices(); this.InitializeWindows(); this.InitializeTrayIcon(); this.InitializeCommands(); }
public Shell(IUnityContainer container, IWindowsIntegrationService windowsIntegrationService, INotificationService notificationService, IWin32InputService win32InputService, IAppearanceService appearanceService, IPlaybackService playbackService, IMetadataService metadataService, IEventAggregator eventAggregator) { InitializeComponent(); this.container = container; this.windowsIntegrationService = windowsIntegrationService; this.notificationService = notificationService; this.win32InputService = win32InputService; this.playbackService = playbackService; this.metadataService = metadataService; this.appearanceService = appearanceService; this.eventAggregator = eventAggregator; this.shellService = container.Resolve <IShellService>( new ParameterOverride("nowPlayingPage", typeof(NowPlaying.NowPlaying).FullName), new ParameterOverride("fullPlayerPage", typeof(FullPlayer.FullPlayer).FullName), new ParameterOverride("coverPlayerPage", typeof(CoverPlayer).FullName), new ParameterOverride("microplayerPage", typeof(MicroPlayer).FullName), new ParameterOverride("nanoPlayerPage", typeof(NanoPlayer).FullName) ); this.InitializeServices(); this.InitializeWindows(); this.InitializeTrayIcon(); this.InitializeCommands(); }
public Shell(IUnityContainer container, IWindowsIntegrationService windowsIntegrationService, INotificationService notificationService, IWin32InputService win32InputService, IPlaybackService playbackService, IMetadataService metadataService, IRegionManager regionManager, IEventAggregator eventAggregator) { InitializeComponent(); this.container = container; this.windowsIntegrationService = windowsIntegrationService; this.notificationService = notificationService; this.win32InputService = win32InputService; this.playbackService = playbackService; this.metadataService = metadataService; this.regionManager = regionManager; this.eventAggregator = eventAggregator; this.InitializeTrayIcon(); this.InitializeShellWindow(); this.InitializeCommands(); }
public Shell(IUnityContainer container, IWindowsIntegrationService windowsIntegrationService, INotificationService notificationService, IWin32InputService win32InputService, IPlaybackService playbackService, IMetadataService metadataService) { InitializeComponent(); this.container = container; this.windowsIntegrationService = windowsIntegrationService; this.notificationService = notificationService; this.win32InputService = win32InputService; this.playbackService = playbackService; this.metadataService = metadataService; this.ShowNowPlayingCommand = new DelegateCommand(() => this.ShellFrame.Navigate(this.container.Resolve <NowPlayingPage>())); ApplicationCommands.ShowNowPlayingCommand.RegisterCommand(this.ShowNowPlayingCommand); this.ShowFullPlayerCommmand = new DelegateCommand(() => this.ShellFrame.Navigate(this.container.Resolve <FullPlayerPage>())); ApplicationCommands.ShowFullPlayerCommand.RegisterCommand(this.ShowFullPlayerCommmand); this.InitializeTrayIcon(); this.InitializeShellWindow(); }