mirror of
https://github.com/BeyondDimension/SteamTools.git
synced 2026-10-20 00:11:04 +08:00
Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 542b528b93 | |||
| 0a4326924d | |||
| e8a9990354 | |||
| 4e72f9ccf9 | |||
| 6df6ed93cb | |||
| 605beeb918 | |||
| 2bdfbefda9 | |||
| 6747549cbc | |||
| 0d4c0b27f7 | |||
| c501066a3d | |||
| 57a6b24dad | |||
| 143011fbd0 | |||
| 11bc9cd440 | |||
| 72e9068571 | |||
| 5842d5f80f |
@@ -213,7 +213,9 @@ Get_NewVer() {
|
||||
|
||||
sleep 1
|
||||
#本地版本 Hash
|
||||
o_sha384=$(cat "AppVer")
|
||||
if [ -f "AppVer" ]; then
|
||||
o_sha384=$(cat "AppVer")
|
||||
fi
|
||||
if [ -e "AppVer" ]; then
|
||||
if [ "${o_sha384,,}" = "${n_sha384,,}" ]; then
|
||||
Show_Run "已是最新版本,是否启动程序?"
|
||||
|
||||
+1
-1
Submodule ref/SteamClient updated: d137c6195b...7a7aca2567
@@ -11,6 +11,12 @@ public sealed partial class App : Application
|
||||
{
|
||||
const string TAG = "AvaApp";
|
||||
|
||||
public App()
|
||||
{
|
||||
OpenBrowserCommand = ReactiveCommand.Create<object?>(OpenBrowserCommandCore);
|
||||
CopyToClipboardCommand = ReactiveCommand.Create<object?>(CopyToClipboardCommandCore);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取当前主窗口
|
||||
/// </summary>
|
||||
@@ -225,7 +231,9 @@ public sealed partial class App : Application
|
||||
|
||||
public static FontFamily DefaultFontFamily => _DefaultFontFamily.Value;
|
||||
|
||||
public async void OpenBrowserCommand(object? url)
|
||||
public ICommand OpenBrowserCommand { get; }
|
||||
|
||||
public async void OpenBrowserCommandCore(object? url)
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -256,7 +264,9 @@ public sealed partial class App : Application
|
||||
}
|
||||
}
|
||||
|
||||
public async void CopyToClipboardCommand(object text)
|
||||
public ICommand CopyToClipboardCommand { get; }
|
||||
|
||||
public async void CopyToClipboardCommandCore(object? text)
|
||||
{
|
||||
try
|
||||
{
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
x:CompileBindings="True">
|
||||
<Styles.Resources>
|
||||
<ResourceDictionary>
|
||||
<sys:Double x:Key="TitleBarHeight">60</sys:Double>
|
||||
<Thickness x:Key="TitleBarAfterMargin">0,60,0,0</Thickness>
|
||||
<sys:Double x:Key="TitleBarHeight">50</sys:Double>
|
||||
<Thickness x:Key="TitleBarAfterMargin">0,50,0,0</Thickness>
|
||||
<sys:Double x:Key="SplashScreenImageWidth">100</sys:Double>
|
||||
|
||||
<Thickness x:Key="PageMargin">10</Thickness>
|
||||
|
||||
@@ -210,7 +210,7 @@
|
||||
<wnd:MinMaxCloseControl
|
||||
Name="SystemCaptionButtons"
|
||||
Height="{Binding TemplateSettings.TitleBarHeight, RelativeSource={RelativeSource TemplatedParent}}"
|
||||
Margin="18,0"
|
||||
Margin="14,0"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Top" />
|
||||
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
using Avalonia.Markup.Xaml.MarkupExtensions;
|
||||
using Avalonia.Rendering.Composition;
|
||||
using FluentAvalonia.UI.Controls.Experimental;
|
||||
using FluentAvalonia.UI.Navigation;
|
||||
|
||||
namespace BD.WTTS.UI.Views.Pages;
|
||||
|
||||
@@ -17,6 +19,7 @@ public class PageBase : UserControl
|
||||
}
|
||||
|
||||
_disposables.Add(UISettings.WindowBackgroundCustomImage.Subscribe(x => IsShowBackgroundImage = !x));
|
||||
|
||||
//AddHandler(Frame.NavigatingFromEvent, FrameNavigatingFrom, RoutingStrategies.Direct);
|
||||
//AddHandler(Frame.NavigatedToEvent, FrameNavigatedTo, RoutingStrategies.Direct);
|
||||
}
|
||||
@@ -142,6 +145,7 @@ public class PageBase : UserControl
|
||||
|
||||
//_previewImageHost = e.NameScope.Find<IconSourceElement>("PreviewImageElement");
|
||||
//_detailsHost = e.NameScope.Find<StackPanel>("DetailsTextHost");
|
||||
|
||||
_optionsHost = e.NameScope.Find<Panel>("OptionsRegion");
|
||||
_tabsHost = e.NameScope.Find<Border>("TabRegion");
|
||||
_detailsPanel = e.NameScope.Find<Panel>("PageDetails");
|
||||
@@ -270,33 +274,28 @@ public class PageBase : UserControl
|
||||
ec.ImplicitAnimations = ani;
|
||||
}
|
||||
|
||||
//private void FrameNavigatingFrom(object sender, NavigatingCancelEventArgs e)
|
||||
//private void FrameNavigatingFrom(object? sender, NavigatingCancelEventArgs e)
|
||||
//{
|
||||
// // If TargetType is not set, we know we're currently on a CoreControls page since those
|
||||
// // are grouped pages - whereas, FA controls only display one control per page and
|
||||
// // set all the extra properties
|
||||
// bool isFAControlPage = TargetType != null;
|
||||
|
||||
// // Only setup the ConnectedAnimation if it makes sense
|
||||
// if ((!isFAControlPage && e.SourcePageType == typeof(CoreControlsPageViewModel)) ||
|
||||
// (isFAControlPage && e.SourcePageType == typeof(FAControlsOverviewPageViewModel)))
|
||||
// if ((e.SourcePageType == typeof(HomePageViewModel)) ||
|
||||
// (e.SourcePageType == typeof(PluginStorePageViewModel)))
|
||||
// {
|
||||
// // Only setup the Back connected animation if we're going back to the
|
||||
// // controls list pages
|
||||
// var svc = ConnectedAnimationService.GetForView(TopLevel.GetTopLevel(this));
|
||||
// svc.PrepareToAnimate("BackAnimation", (Control)_previewImageHost.Parent);
|
||||
// NavigationService.Instance.PreviousPage = this;
|
||||
// //NavigationService.Instance.PreviousPage = this;
|
||||
// }
|
||||
//}
|
||||
|
||||
//private void FrameNavigatedTo(object sender, NavigationEventArgs e)
|
||||
//private void FrameNavigatedTo(object? sender, NavigationEventArgs e)
|
||||
//{
|
||||
// var svc = ConnectedAnimationService.GetForView(TopLevel.GetTopLevel(this));
|
||||
// var animation = svc.GetAnimation("ForwardAnimation");
|
||||
|
||||
// if (animation != null)
|
||||
// {
|
||||
// var coordinated = new List<Visual>
|
||||
// var coordinated = new List<Visual?>
|
||||
// {
|
||||
// _optionsHost,
|
||||
// _detailsHost,
|
||||
|
||||
@@ -24,10 +24,10 @@
|
||||
</Style>
|
||||
|
||||
<Style Selector="ui|NavigationView.AppNav[IsBackButtonVisible=False] SplitView /template/ ContentPresenter#PART_PanePresenter">
|
||||
<Setter Property="Margin" Value="0 50 0 0" />
|
||||
<Setter Property="Margin" Value="0 42 0 0" />
|
||||
</Style>
|
||||
<Style Selector="ui|NavigationView.AppNav[IsBackButtonVisible=True] SplitView /template/ ContentPresenter#PART_PanePresenter">
|
||||
<Setter Property="Margin" Value="0 10 0 0" />
|
||||
<Setter Property="Margin" Value="0 2 0 0" />
|
||||
</Style>
|
||||
|
||||
<Style Selector="ui|NavigationViewItem.AppNav">
|
||||
@@ -331,7 +331,7 @@
|
||||
PaneDisplayMode="Left">
|
||||
<ui:NavigationView.Resources>
|
||||
<!-- Override this -->
|
||||
<Thickness x:Key="NavigationViewContentMargin">0,60,0,0</Thickness>
|
||||
<Thickness x:Key="NavigationViewContentMargin">0,50,0,0</Thickness>
|
||||
</ui:NavigationView.Resources>
|
||||
<ui:NavigationView.Styles>
|
||||
<Style Selector="Button#NavigationViewBackButton">
|
||||
@@ -342,7 +342,7 @@
|
||||
<Setter Property="Content" Value="" />
|
||||
</Style>
|
||||
<Style Selector="Grid#PaneToggleButtonGrid">
|
||||
<Setter Property="Margin" Value="5 5 0 0" />
|
||||
<Setter Property="Margin" Value="5 0 0 0" />
|
||||
<Setter Property="ToolTip.Tip" Value="{Binding Path=Res.Back, Mode=OneWay, Source={x:Static s:ResourceService.Current}}" />
|
||||
<Setter Property="ToolTip.Placement" Value="Bottom" />
|
||||
</Style>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
d:DesignHeight="450"
|
||||
d:DesignWidth="800"
|
||||
x:CompileBindings="True"
|
||||
x:DataType="spp:HomePageViewModel"
|
||||
x:DataType="spp:PluginStorePageViewModel"
|
||||
mc:Ignorable="d">
|
||||
<ScrollViewer Padding="20">
|
||||
<!--<spp:ContentLoader IsLoading="False">-->
|
||||
@@ -23,7 +23,7 @@
|
||||
Text="插件商店是什么?"
|
||||
Theme="{StaticResource TitleTextBlockStyle}" />
|
||||
|
||||
<TextBlock Text="3.0版本的计划是将所有功能插件化,拆分后按需下载安装,每个人都可以只下载自己需要的插件功能使用,并且支持所有人都可以开发插件,等等还有许多暂时不方便说的内容,因为计划的过于异想天开,且遇到的问题有点多,所以开发难度有点点大,这个功能上线还需要一点时间,对一直等待的大家说声抱歉麻烦在多等等了😭。" TextWrapping="WrapWithOverflow" />
|
||||
<TextBlock Text="3.0 版本的计划是将所有功能插件化,拆分后按需下载安装,每个人都可以只下载自己需要的插件功能使用,并且支持所有人都可以开发插件,等等还有许多暂时不方便说的内容,因为计划的过于异想天开,且遇到的问题有点多,所以开发难度有点点大,这个功能上线还需要一点时间,上线后 3.0 也将正式发布正式版,对一直等待的大家说声抱歉麻烦在多等等了 😭,如果您不习惯启动后是插件商店页面也可以在界面设置中修改启动默认页。" TextWrapping="WrapWithOverflow" />
|
||||
<TextBlock
|
||||
Margin="-3,0,0,0"
|
||||
Text="已安装功能"
|
||||
@@ -55,11 +55,12 @@
|
||||
<DataTemplate DataType="spp:TabItemViewModel">
|
||||
<Border spp:Animations.EnableAnimations="True">
|
||||
<Button
|
||||
Command="{Binding $parent[spp:HomePage].((spp:HomePageViewModel)DataContext).NavgationToMenuPageCommand}"
|
||||
Command="{Binding $parent[spp:PluginStorePage].((spp:PluginStorePageViewModel)DataContext).NavgationToMenuPageCommand}"
|
||||
CommandParameter="{Binding}"
|
||||
Theme="{StaticResource NavButtonStyle}">
|
||||
<Grid RowDefinitions="3*,*">
|
||||
<Border
|
||||
Name="IconHost"
|
||||
HorizontalAlignment="Stretch"
|
||||
VerticalAlignment="Stretch"
|
||||
CornerRadius="4 4 0 0"
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
using FluentAvalonia.UI.Controls.Experimental;
|
||||
using FluentAvalonia.UI.Navigation;
|
||||
|
||||
namespace BD.WTTS.UI.Views.Pages;
|
||||
|
||||
public partial class PluginStorePage : UserControl
|
||||
@@ -5,5 +8,85 @@ public partial class PluginStorePage : UserControl
|
||||
public PluginStorePage()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.SetViewModel<PluginStorePageViewModel>(useCache: true);
|
||||
|
||||
// Use the frame events here to ensure ConnectedAnimations still work with
|
||||
// Back/Forward navigation and not just explicit page invokes
|
||||
//AddHandler(Frame.NavigatingFromEvent, OnNavigatingFrom, RoutingStrategies.Direct);
|
||||
//AddHandler(Frame.NavigatedToEvent, OnNavigatedTo, RoutingStrategies.Direct);
|
||||
|
||||
}
|
||||
|
||||
//private void PluginStorePage_Click(object? sender, RoutedEventArgs e)
|
||||
//{
|
||||
// if (sender != null && sender is Button b && b.DataContext is TabItemViewModel fci)
|
||||
// {
|
||||
// _animationPage = fci;
|
||||
// //NavigationService.Instance.NavigateFromContext(fci);
|
||||
// }
|
||||
//}
|
||||
|
||||
//private void OnNavigatedTo(object? sender, NavigationEventArgs e)
|
||||
//{
|
||||
// if (_animationPage == null)
|
||||
// return;
|
||||
|
||||
// var svc = ConnectedAnimationService.GetForView(TopLevel.GetTopLevel(this));
|
||||
// var anim = svc.GetAnimation("BackAnimation");
|
||||
|
||||
// if (anim == null)
|
||||
// return;
|
||||
|
||||
// var item = this.GetVisualDescendants()
|
||||
// ?.Where(x => x is Button && x.DataContext == _animationPage)
|
||||
// ?.FirstOrDefault()
|
||||
// ?.GetVisualDescendants()
|
||||
// .Where(x => x is Border && x.Name == "IconHost")
|
||||
// .FirstOrDefault();
|
||||
|
||||
// var presenter = item;// GetAnimationSource();
|
||||
|
||||
// // In WinUI, ConnectedAnimation is somehow exempt from all clipping behaviors
|
||||
// // Here, we are not, so disable ClipToBounds on all elements in the SettingsExpander
|
||||
// // The rest are taken care of in the xaml.
|
||||
// // NOTE: The ScrollViewer is not changed here as that's important for scrolling - thus
|
||||
// // the animation will be cut off, but the back animation is pretty fast and mostly is
|
||||
// // only visible closer to the element so we're ok, I think
|
||||
// var x = presenter?.GetVisualParent();
|
||||
|
||||
// while (!(x is ScrollContentPresenter) && x != null)
|
||||
// {
|
||||
// x.ClipToBounds = false;
|
||||
// x = x.GetVisualParent();
|
||||
// }
|
||||
|
||||
// anim.Configuration = new DirectConnectedAnimationConfiguration();
|
||||
// anim.TryStart(presenter);
|
||||
//}
|
||||
|
||||
//private void OnNavigatingFrom(object? sender, NavigatingCancelEventArgs e)
|
||||
//{
|
||||
// if (_animationPage == null)
|
||||
// return;
|
||||
|
||||
// // We're not navigating to a control page, don't set up the animation & clear
|
||||
// // the previous animation source
|
||||
// if (!e.SourcePageType.Name.Equals(nameof(TabItemViewModel)))
|
||||
// {
|
||||
// _animationPage = null;
|
||||
// _animationPage = null;
|
||||
// return;
|
||||
// }
|
||||
|
||||
// var item = this.GetVisualDescendants()
|
||||
// ?.Where(x => x is ListBoxItem && x.DataContext == _animationPage)
|
||||
// ?.FirstOrDefault()
|
||||
// ?.GetVisualDescendants()
|
||||
// .Where(x => x is Viewbox && x.Name == "IconHost")
|
||||
// .FirstOrDefault();
|
||||
// var svc = ConnectedAnimationService.GetForView(TopLevel.GetTopLevel(this));
|
||||
// svc.PrepareToAnimate("ForwardAnimation", item);
|
||||
//}
|
||||
|
||||
//private TabItemViewModel? _animationPage;
|
||||
}
|
||||
|
||||
@@ -425,6 +425,12 @@ public sealed class ScriptManager : GeneralHttpClientFactory, IScriptManager
|
||||
//item.Content = string.Empty;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
await TryReadFileAsync(item, true);
|
||||
//item.Content = string.Empty;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
return scripts;
|
||||
|
||||
@@ -721,6 +721,7 @@
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Center"
|
||||
IsVisible="{Binding Source={x:Static s:ProxyService.Current}, Path=ProxyStatus, Mode=OneWay}"
|
||||
Orientation="Horizontal"
|
||||
Spacing="8">
|
||||
<StackPanel.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
@@ -736,15 +737,26 @@
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
</Style>
|
||||
</StackPanel.Styles>
|
||||
<TextBlock>
|
||||
<Run Text="{x:Static spp:Strings.CommunityFix_ProxyMode}" />
|
||||
<Run Text="{Binding Source={x:Static ms:ProxySettings.ProxyMode}, Path=Value, Mode=OneWay, Converter={StaticResource EnumLocalizationNameConverter}}" />
|
||||
<Button Theme="{StaticResource TransparentButton}">
|
||||
<ToolTip.Tip>
|
||||
<TextBlock>
|
||||
<Run FontSize="16" Text="Q:为什么加速后流量一直显示 0KB ?" />
|
||||
<LineBreak />
|
||||
<Run Text="A:流量统计图表是用于查看实时流量数据信息,您需要先访问对应的网站,这边才会有相应的流量波动数据,请检查是否已经选择了对应的网站加速项目,如果确定有正常勾选加速项目并且访问网站依然无流量,则可能是加速的监听服务没有启用成功,尝试更换加速模式。" />
|
||||
<LineBreak />
|
||||
<LineBreak />
|
||||
<Run FontSize="16" Text="Q:加速后对应网站打不开显示SSL错误或者Steam浏览器显示-100错误?" />
|
||||
<LineBreak />
|
||||
<Run Text="A:可以尝试执行以下操作进行修复,关闭加速,点击加速设置-移除证书再安装证书,重开加速。或者加速设置-代理设置-尝试更换doh地址或者关闭doh使用dns等方案。" />
|
||||
</TextBlock>
|
||||
</ToolTip.Tip>
|
||||
<ui:FontIcon FontSize="22" Glyph="" />
|
||||
</Button>
|
||||
<TextBlock Text="{x:Static spp:Strings.CommunityFix_ProxyMode}" />
|
||||
<TextBlock Text="{Binding Source={x:Static ms:ProxySettings.ProxyMode}, Path=Value, Mode=OneWay, Converter={StaticResource EnumLocalizationNameConverter}}" />
|
||||
|
||||
<Run Text=" " />
|
||||
|
||||
<Run Text="{x:Static spp:Strings.CommunityFix_EnableScriptService}" />
|
||||
<Run Text="{Binding Source={x:Static s:ProxyService.Current}, Path=IsEnableScript, Converter={StaticResource StringFormatConverter}}" />
|
||||
</TextBlock>
|
||||
<TextBlock Text="{x:Static spp:Strings.CommunityFix_EnableScriptService}" />
|
||||
<TextBlock Text="{Binding Source={x:Static s:ProxyService.Current}, Path=IsEnableScript, Converter={StaticResource StringFormatConverter}}" />
|
||||
</StackPanel>
|
||||
|
||||
<spp:AdControl
|
||||
|
||||
+1
-1
@@ -696,7 +696,7 @@ Windows Registry Editor Version 5.00
|
||||
|
||||
var idsFile = Path.Combine(localCachePath, "ids.json");
|
||||
|
||||
var accountRemarks = Ioc.Get<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
var accountRemarks = Ioc.Get_Nullable<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
var accList = File.Exists(idsFile) ? JTokenHelper.ReadDict(idsFile).ToList() : null;
|
||||
|
||||
if (accList.Any_Nullable())
|
||||
|
||||
@@ -58,7 +58,7 @@ public partial class AccountItems : ReactiveUserControl<PlatformAccount>
|
||||
3 => idConvert.Id32,
|
||||
_ => idConvert.Id64,
|
||||
};
|
||||
App.Instance.CopyToClipboardCommand(id);
|
||||
App.Instance.CopyToClipboardCommandCore(id);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -113,7 +113,7 @@ public sealed partial class IdleCardPageViewModel : ViewModelBase
|
||||
{
|
||||
if (SteamLoginState.Success && SteamLoginState.SteamId != (ulong?)SteamConnectService.Current.CurrentSteamUser?.SteamId64)
|
||||
{
|
||||
Toast.Show(ToastIcon.Error, Strings.SteamIdle_LoginSteamUserError);
|
||||
Toast.Show(ToastIcon.Warning, Strings.SteamIdle_LoginSteamUserError);
|
||||
//RunState = false;
|
||||
//RunLoaingState = false;
|
||||
//return;
|
||||
@@ -228,10 +228,9 @@ public sealed partial class IdleCardPageViewModel : ViewModelBase
|
||||
LoginViewModel.Close += async _ =>
|
||||
{
|
||||
IsLogin = SteamLoginState.Success;
|
||||
ViewState = 1;
|
||||
await LoadBadges();
|
||||
SteamAppsSort();
|
||||
|
||||
ViewState = 1;
|
||||
};
|
||||
ViewState = 0;
|
||||
//var vm = new IdleSteamLoginPageViewModel(ref SteamLoginState);
|
||||
|
||||
@@ -529,7 +529,10 @@
|
||||
IsVisible="{Binding !IdleGameList.Count}"
|
||||
Text="未获取到挂卡游戏数据" />
|
||||
</StackPanel>
|
||||
<ItemsRepeater DockPanel.Dock="Bottom" ItemsSource="{Binding IdleGameList}">
|
||||
<ItemsRepeater
|
||||
DockPanel.Dock="Bottom"
|
||||
ItemsSource="{Binding IdleGameList}"
|
||||
VerticalCacheLength="50">
|
||||
<ItemsRepeater.Layout>
|
||||
<UniformGridLayout
|
||||
ItemsJustification="Start"
|
||||
|
||||
@@ -152,4 +152,6 @@ public partial interface IApplication
|
||||
System.Drawing.Size? GetScreenSize() => null;
|
||||
|
||||
bool? IsAnyWindowNotMinimized() => null;
|
||||
|
||||
async void OpenBrowserCommandCore(object? url) => await Browser2.OpenAsync(url?.ToString());
|
||||
}
|
||||
|
||||
@@ -160,15 +160,6 @@ public static class ThirdPartyLoginHelper
|
||||
|
||||
static IDisposable? serverDisposable;
|
||||
|
||||
/// <summary>
|
||||
/// 释放 WebSocket Server 占用资源
|
||||
/// </summary>
|
||||
public static void DisposeServer()
|
||||
{
|
||||
serverDisposable?.Dispose();
|
||||
serverDisposable = null;
|
||||
}
|
||||
|
||||
static void StartServer(IApplication app)
|
||||
{
|
||||
if (ws != null) return;
|
||||
@@ -196,6 +187,15 @@ public static class ThirdPartyLoginHelper
|
||||
});
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 释放 WebSocket Server 占用资源
|
||||
/// </summary>
|
||||
public static void DisposeServer()
|
||||
{
|
||||
serverDisposable?.Dispose();
|
||||
serverDisposable = null;
|
||||
}
|
||||
|
||||
static Aes? tempAes;
|
||||
static bool isBind;
|
||||
static WindowViewModel? vm;
|
||||
@@ -220,7 +220,7 @@ public static class ThirdPartyLoginHelper
|
||||
public static async Task StartAsync(WindowViewModel vm, ExternalLoginChannel channel, bool isBind)
|
||||
{
|
||||
var app = IApplication.Instance;
|
||||
if (!OperatingSystem2.IsAndroid() && !OperatingSystem2.IsIOS())
|
||||
if (!OperatingSystem2.IsAndroid() && !OperatingSystem2.IsIOS() && !OperatingSystem2.IsMacOS())
|
||||
{
|
||||
// Android/iOS 使用 URL Scheme 回调
|
||||
StartServer(app);
|
||||
@@ -273,8 +273,10 @@ public static class ThirdPartyLoginHelper
|
||||
qs.Add("dg", DeviceIdHelper.DeviceIdG.ToStringN());
|
||||
qs.Add("dr", DeviceIdHelper.DeviceIdR);
|
||||
qs.Add("dn", DeviceIdHelper.DeviceIdN);
|
||||
if (OperatingSystem.IsMacOS())
|
||||
if (OperatingSystem2.IsMacOS())
|
||||
{
|
||||
qs.Add("isUS", "true");
|
||||
}
|
||||
var ub = new UriBuilder(apiBaseUrl)
|
||||
{
|
||||
Path = $"/identity/v1/externallogin/{(int)channel}",
|
||||
|
||||
@@ -95,10 +95,11 @@ public sealed class AdvertiseService : ReactiveObject
|
||||
}
|
||||
}
|
||||
|
||||
private static async void ClickAdvertisement(AdvertisementDTO dto)
|
||||
static async void ClickAdvertisement(AdvertisementDTO? dto)
|
||||
{
|
||||
if (dto != null)
|
||||
{
|
||||
//IApplication.Instance.OpenBrowserCommandCore(dto.Url);
|
||||
await Browser2.OpenAsync(dto.Url);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -224,6 +224,12 @@ public sealed class UserService : ReactiveObject
|
||||
/// <returns></returns>
|
||||
public async Task OpenAuthUrl(string url)
|
||||
{
|
||||
if (url.StartsWith(Constants.Urls.WattGame, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
OpenAuthUrl(url, FastLoginWebChannel.WattGame);
|
||||
return;
|
||||
}
|
||||
|
||||
var token = await userManager.GetAuthTokenAsync();
|
||||
if (token == null)
|
||||
{
|
||||
|
||||
@@ -524,7 +524,7 @@ public sealed class SteamConnectService
|
||||
|
||||
#region 加载备注信息和 JumpList
|
||||
|
||||
var accountRemarks = Ioc.Get<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
var accountRemarks = Ioc.Get_Nullable<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
|
||||
#if WINDOWS
|
||||
List<(string title, string applicationPath, string iconResourcePath, string arguments, string description, string customCategory)>? jumplistData = new();
|
||||
|
||||
@@ -318,7 +318,7 @@ partial class Startup // 自定义控制台命令参数
|
||||
var users = steamService.GetRememberUserList();
|
||||
|
||||
var accountRemarks =
|
||||
Ioc.Get<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
Ioc.Get_Nullable<IPartialGameAccountSettings>()?.AccountRemarks;
|
||||
|
||||
var sUsers = users.Select(s =>
|
||||
{
|
||||
|
||||
@@ -10,6 +10,13 @@ public sealed class PluginStorePageViewModel : TabItemViewModel
|
||||
|
||||
public override string IconKey => "avares://BD.WTTS.Client.Avalonia/UI/Assets/Icons/home.ico";
|
||||
|
||||
public ICommand NavgationToMenuPageCommand { get; }
|
||||
|
||||
public PluginStorePageViewModel()
|
||||
{
|
||||
NavgationToMenuPageCommand = ReactiveCommand.Create<TabItemViewModel>(NavgationToMenuPage);
|
||||
}
|
||||
|
||||
public void NavgationToMenuPage(TabItemViewModel tabItem)
|
||||
{
|
||||
INavigationService.Instance.Navigate(tabItem.PageType, NavigationTransitionEffect.FromBottom);
|
||||
|
||||
Reference in New Issue
Block a user