From 9b593a39bf2f4db6c6973be82ffb9610e9c03c25 Mon Sep 17 00:00:00 2001 From: ivandrofly Date: Sun, 11 Oct 2015 22:00:32 +0100 Subject: [PATCH] [Add Item to list view] - Minor Refactor --- src/Forms/MergeDoubleLines.cs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/Forms/MergeDoubleLines.cs b/src/Forms/MergeDoubleLines.cs index 9a6b7eab2..6bdd8f4b2 100644 --- a/src/Forms/MergeDoubleLines.cs +++ b/src/Forms/MergeDoubleLines.cs @@ -58,12 +58,8 @@ namespace Nikse.SubtitleEdit.Forms private void AddToListView(Paragraph p, string lineNumbers, string newText) { var item = new ListViewItem(string.Empty) { Tag = p, Checked = true }; - - var subItem = new ListViewItem.ListViewSubItem(item, lineNumbers.TrimEnd(',')); - item.SubItems.Add(subItem); - subItem = new ListViewItem.ListViewSubItem(item, newText.Replace(Environment.NewLine, Configuration.Settings.General.ListViewLineSeparatorString)); - item.SubItems.Add(subItem); - + item.SubItems.Add(lineNumbers.TrimEnd(',')); + item.SubItems.Add(newText.Replace(Environment.NewLine, Configuration.Settings.General.ListViewLineSeparatorString)); listViewFixes.Items.Add(item); }