mirror of https://github.com/2dust/v2rayN
parent
9540669f56
commit
24afe8bde4
|
@ -103,8 +103,6 @@
|
||||||
public int trayMenuServersLimit { get; set; } = 20;
|
public int trayMenuServersLimit { get; set; } = 20;
|
||||||
|
|
||||||
public bool enableHWA { get; set; } = false;
|
public bool enableHWA { get; set; } = false;
|
||||||
|
|
||||||
public string geoSourceUrl { get; set; }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
[Serializable]
|
[Serializable]
|
||||||
|
@ -142,6 +140,7 @@
|
||||||
{
|
{
|
||||||
public string defIEProxyExceptions { get; set; }
|
public string defIEProxyExceptions { get; set; }
|
||||||
public string subConvertUrl { get; set; } = string.Empty;
|
public string subConvertUrl { get; set; } = string.Empty;
|
||||||
|
public string? geoSourceUrl { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
[Serializable]
|
[Serializable]
|
||||||
|
|
|
@ -3005,12 +3005,10 @@ namespace ServiceLib.Resx {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get Geo files source.
|
/// 查找类似 Geo files source (optional) 的本地化字符串。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static string TbSettingsGeoFilesSource
|
public static string TbSettingsGeoFilesSource {
|
||||||
{
|
get {
|
||||||
get
|
|
||||||
{
|
|
||||||
return ResourceManager.GetString("TbSettingsGeoFilesSource", resourceCulture);
|
return ResourceManager.GetString("TbSettingsGeoFilesSource", resourceCulture);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1328,6 +1328,6 @@
|
||||||
<value>Save Interface Layout</value>
|
<value>Save Interface Layout</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbSettingsGeoFilesSource" xml:space="preserve">
|
<data name="TbSettingsGeoFilesSource" xml:space="preserve">
|
||||||
<value>Geo files source</value>
|
<value>Geo files source (optional)</value>
|
||||||
</data>
|
</data>
|
||||||
</root>
|
</root>
|
|
@ -1324,4 +1324,7 @@
|
||||||
<data name="menuStorageUI" xml:space="preserve">
|
<data name="menuStorageUI" xml:space="preserve">
|
||||||
<value>保存界面布局</value>
|
<value>保存界面布局</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="TbSettingsGeoFilesSource" xml:space="preserve">
|
||||||
|
<value>Geo文件来源(可选)</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
|
@ -1204,4 +1204,7 @@
|
||||||
<data name="menuStorageUI" xml:space="preserve">
|
<data name="menuStorageUI" xml:space="preserve">
|
||||||
<value>儲存介面佈局</value>
|
<value>儲存介面佈局</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="TbSettingsGeoFilesSource" xml:space="preserve">
|
||||||
|
<value>Geo文件來源(可選)</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
|
@ -451,7 +451,9 @@ namespace ServiceLib.Services
|
||||||
_config = config;
|
_config = config;
|
||||||
_updateFunc = updateFunc;
|
_updateFunc = updateFunc;
|
||||||
|
|
||||||
var geoUrl = !String.IsNullOrEmpty(config?.guiItem.geoSourceUrl) ? config.guiItem.geoSourceUrl : Global.GeoUrl;
|
var geoUrl = string.IsNullOrEmpty(config?.constItem.geoSourceUrl)
|
||||||
|
? Global.GeoUrl
|
||||||
|
: config.constItem.geoSourceUrl;
|
||||||
var url = string.Format(Global.GeoUrl, geoName);
|
var url = string.Format(Global.GeoUrl, geoName);
|
||||||
var fileName = Utils.GetTempPath(Utils.GetGuid());
|
var fileName = Utils.GetTempPath(Utils.GetGuid());
|
||||||
|
|
||||||
|
|
|
@ -165,7 +165,7 @@ namespace ServiceLib.ViewModels
|
||||||
EnableHWA = _config.guiItem.enableHWA;
|
EnableHWA = _config.guiItem.enableHWA;
|
||||||
SubConvertUrl = _config.constItem.subConvertUrl;
|
SubConvertUrl = _config.constItem.subConvertUrl;
|
||||||
MainGirdOrientation = (int)_config.uiItem.mainGirdOrientation;
|
MainGirdOrientation = (int)_config.uiItem.mainGirdOrientation;
|
||||||
GeoFileSourceUrl = _config.guiItem.geoSourceUrl;
|
GeoFileSourceUrl = _config.constItem.geoSourceUrl;
|
||||||
|
|
||||||
#endregion UI
|
#endregion UI
|
||||||
|
|
||||||
|
@ -318,7 +318,7 @@ namespace ServiceLib.ViewModels
|
||||||
_config.guiItem.enableHWA = EnableHWA;
|
_config.guiItem.enableHWA = EnableHWA;
|
||||||
_config.constItem.subConvertUrl = SubConvertUrl;
|
_config.constItem.subConvertUrl = SubConvertUrl;
|
||||||
_config.uiItem.mainGirdOrientation = (EGirdOrientation)MainGirdOrientation;
|
_config.uiItem.mainGirdOrientation = (EGirdOrientation)MainGirdOrientation;
|
||||||
_config.guiItem.geoSourceUrl = GeoFileSourceUrl;
|
_config.constItem.geoSourceUrl = GeoFileSourceUrl;
|
||||||
|
|
||||||
//systemProxy
|
//systemProxy
|
||||||
_config.systemProxyItem.systemProxyExceptions = systemProxyExceptions;
|
_config.systemProxyItem.systemProxyExceptions = systemProxyExceptions;
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
Cursor="Hand" />
|
Cursor="Hand" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
<TabControl HorizontalContentAlignment="Left">
|
<TabControl HorizontalContentAlignment="Stretch">
|
||||||
<TabItem Header="{x:Static resx:ResUI.TbSettingsCore}">
|
<TabItem Header="{x:Static resx:ResUI.TbSettingsCore}">
|
||||||
<ScrollViewer VerticalScrollBarVisibility="Visible">
|
<ScrollViewer VerticalScrollBarVisibility="Visible">
|
||||||
<Grid Classes="Margin8">
|
<Grid Classes="Margin8">
|
||||||
|
|
|
@ -847,11 +847,10 @@
|
||||||
Margin="{StaticResource Margin8}"
|
Margin="{StaticResource Margin8}"
|
||||||
Style="{StaticResource DefComboBox}" />
|
Style="{StaticResource DefComboBox}" />
|
||||||
|
|
||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Grid.Row="22"
|
Grid.Row="22"
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
Margin="{StaticResource SettingItemMargin}"
|
Margin="{StaticResource Margin8}"
|
||||||
VerticalAlignment="Center"
|
VerticalAlignment="Center"
|
||||||
Style="{StaticResource ToolbarTextBlock}"
|
Style="{StaticResource ToolbarTextBlock}"
|
||||||
Text="{x:Static resx:ResUI.TbSettingsGeoFilesSource}" />
|
Text="{x:Static resx:ResUI.TbSettingsGeoFilesSource}" />
|
||||||
|
@ -860,7 +859,7 @@
|
||||||
Grid.Row="22"
|
Grid.Row="22"
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
Width="300"
|
Width="300"
|
||||||
Margin="{StaticResource SettingItemMargin}"
|
Margin="{StaticResource Margin8}"
|
||||||
IsEditable="True"
|
IsEditable="True"
|
||||||
Style="{StaticResource DefComboBox}" />
|
Style="{StaticResource DefComboBox}" />
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
Loading…
Reference in New Issue