示例#1
0
 private void _DelBgm()
 {
     if (SelectedBangumi != null)
     {
         DbModel.番组.Remove(SelectedBangumi);
         BgmList.Remove(SelectedBangumi);
         DbModel.SaveChanges();
     }
 }
示例#2
0
 /// <summary>
 /// Play the background music.
 /// </summary>
 /// <param name="songName">BGM name.</param>
 public void PlayBgm(string songName)
 {
     BgmList.ForEach(song =>
     {
         if (song.musicName.Equals(songName))
         {
             PlayBgm(song);
         }
     });
 }
示例#3
0
        private void _DropBgm(object o)
        {
            var code = (string)o;
            var bgm  = VM番组.解析信息(code, new 番组());

            bgm.Bangumi编号 = code;
            DbModel.番组.Add(bgm);
            DbModel.SaveChanges();
            BgmList.Add(bgm);
        }