Esempio n. 1
0
        private void mc_Delete(object sender, ExecutedRoutedEventArgs e)
        {
            if (listView_result.SelectedItem == null)
            {
                return;
            }
            //
            List <IRecWorkMainData> dataList = lstCtrl.GetSelectedItemsList().Select(data => data.Data).ToList();

            dataList.RemoveAll(d => d is RecFileInfo && (d as RecFileInfo).ProtectFlag != 0);

            if (CmdExeUtil.CheckDeleteCancel(e, dataList) == true)
            {
                return;
            }

            if (CmdExeRecinfo.mcs_DeleteCheckDelFile(dataList.OfType <RecFileInfo>()) == false)
            {
                return;
            }

            if (MenuUtil.CautionManyMessage(dataList.Count, "削除の確認") == false)
            {
                return;
            }

            MenuUtil.ReserveDelete(dataList.OfType <ReserveData>().ToList(), false);
            MenuUtil.RecinfoDelete(dataList.OfType <RecFileInfo>().ToList(), false);
            MenuUtil.AutoAddDelete(dataList.OfType <AutoAddData>().ToList(), false);

            StatusManager.StatusNotifySet(true, mc.GetCmdMessageFormat("削除を実行", dataList.Count));
        }
Esempio n. 2
0
        protected void autoadd_del(ExecutedRoutedEventArgs e, int code)
        {
            bool ret = false;

            try
            {
                if (CheckAutoAddChange(e, code) == 0)
                {
                    if (code == 2)
                    {
                        ret = MenuUtil.AutoAddDelete(autoAddData.IntoList());
                    }
                    else
                    {
                        ret = MenuUtil.AutoAddDelete(autoAddData.IntoList(), true, true);
                    }

                    if (ret == true)
                    {
                        SetViewMode(AutoAddMode.NewAdd);
                    }
                }
            }
            catch (Exception ex) { MessageBox.Show(ex.Message + "\r\n" + ex.StackTrace); }
            StatusManager.StatusNotifySet(ret, AutoAddString + "を" + cmdMsg[code]);
        }
Esempio n. 3
0
 protected override void mc_Delete2(object sender, ExecutedRoutedEventArgs e)
 {
     if (CmdExeUtil.CheckAllProcCancel(e, dataList, true) == true)
     {
         return;
     }
     IsCommandExecuted = MenuUtil.AutoAddDelete(dataList, true, true);
 }
Esempio n. 4
0
 protected override void mc_Delete(object sender, ExecutedRoutedEventArgs e)
 {
     if (mcs_DeleteCheck(e) == false)
     {
         return;
     }
     IsCommandExecuted = MenuUtil.AutoAddDelete(dataList);
 }
Esempio n. 5
0
        private void button_del2_click(object sender, ExecutedRoutedEventArgs e)
        {
            if (CheckAutoAddChange(e, 3) == false)
            {
                return;
            }
            //
            bool ret = MenuUtil.AutoAddDelete(CommonUtil.ToList(defKey), cmdDeleteType.Delete2);

            CommonManager.Instance.StatusNotifySet(ret, "プログラム予約登録を予約ごと削除");
            DialogResult = true;
        }
Esempio n. 6
0
 protected override void mc_Delete(object sender, ExecutedRoutedEventArgs e)
 {
     if (e.Command == EpgCmds.DeleteAll)
     {
         if (CmdExeUtil.CheckAllDeleteCancel(e, dataList.Count) == true)
         {
             return;
         }
     }
     else
     {
         if (CmdExeUtil.CheckKeyboardDeleteCancel(e, dataList.Select(data => data.DataTitle).ToList()) == true)
         {
             return;
         }
     }
     IsCommandExecuted = MenuUtil.AutoAddDelete(dataList);
 }
Esempio n. 7
0
        private void button_del_epgAutoAdd_Click(object sender, ExecutedRoutedEventArgs e)
        {
            bool ret = false;

            try
            {
                ret = CheckAutoAddChange(e, 2);
                if (ret == true)
                {
                    ret = MenuUtil.AutoAddDelete(CommonUtil.ToList(CommonManager.Instance.DB.EpgAutoAddList[autoAddID]));
                    if (ret == true)
                    {
                        SetViewMode(SearchMode.NewAdd);
                        this.autoAddID = 0;
                    }
                }
            }
            catch (Exception ex) { MessageBox.Show(ex.Message + "\r\n" + ex.StackTrace); }
            CommonManager.Instance.StatusNotifySet(ret, "キーワード予約を削除", this);
        }