diff --git a/v2rayN/ServiceLib/ServiceLib.csproj b/v2rayN/ServiceLib/ServiceLib.csproj
index 48f0e359..b81a48dc 100644
--- a/v2rayN/ServiceLib/ServiceLib.csproj
+++ b/v2rayN/ServiceLib/ServiceLib.csproj
@@ -8,13 +8,13 @@
-
+
-
+
diff --git a/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs b/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs
index dc87be16..d6ec6e25 100644
--- a/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs
+++ b/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs
@@ -639,6 +639,7 @@ namespace ServiceLib.ViewModels
NoticeHandler.Instance.Enqueue(ResUI.OperationSuccess);
RefreshServers();
+ SelectedMoveToGroup = null;
SelectedMoveToGroup = new();
//Reload();
}
diff --git a/v2rayN/v2rayN.Desktop/Views/ClashConnectionsView.axaml b/v2rayN/v2rayN.Desktop/Views/ClashConnectionsView.axaml
index dd1c94ac..7318e7de 100644
--- a/v2rayN/v2rayN.Desktop/Views/ClashConnectionsView.axaml
+++ b/v2rayN/v2rayN.Desktop/Views/ClashConnectionsView.axaml
@@ -42,6 +42,23 @@
+
+
{
@@ -42,6 +44,19 @@ namespace v2rayN.Desktop.Views
return await Task.FromResult(true);
}
+ private void BtnAutofitColumnWidth_Click(object? sender, RoutedEventArgs e)
+ {
+ AutofitColumnWidth();
+ }
+
+ private void AutofitColumnWidth()
+ {
+ foreach (var it in lstConnections.Columns)
+ {
+ it.Width = new DataGridLength(1, DataGridLengthUnitType.Auto);
+ }
+ }
+
private void btnClose_Click(object? sender, RoutedEventArgs e)
{
ViewModel?.ClashConnectionClose(false);
diff --git a/v2rayN/v2rayN.Desktop/v2rayN.Desktop.csproj b/v2rayN/v2rayN.Desktop/v2rayN.Desktop.csproj
index c2a35353..740975da 100644
--- a/v2rayN/v2rayN.Desktop/v2rayN.Desktop.csproj
+++ b/v2rayN/v2rayN.Desktop/v2rayN.Desktop.csproj
@@ -28,8 +28,8 @@
-
-
+
+
diff --git a/v2rayN/v2rayN/Views/ClashConnectionsView.xaml b/v2rayN/v2rayN/Views/ClashConnectionsView.xaml
index 88f6b3d1..779354e7 100644
--- a/v2rayN/v2rayN/Views/ClashConnectionsView.xaml
+++ b/v2rayN/v2rayN/Views/ClashConnectionsView.xaml
@@ -39,6 +39,16 @@
+
+
{
@@ -45,6 +47,18 @@ namespace v2rayN.Views
return await Task.FromResult(true);
}
+ private void BtnAutofitColumnWidth_Click(object sender, RoutedEventArgs e)
+ {
+ AutofitColumnWidth();
+ }
+ private void AutofitColumnWidth()
+ {
+ foreach (var it in lstConnections.Columns)
+ {
+ it.Width = new DataGridLength(1, DataGridLengthUnitType.Auto);
+ }
+ }
+
private void btnClose_Click(object sender, System.Windows.RoutedEventArgs e)
{
ViewModel?.ClashConnectionClose(false);
diff --git a/v2rayN/v2rayN/Views/MainWindow.xaml.cs b/v2rayN/v2rayN/Views/MainWindow.xaml.cs
index 0243fcff..0dc59911 100644
--- a/v2rayN/v2rayN/Views/MainWindow.xaml.cs
+++ b/v2rayN/v2rayN/Views/MainWindow.xaml.cs
@@ -283,13 +283,6 @@ namespace v2rayN.Views
{
switch (e.Key)
{
- case Key.V:
- if (_backupAndRestoreView?.IsVisible == true) return;
-
- var clipboardData = WindowsUtils.GetClipboardData();
- ViewModel?.AddServerViaClipboardAsync(clipboardData);
- break;
-
case Key.S:
ScanScreenTaskAsync().ContinueWith(_ => { });
break;
diff --git a/v2rayN/v2rayN/Views/ProfilesView.xaml.cs b/v2rayN/v2rayN/Views/ProfilesView.xaml.cs
index e39c7dff..36101b41 100644
--- a/v2rayN/v2rayN/Views/ProfilesView.xaml.cs
+++ b/v2rayN/v2rayN/Views/ProfilesView.xaml.cs
@@ -228,6 +228,12 @@ namespace v2rayN.Views
{
switch (e.Key)
{
+ case Key.V:
+ var clipboardData = WindowsUtils.GetClipboardData();
+ var service = Locator.Current.GetService();
+ if (service != null) _ = service.AddServerViaClipboardAsync(clipboardData);
+ break;
+
case Key.A:
menuSelectAll_Click(null, null);
break;