Example #1
0
        private static void DeleteRelease_Click(object sender, RoutedEventArgs e)
        {
            Button btn       = sender as Button;
            string storageid = btn.Name.Replace("delete", "");
            //string userid = AccessHelper.GetGameStorageUserID(storageid);
            string           gameid = AccessHelper.GetGameStorageGameID(storageid);
            MessageBoxResult dr     = MessageBox.Show("真的要删除此信息吗?", "提示", MessageBoxButton.OKCancel, MessageBoxImage.Question);

            if (dr == MessageBoxResult.OK)
            {
                AccessHelper.DeleteGameStorageInfo(storageid);

                EventCenter.Broadcast <string>(EventType.DeleteOneUserRelease, storageid);
                EventCenter.Broadcast <string>(EventType.UpdateGameList, gameid);


                MessageBox.Show("已删除!", "message", MessageBoxButton.OK);
            }

            //throw new NotImplementedException();
        }