Skip to content

Commit 079a0f8

Browse files
author
Sébastien Geiser
committed
Refatoring
1 parent 03d5457 commit 079a0f8

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

RegexDialog/RegExToolDialog.xaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -748,8 +748,8 @@
748748
<RowDefinition Height="0.2*" MinHeight="20" />
749749
</Grid.RowDefinitions>
750750
<StackPanelEx Margin="5" MarginBetweenChildren="5">
751-
<ListBox Name="icRegexOptions"
752-
SelectionChanged="icRegexOptions_SelectionChanged"
751+
<ListBox Name="RegexOptionsListBox"
752+
SelectionChanged="RegexOptionsListBox_SelectionChanged"
753753
BorderThickness="0">
754754
<ItemsControl.ItemTemplate>
755755
<DataTemplate>

RegexDialog/RegExToolDialog.xaml.cs

+4-7
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ private void BuildRegexOptionsCheckBoxs()
331331
}
332332
});
333333

334-
icRegexOptions.ItemsSource = regExOptionViewModelsList;
334+
RegexOptionsListBox.ItemsSource = regExOptionViewModelsList;
335335
miRegexOptions.ItemsSource = regExOptionViewModelsList;
336336
}
337337

@@ -917,10 +917,7 @@ void Extract(string text, string fileName = "")
917917
}
918918
else
919919
{
920-
matches.ForEach(match =>
921-
{
922-
sb.Append(match.Result(ReplaceEditor.Text));
923-
});
920+
matches.ForEach(match => sb.Append(match.Result(ReplaceEditor.Text)));
924921
}
925922
}
926923
else
@@ -2425,9 +2422,9 @@ private void Hyperlink_RequestNavigate(object sender, System.Windows.Navigation.
24252422
e.Handled = true;
24262423
}
24272424

2428-
private void icRegexOptions_SelectionChanged(object sender, SelectionChangedEventArgs e)
2425+
private void RegexOptionsListBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
24292426
{
2430-
if(icRegexOptions.SelectedValue is RegExOptionViewModel optionModel)
2427+
if(RegexOptionsListBox.SelectedValue is RegExOptionViewModel optionModel)
24312428
{
24322429
tbxRegexOptionDescription.Text = optionModel.Description;
24332430
}

0 commit comments

Comments
 (0)