public static PlayerEngine Configure(this PlayerEngine playerEngine)
 {
     if (playerEngine != null)
     {
         playerEngine.ConfigureInternal();
     }
     return(playerEngine);
 }
        public PlayListsViewModel()
        {
            this.FileSearchWorker = new FileSearchWorker("PlayList", MediaFile.GetMediaFileViewModel);
            var container = TinyIoCContainer.Current;
            this.playerEngine = container.Resolve<PlayerEngine>();
            this.playerSettings = container.Resolve<PlayerSettings>();
            this.SelectedPlayListFiles = new ObservableCollection<IMediaFile>();

            this.StartUpCommand = ReactiveCommand.CreateAsyncTask(x => this.StartUpAsync());

            // handle command line args from another instance
            this.WhenAnyValue(x => x.CommandLineArgs)
                .Where(list => list != null && list.Skip(1).Any())
                .Select(list => list.Skip(1).ToList())
                .SelectMany(list => this.HandleCommandLineArgsAsync(list).ToObservable())
                .Subscribe();
        }