mirror of
https://github.com/2dust/v2rayN.git
synced 2026-11-13 16:05:01 +03:00
Restore Autofit Column Width Button on Main Window (#10579)
* Add autofit column width button to ProfilesView restore-autofit-column-width-button * Restore autofit button
This commit is contained in:
@@ -69,6 +69,16 @@
|
||||
PlaceholderText="{x:Static resx:ResUI.MsgServerTitle}"
|
||||
ToolTip.Tip="{x:Static resx:ResUI.MsgServerTitle}" />
|
||||
|
||||
<Button
|
||||
x:Name="btnAutofitColumnWidth"
|
||||
Margin="{StaticResource MarginLr4}"
|
||||
Classes="IconButton Success"
|
||||
ToolTip.Tip="{x:Static resx:ResUI.menuProfileAutofitColumnWidth}">
|
||||
<Button.Content>
|
||||
<PathIcon Data="{StaticResource SemiIconExpand}" />
|
||||
</Button.Content>
|
||||
</Button>
|
||||
|
||||
<Button
|
||||
x:Name="btnFastRealPing"
|
||||
Margin="{StaticResource MarginLr4}"
|
||||
|
||||
@@ -18,6 +18,7 @@ public partial class ProfilesView : ReactiveUserControl<ProfilesViewModel>
|
||||
_config = AppManager.Instance.Config;
|
||||
|
||||
menuSelectAll.Click += menuSelectAll_Click;
|
||||
btnAutofitColumnWidth.Click += BtnAutofitColumnWidth_Click;
|
||||
txtServerFilter.KeyDown += TxtServerFilter_KeyDown;
|
||||
lstProfiles.KeyDown += LstProfiles_KeyDown;
|
||||
lstProfiles.SelectionChanged += lstProfiles_SelectionChanged;
|
||||
@@ -316,6 +317,12 @@ public partial class ProfilesView : ReactiveUserControl<ProfilesViewModel>
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void BtnAutofitColumnWidth_Click(object? sender, RoutedEventArgs e)
|
||||
{
|
||||
AutofitColumnWidth();
|
||||
}
|
||||
|
||||
private void AutofitColumnWidth()
|
||||
{
|
||||
try
|
||||
|
||||
Reference in New Issue
Block a user