Exemple #1
0
        private LibraryModel()
        {
            libraryTracer.Restart();

            DatabaseManager.Current.Connect();

            libraryTracer.Trace("Database Connected");

            _playQueue = new PlayQueueModel();

            libraryTracer.Trace("PlayQueueModel Created");
        }
Exemple #2
0
        private LibraryViewModel()
        {
            perf.Restart();

            LibraryModel.Current.Start();

            perf.Trace("Model created");

            LibraryModel.Current.AllSongs.CollectionChanged  += HandleAllSongsCollectionChanged;
            LibraryModel.Current.Playlists.CollectionChanged += HandlePlaylistsCollectionChanged;
            LibraryModel.Current.Mixes.CollectionChanged     += HandleMixCollectionChanged;

            LibraryModel.Current.AlbumCreated += HandleLibraryModelAlbumCreated;

            _playQueue = new PlayQueueViewModel(LibraryModel.Current.PlayQueue);

            perf.Trace("first pass load done");
        }