private void listView_recinfo_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (listView_recinfo.SelectedItem != null) { if (Settings.Instance.PlayDClick == false) { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; RecInfoDescWindow dlg = new RecInfoDescWindow(); dlg.Owner = (Window)PresentationSource.FromVisual(this).RootVisual; dlg.SetRecInfo(info.RecInfo); dlg.ShowDialog(); } else { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; if (info.RecInfo.RecFilePath.Length > 0) { try { CommonManager.Instance.FilePlay(info.RecInfo.RecFilePath); } catch (Exception ex) { MessageBox.Show(ex.Message); } } } } }
private void listView_recinfo_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (listView_recinfo.SelectedItem != null) { if (Settings.Instance.PlayDClick == false) { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; RecInfoDescWindow dlg = new RecInfoDescWindow(); dlg.Owner = (Window)PresentationSource.FromVisual(this).RootVisual; RecFileInfo extraRecInfo = new RecFileInfo(); if (CommonManager.CreateSrvCtrl().SendGetRecInfo(info.RecInfo.ID, ref extraRecInfo) == ErrCode.CMD_SUCCESS) { info.RecInfo.ProgramInfo = extraRecInfo.ProgramInfo; info.RecInfo.ErrInfo = extraRecInfo.ErrInfo; } dlg.SetRecInfo(info.RecInfo); dlg.ShowDialog(); } else { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; if (info.RecInfo.RecFilePath.Length > 0) { try { CommonManager.Instance.FilePlay(info.RecInfo.RecFilePath); } catch (Exception ex) { MessageBox.Show(ex.Message); } } } } }
private void button_recInfo_Click(object sender, RoutedEventArgs e) { if (listView_recinfo.SelectedItem != null) { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; RecInfoDescWindow dlg = new RecInfoDescWindow(); dlg.Owner = (Window)PresentationSource.FromVisual(this).RootVisual; dlg.SetRecInfo(info.RecInfo); dlg.ShowDialog(); } }
public static bool?OpenRecInfoDialog(RecFileInfo info, Control Owner) { try { var dlg = new RecInfoDescWindow(); dlg.Owner = CommonUtil.GetTopWindow(Owner); cmd.SendGetRecInfo(info.ID, ref info);//*** dlg.SetRecInfo(info); return(dlg.ShowDialog()); } catch (Exception ex) { MessageBox.Show(ex.Message + "\r\n" + ex.StackTrace); } return(null); }
public static bool?OpenRecInfoDialog(RecFileInfo info) { try { if (RecInfoDescWindow.ChangeDataLastUsedWindow(info) != null) { return(true); } new RecInfoDescWindow(info).Show(); return(true); } catch (Exception ex) { MessageBox.Show(ex.Message + "\r\n" + ex.StackTrace); } return(null); }
private void button_recInfo_Click(object sender, RoutedEventArgs e) { if (listView_recinfo.SelectedItem != null) { RecInfoItem info = listView_recinfo.SelectedItem as RecInfoItem; RecInfoDescWindow dlg = new RecInfoDescWindow(); dlg.Owner = (Window)PresentationSource.FromVisual(this).RootVisual; RecFileInfo extraRecInfo = new RecFileInfo(); if (CommonManager.CreateSrvCtrl().SendGetRecInfo(info.RecInfo.ID, ref extraRecInfo) == ErrCode.CMD_SUCCESS) { info.RecInfo.ProgramInfo = extraRecInfo.ProgramInfo; info.RecInfo.ErrInfo = extraRecInfo.ErrInfo; } dlg.SetRecInfo(info.RecInfo); dlg.ShowDialog(); } }
private void button_recInfo_Click(object sender, RoutedEventArgs e) { if (listView_recinfo.SelectedItem != null) { RecFileInfo info = ((RecInfoItem)listView_recinfo.SelectedItem).RecInfo; RecInfoDescWindow dlg = new RecInfoDescWindow(); dlg.Owner = (Window)PresentationSource.FromVisual(this).RootVisual; RecFileInfo extraRecInfo = new RecFileInfo(); if (CommonManager.CreateSrvCtrl().SendGetRecInfo(info.ID, ref extraRecInfo) == ErrCode.CMD_SUCCESS) { info.ProgramInfo = extraRecInfo.ProgramInfo; info.ErrInfo = extraRecInfo.ErrInfo; if (info.ProgramInfo.Length == 0 && info.EventID != 0xFFFF) { //過去番組情報を探してみる var arcList = new List <EpgServiceEventInfo>(); if (CommonManager.CreateSrvCtrl().SendEnumPgArc(new List <long> { 0, (long)CommonManager.Create64Key(info.OriginalNetworkID, info.TransportStreamID, info.ServiceID), info.StartTime.ToFileTimeUtc(), info.StartTime.ToFileTimeUtc() + 1 }, ref arcList) == ErrCode.CMD_SUCCESS && arcList.Count > 0 && arcList[0].eventList.Count > 0) { info.ProgramInfo = CommonManager.Instance.ConvertProgramText(arcList[0].eventList[0], EventInfoTextMode.All); } else { //番組情報を探してみる EpgEventInfo eventInfo = CommonManager.Instance.DB.GetPgInfo(info.OriginalNetworkID, info.TransportStreamID, info.ServiceID, info.EventID, false); if (eventInfo != null && eventInfo.StartTimeFlag != 0 && eventInfo.start_time == info.StartTime) { info.ProgramInfo = CommonManager.Instance.ConvertProgramText(eventInfo, EventInfoTextMode.All); } } } } dlg.SetRecInfo(info); dlg.ShowDialog(); } }