pull/7891/head
DHR60 2025-09-06 17:27:08 +08:00
parent 0302b9d1d0
commit 9a4d8faaa2
11 changed files with 57 additions and 6 deletions

View File

@ -3030,6 +3030,15 @@ namespace ServiceLib.Resx {
} }
} }
/// <summary>
/// 查找类似 Select Profile 的本地化字符串。
/// </summary>
public static string TbSelectProfile {
get {
return ResourceManager.GetString("TbSelectProfile", resourceCulture);
}
}
/// <summary> /// <summary>
/// 查找类似 Set system proxy 的本地化字符串。 /// 查找类似 Set system proxy 的本地化字符串。
/// </summary> /// </summary>

View File

@ -1512,4 +1512,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>Start parsing and processing subscription content</value> <value>Start parsing and processing subscription content</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>Select Profile</value>
</data>
</root> </root>

View File

@ -1512,4 +1512,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>Start parsing and processing subscription content</value> <value>Start parsing and processing subscription content</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>Select Profile</value>
</data>
</root> </root>

View File

@ -1512,4 +1512,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>Start parsing and processing subscription content</value> <value>Start parsing and processing subscription content</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>Select Profile</value>
</data>
</root> </root>

View File

@ -1512,4 +1512,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>Start parsing and processing subscription content</value> <value>Start parsing and processing subscription content</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>Select Profile</value>
</data>
</root> </root>

View File

@ -1509,4 +1509,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>开始解析和处理订阅内容</value> <value>开始解析和处理订阅内容</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>选择配置文件</value>
</data>
</root> </root>

View File

@ -1509,4 +1509,7 @@
<data name="MsgStartParsingSubscription" xml:space="preserve"> <data name="MsgStartParsingSubscription" xml:space="preserve">
<value>開始解析和處理訂閱內容</value> <value>開始解析和處理訂閱內容</value>
</data> </data>
<data name="TbSelectProfile" xml:space="preserve">
<value>Select Profile</value>
</data>
</root> </root>

View File

@ -10,7 +10,7 @@
xmlns:reactiveui="http://reactiveui.net" xmlns:reactiveui="http://reactiveui.net"
xmlns:resx="clr-namespace:ServiceLib.Resx;assembly=ServiceLib" xmlns:resx="clr-namespace:ServiceLib.Resx;assembly=ServiceLib"
xmlns:vms="clr-namespace:ServiceLib.ViewModels;assembly=ServiceLib" xmlns:vms="clr-namespace:ServiceLib.ViewModels;assembly=ServiceLib"
Title="ProfilesSelectWindow" Title="{x:Static resx:ResUI.TbSelectProfile}"
Width="800" Width="800"
Height="450" Height="450"
x:TypeArguments="vms:ProfilesSelectViewModel" x:TypeArguments="vms:ProfilesSelectViewModel"

View File

@ -72,14 +72,24 @@
IsEditable="True" IsEditable="True"
MaxDropDownHeight="1000" MaxDropDownHeight="1000"
Style="{StaticResource DefComboBox}" /> Style="{StaticResource DefComboBox}" />
<TextBlock <StackPanel
Grid.Row="1" Grid.Row="1"
Grid.Column="2" Grid.Column="2"
Margin="{StaticResource Margin4}" Margin="{StaticResource Margin4}"
HorizontalAlignment="Left" HorizontalAlignment="Left"
VerticalAlignment="Center" VerticalAlignment="Center"
Style="{StaticResource ToolbarTextBlock}" Orientation="Horizontal">
Text="{x:Static resx:ResUI.TbRuleOutboundTagTip}" /> <Button
Margin="{StaticResource Margin4}"
Click="BtnSelectProfile_Click"
Content="{x:Static resx:ResUI.TbSelectProfile}"
Style="{StaticResource DefButton}" />
<TextBlock
Margin="{StaticResource Margin4}"
VerticalAlignment="Center"
Style="{StaticResource ToolbarTextBlock}"
Text="{x:Static resx:ResUI.TbRuleOutboundTagTip}" />
</StackPanel>
<TextBlock <TextBlock
Grid.Row="2" Grid.Row="2"

View File

@ -1,5 +1,6 @@
using System.Reactive.Disposables; using System.Reactive.Disposables;
using System.Windows; using System.Windows;
using System.Windows.Threading;
using ReactiveUI; using ReactiveUI;
using ServiceLib.Manager; using ServiceLib.Manager;
@ -88,4 +89,17 @@ public partial class RoutingRuleDetailsWindow
{ {
ProcUtils.ProcessStart("https://xtls.github.io/config/routing.html#ruleobject"); ProcUtils.ProcessStart("https://xtls.github.io/config/routing.html#ruleobject");
} }
private async void BtnSelectProfile_Click(object sender, RoutedEventArgs e)
{
var selectWindow = new ProfilesSelectWindow();
if (selectWindow.ShowDialog() == true)
{
var profile = await selectWindow.ProfileItem;
if (profile != null)
{
cmbOutboundTag.Text = profile.Remarks;
}
}
}
} }

View File

@ -265,7 +265,7 @@
Margin="{StaticResource Margin4}" Margin="{StaticResource Margin4}"
VerticalAlignment="Center" VerticalAlignment="Center"
Click="BtnSelectPrevProfile_Click" Click="BtnSelectPrevProfile_Click"
Content="btnSelectPrevProfile" Content="{x:Static resx:ResUI.TbSelectProfile}"
Style="{StaticResource DefButton}" /> Style="{StaticResource DefButton}" />
<TextBlock <TextBlock
@ -290,7 +290,7 @@
Margin="{StaticResource Margin4}" Margin="{StaticResource Margin4}"
VerticalAlignment="Center" VerticalAlignment="Center"
Click="BtnSelectNextProfile_Click" Click="BtnSelectNextProfile_Click"
Content="btnNextPrevProfile" Content="{x:Static resx:ResUI.TbSelectProfile}"
Style="{StaticResource DefButton}" /> Style="{StaticResource DefButton}" />
<TextBlock <TextBlock