public SelectAudioFilesViewModel(ViewLocator locator, IZuneAudioFileRetriever fileRetriever,
                                  SharedModel sharedModel)
 {
     _sharedModel = sharedModel;
     _locator = locator;
     _fileRetriever = fileRetriever;
     CanSwitchToNewMode = true;
     SelectFilesCommand = new RelayCommand(SelectFiles);
     SwitchToNewModeCommand = new RelayCommand(SwitchToNewMode);
 }
 public AlbumDetailsViewModel(IZuneDatabaseReader dbReader,
                         ViewLocator locator,
                         IZuneAudioFileRetriever fileRetriever,
                         SharedModel sharedModel)
 {
     _dbReader = dbReader;
     _locator = locator;
     _fileRetriever = fileRetriever;
     _sharedModel = sharedModel;
     LinkCommand = new RelayCommand(LinkAlbum);
     RefreshCommand = new RelayCommand(RefreshAlbum);
     DelinkCommand = new RelayCommand(DelinkAlbum);
 }
        public ApplicationViewModel(IZuneDatabaseReader dbReader,
                                    SafeObservableCollection<AlbumDetailsViewModel> albums,
                                    ViewLocator locator)
        {
            _dbReader = dbReader;
            _albums = albums;
            _viewLocator = locator;

            //register for notification messages
            Messenger.Default.Register<ErrorMessage>(this, Notifications.Add);

            locator.SwitchToViewRequested += (view, viewModel) => {
                CurrentPage = view;
            };
        }
        public WebAlbumListViewModel(SafeObservableCollection<AlbumDetailsViewModel> albums,
                                     ViewLocator locator)
        {
            _albums = albums;
            _albums.CollectionChanged += AlbumsCollectionChanged;
            _cvs = new CollectionViewSource();
            _cvs.Source = albums;
            _cvs.Filter += CvsFilter;

            _locator = locator;
            _isTaskbarSupported = TaskbarManager.IsPlatformSupported;

            this.LoadFromZuneWebsiteCommand = new RelayCommand(LoadFromZuneWebsite);
            this.SwitchToClassicModeCommand = new RelayCommand(SwitchToClassicMode);
            this.SortCommand = new RelayCommand(Sort);
            this.SearchCommand = new RelayCommand<string>(Search);
            this.CanShowScanAllButton = true;
            this.SortOrder = Settings.Default.SortOrder;
        }
Exemplo n.º 5
0
 public SuccessViewModel(ViewLocator locator, SharedModel sharedModel)
 {
     _locator = locator;
     _sharedModel = sharedModel;
 }
Exemplo n.º 6
0
 public DetailsViewModel(ViewLocator locator, SharedModel sharedModel)
 {
     _locator = locator;
     _sharedModel = sharedModel;
 }
Exemplo n.º 7
0
 public SearchViewModel(ViewLocator locator, SharedModel sharedModel)
 {
     _locator = locator;
     _sharedModel = sharedModel;
 }
 public ApplicationView(ViewLocator locator)
 {
     locator.SwitchToViewRequested += (arg1, arg2) => _currentViewModel = arg2;
     InitializeComponent();
 }