private void button_recFolderAdd_1seg_Click(object sender, RoutedEventArgs e) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } if (setting.ShowDialog() == true) { RecFileSetInfo setInfo = new RecFileSetInfo(); setting.GetSetting(ref setInfo); foreach (RecFileSetInfoView info in listView_recFolder_1seg.Items) { if (String.Compare(setInfo.RecFolder, info.RecFolder, true) == 0 && String.Compare(setInfo.WritePlugIn, info.WritePlugIn, true) == 0 && String.Compare(setInfo.RecNamePlugIn, info.RecNamePlugIn, true) == 0) { MessageBox.Show("すでに追加されています"); return; } } listView_recFolder_1seg.Items.Add(new RecFileSetInfoView(setInfo)); } }
private void button_recFolderAdd_1seg_Click(object sender, RoutedEventArgs e) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } if (setting.ShowDialog() == true) { RecFileSetInfo setInfo = setting.GetSetting(); foreach (RecFileSetInfoView info in listView_recFolder.Items) { if (info.PartialRec && setInfo.RecFolder.Equals(info.RecFolder, StringComparison.OrdinalIgnoreCase) && setInfo.WritePlugIn.Equals(info.WritePlugIn, StringComparison.OrdinalIgnoreCase) && setInfo.RecNamePlugIn.Equals(info.RecNamePlugIn, StringComparison.OrdinalIgnoreCase)) { MessageBox.Show("すでに追加されています"); return; } } listView_recFolder.Items.Add(new RecFileSetInfoView(setInfo, true)); } }
private void button_recFolderChg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder.SelectedItem == null) { if (listView_recFolder.Items.Count != 0) { listView_recFolder.SelectedIndex = 0; } } if (listView_recFolder.SelectedItem != null) { var setting = new RecFolderWindow(); setting.Owner = CommonUtil.GetTopWindow(this); var selectInfo = ((RecFileSetInfoView)listView_recFolder.SelectedItem).Info; setting.SetDefSetting(selectInfo); setting.SetPartialMode(((RecFileSetInfoView)listView_recFolder.SelectedItem).PartialRec); if (setting.ShowDialog() == true) { setting.GetSetting(ref selectInfo); } listView_recFolder.Items.Refresh(); } else { recFolderAdd(false); } }
private void button_recFolderChg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder.SelectedItem == null) { listView_recFolder.SelectedIndex = 0; } var selectInfo = listView_recFolder.SelectedItem as RecFileSetInfoView; if (selectInfo != null) { var setting = new RecFolderWindow { Owner = CommonUtil.GetTopWindow(this) }; setting.SetDefSetting(selectInfo); if (setting.ShowDialog() == true) { setting.GetSetting(selectInfo); listView_recFolder.Items.Refresh(); listView_recFolder.FitColumnWidth(); } } else { button_recFolderAdd_Click(null, null); } }
private void button_recFolderAdd_Click(object sender, RoutedEventArgs e) { var setting = new RecFolderWindow { Owner = CommonUtil.GetTopWindow(this) }; if (setting.ShowDialog() == true) { listView_recFolder.ScrollIntoViewLast(setting.GetSetting()); listView_recFolder.FitColumnWidth(); } }
private void button_recFolderChg_1seg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder_1seg.SelectedItem != null) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } RecFileSetInfo selectInfo = ((RecFileSetInfoView)listView_recFolder_1seg.SelectedItem).Info; setting.SetDefSetting(selectInfo); if (setting.ShowDialog() == true) { setting.GetSetting(ref selectInfo); } listView_recFolder_1seg.Items.Refresh(); } }
private void recFolderAdd(bool partialRec) { var setting = new RecFolderWindow(); setting.Owner = CommonUtil.GetTopWindow(this); setting.SetPartialMode(partialRec); if (setting.ShowDialog() == true) { var setInfo = new RecFileSetInfo(); setting.GetSetting(ref setInfo); foreach (RecFileSetInfoView info in listView_recFolder.Items) { if (info.PartialRec == partialRec && String.Compare(setInfo.RecFolder, info.RecFolder, true) == 0 && String.Compare(setInfo.WritePlugIn, info.WritePlugIn, true) == 0 && String.Compare(setInfo.RecNamePlugIn, info.RecNamePlugIn, true) == 0) { MessageBox.Show("すでに追加されています"); return; } } listView_recFolder.Items.Add(new RecFileSetInfoView(setInfo, partialRec)); } }
private void button_recFolderChg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder.SelectedItem != null) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } var item = (RecFileSetInfoView)listView_recFolder.SelectedItem; setting.SetDefSetting(item.Info); if (setting.ShowDialog() == true) { listView_recFolder.SelectedItem = listView_recFolder.Items[listView_recFolder.SelectedIndex] = new RecFileSetInfoView(setting.GetSetting(), item.PartialRec); } } }
private void button_recFolderChg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder.SelectedItem != null) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } RecFileSetInfo selectInfo = listView_recFolder.SelectedItem as RecFileSetInfo; setting.SetDefSetting(selectInfo); if (setting.ShowDialog() == true) { setting.GetSetting(ref selectInfo); } listView_recFolder.Items.Refresh(); } }
private void button_recFolderAdd_Click(object sender, RoutedEventArgs e) { RecFolderWindow setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } if (setting.ShowDialog() == true) { RecFileSetInfo setInfo = new RecFileSetInfo(); setting.GetSetting(ref setInfo); foreach (RecFileSetInfo info in recSetting.RecFolderList) { if (String.Compare(setInfo.RecFolder, info.RecFolder, true) == 0 && String.Compare(setInfo.WritePlugIn, info.WritePlugIn, true) == 0 && String.Compare(setInfo.RecNamePlugIn, info.RecNamePlugIn, true) == 0) { MessageBox.Show("すでに追加されています"); return; } } listView_recFolder.Items.Add(setInfo); } }
private void recFolderAdd(bool partialRec) { var setting = new RecFolderWindow(); setting.SetPartialMode(partialRec); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } if (setting.ShowDialog() == true) { var setInfo = new RecFileSetInfo(); setting.GetSetting(ref setInfo); foreach (RecFileSetInfoView info in listView_recFolder.Items) { if (info.PartialRec == partialRec && String.Compare(setInfo.RecFolder, info.RecFolder, true) == 0 && String.Compare(setInfo.WritePlugIn, info.WritePlugIn, true) == 0 && String.Compare(setInfo.RecNamePlugIn, info.RecNamePlugIn, true) == 0) { MessageBox.Show("すでに追加されています"); return; } } listView_recFolder.Items.Add(new RecFileSetInfoView(setInfo, partialRec)); } }
private void button_recFolderChg_Click(object sender, RoutedEventArgs e) { if (listView_recFolder.SelectedItem == null) { if (listView_recFolder.Items.Count != 0) { listView_recFolder.SelectedIndex = 0; } } if (listView_recFolder.SelectedItem != null) { var setting = new RecFolderWindow(); PresentationSource topWindow = PresentationSource.FromVisual(this); if (topWindow != null) { setting.Owner = (Window)topWindow.RootVisual; } var selectInfo = ((RecFileSetInfoView)listView_recFolder.SelectedItem).Info; setting.SetDefSetting(selectInfo); setting.SetPartialMode(((RecFileSetInfoView)listView_recFolder.SelectedItem).PartialRec); if (setting.ShowDialog() == true) { setting.GetSetting(ref selectInfo); } listView_recFolder.Items.Refresh(); } else { recFolderAdd(false); } }