Skip to content

Commit

Permalink
库存游戏列表添加clienticon图标显示
Browse files Browse the repository at this point in the history
无边框窗口化功能添加操作窗口历史记录
  • Loading branch information
rmbadmin committed Jan 30, 2021
1 parent 9fbe640 commit 866ad1a
Show file tree
Hide file tree
Showing 16 changed files with 272 additions and 145 deletions.
30 changes: 14 additions & 16 deletions release-keylol.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,16 @@ Steam++只在keylol论坛与github发布,为了账号安全,请不要到其

## 更新内容

### 1.1.0
### 1.1.2
```
本地令牌市场交易确认功能上线啦(目前功能较简单,待完善)
新增内置steam史低查询脚本
新增Steam启动消息通知设置项
新增github gist代理服务支持
修复某些情况配置文件读取出错
修复discord更新下载和图片失效
修复twitch聊天频道连接失效
修复gihub头像资源加载失败
新增pixiv图片的代理选项来修复pixiv图片失效
修改了本地反代解析域名的方式,这样出问题以后可以直接热更新
还修复了一些没有记下来的bug...
新增在账号切换的状态栏右下角位置登录新账号功能
账号切换功能可以实时刷新获取Steam新登录的账号数据
关于里加入FAQ常见问题疑难解答
修改谷歌验证码代理方式为全局跳转www.recaptcha.net
记录更详细错误日志
修复某些情况下开机自启失效问题
修复配置文件加载时提示根元素错误
配置文件备份机制完善,如果配置文件出错会提示还原上次读取成功的配置
```


Expand Down Expand Up @@ -112,11 +109,12 @@ Steam++只在keylol论坛与github发布,为了账号安全,请不要到其
> [Github](https://github.com/rmbadmin/SteamTools/releases)
> 分流下载:
> [hide]
> [蓝奏云](https://wws.lanzous.com/icwdPkpnu1e)
> [百度云](https://pan.baidu.com/s/1EG8e1Oi4Mg2KCiF42oKnig)
> [蓝奏云](https://wws.lanzous.com/ioCJnl1hdli)
> [百度云](https://pan.baidu.com/s/1j8Y2a-8X7tpa5BnEFLOxbg)
> 提取码:stpp
> [/hide]
> EXE 大小:4.87MB
> MD5:8965D1A2EC7688F1EDEF3DA81667A009
> EXE 大小:4.88MB
> EXE MD5:023FB09444B774354827C0A7D6547DEE
> ZIP MD5:51D8921256DF485FBE9F4AF3F05E2564
> [查毒链接](https://www.virustotal.com/gui/file/9931d6034c3b8f6c362ecb991a21d205623734fbee201e62f813d05f50347e64/detection)
虽然没有什么杀毒软件报毒,但是使用过程中可能遇到windows defender误报,您可以选择添加信任。
46 changes: 43 additions & 3 deletions resources/RewardRecord.json
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,15 @@
"PayType": 2,
"Remark": "给个建议 令牌页面保持前端显示",
"PayTime": "2021-01-14 11:07:54"
},
},
{
"Name": "**天",
"Amount": 18,
"OrderNumber": "",
"PayType": 1,
"Remark": "切换账号很好用,脚本还不知道怎么用。加油",
"PayTime": "2021-01-23 19:37:54"
},
{
"Name": "**浩",
"Amount": 6.66,
Expand All @@ -318,6 +326,22 @@
"PayType": 2,
"Remark": "Sherry",
"PayTime": "2021-01-23 09:16:11"
},
{
"Name": "**胜",
"Amount": 6.66,
"OrderNumber": "",
"PayType": 1,
"Remark": "大佬牛皮,支持一哈",
"PayTime": "2021-01-24 09:28:07"
},
{
"Name": "*枫",
"Amount": 6.66,
"OrderNumber": "",
"PayType": 1,
"Remark": "",
"PayTime": "2021-01-28 16:42:49"
},
{
"Name": "**志",
Expand Down Expand Up @@ -352,11 +376,27 @@
"PayTime": "2021-01-28 11:11:38"
},
{
"Name": "*枫",
"Name": "匿名",
"Amount":1,
"OrderNumber": "",
"PayType": 2,
"Remark": "为啥我更新不了1.1.1版本",
"PayTime": "2021-01-28 17:05:42"
},
{
"Name": "*晨",
"Amount": 6.66,
"OrderNumber": "",
"PayType": 1,
"Remark": "加油加油💪",
"PayTime": "2021-01-29 20:40:54"
},
{
"Name": "**桐",
"Amount": 0.58,
"OrderNumber": "",
"PayType": 1,
"Remark": "",
"PayTime": "2021-01-28 16:42:49"
"PayTime": "2021-01-29 12:11:16"
}
]
2 changes: 1 addition & 1 deletion source/SteamTool.Model/Const.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class Const
public const string STEAMAPP_LIST_URL = "https://api.steampowered.com/ISteamApps/GetAppList/v2";
public const string STORE_APP_URL = "https://store.steampowered.com/app/{0}";
public const string STEAMAPP_LOGO_URL = "https://steamcdn-a.akamaihd.net/steamcommunity/public/images/apps/{0}/{1}.jpg";
public const string STEAMAPP_ICON_URL = "https://steamcdn-a.akamaihd.net/steamcommunity/public/images/apps/{0}/{1}";
public const string STEAMAPP_ICON_URL = "https://steamcdn-a.akamaihd.net/steamcommunity/public/images/apps/{0}/{1}.jpg";
public const string STEAMAPP_CAPSULE_URL = "https://steamcdn-a.akamaihd.net/steam/apps/{0}/capsule_184x69.jpg";
public const string STEAMAPP_HEADIMAGE_URL = "https://steamcdn-a.akamaihd.net/steam/apps/{0}/header.jpg";
public const string STEAM_MEDIA_URL = "https://steamcdn-a.akamaihd.net/steam/apps/{0}/movie_max.webm";
Expand Down
4 changes: 3 additions & 1 deletion source/SteamTool.Model/SteamModel/SteamApp.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ public SteamApp()

public bool IsInstalled { get; set; }

public string InstalledDir { get; set; }

public string Name { get; set; }

public string Logo { get; set; }
Expand All @@ -30,7 +32,7 @@ public SteamApp()

public string HeaderLogoUrl => string.Format(Const.STEAMAPP_CAPSULE_URL, AppId);

public string IconUrl => string.IsNullOrEmpty(Icon) ? null : string.Format(Const.STEAMAPP_LOGO_URL, AppId, Icon);
public string IconUrl => string.IsNullOrEmpty(Icon) ? null : string.Format(Const.STEAMAPP_ICON_URL, AppId, Icon);

public Process Process { get; set; }

Expand Down
9 changes: 8 additions & 1 deletion source/SteamTool.Steam.Service/Local/SteamworksApiService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ public List<SteamApp> OwnsApps(List<SteamApp> apps)
AppId = s.AppId,
Name = s.Name,
Type = Enum.TryParse<SteamAppTypeEnum>(GetAppData(s.AppId, "type"), true, out var result) ? result : SteamAppTypeEnum.Unknown,
//Logo = SteamClient.SteamApps001.GetAppData(s.AppId, "logo"),
Icon = GetAppData(s.AppId, "icon"),
Logo = GetAppData(s.AppId, "logo"),
InstalledDir = GetAppInstallDir(s.AppId),
IsInstalled = IsAppInstalled(s.AppId)
}).ToList();
}
Expand All @@ -85,6 +87,11 @@ public bool IsAppInstalled(uint appid)
return SteamClient.SteamApps008.IsAppInstalled(appid);
}

public string GetAppInstallDir(uint appid)
{
return SteamClient.SteamApps008.GetAppInstallDir(appid);
}

public string GetIPCountry()
{
return SteamClient.SteamUtils.GetIPCountry();
Expand Down
23 changes: 16 additions & 7 deletions source/SteamTools/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,20 @@ protected override void OnStartup(StartupEventArgs e)
#endif
App.Current.ShutdownMode = ShutdownMode.OnExplicitShutdown;
this.DispatcherUnhandledException += App_DispatcherUnhandledException;
DispatcherHelper.UIDispatcher = this.Dispatcher;
DispatcherHelper.UIDispatcher = this.Dispatcher;
SettingsHost.Load();
this.compositeDisposable.Add(SettingsHost.Save);
this.compositeDisposable.Add(ProxyService.Current.Shutdown);
this.compositeDisposable.Add(SteamConnectService.Current.Shutdown);
this.compositeDisposable.Add(() =>
{
if (TaskbarService.Current.Taskbar != null)
{
//TaskbarService.Current.Taskbar.Icon = null; //避免托盘图标没有自动消失
TaskbarService.Current.Taskbar.Icon.Dispose();
}
});

Microsoft.Win32.SystemEvents.SessionEnding += SystemEvents_SessionEnding;

if (e.Args.ContainsArg("-log") || GeneralSettings.IsEnableLogRecord)
Expand Down Expand Up @@ -204,11 +213,11 @@ private void App_DispatcherUnhandledException(object sender, System.Windows.Thre
/// <param name="e"></param>
protected override void OnExit(ExitEventArgs e)
{
if (TaskbarService.Current.Taskbar != null)
{
//TaskbarService.Current.Taskbar.Icon = null; //避免托盘图标没有自动消失
TaskbarService.Current.Taskbar.Icon.Dispose();
}
//if (TaskbarService.Current.Taskbar != null)
//{
// //TaskbarService.Current.Taskbar.Icon = null; //避免托盘图标没有自动消失
// TaskbarService.Current.Taskbar.Icon.Dispose();
//}
this.compositeDisposable.Dispose();
base.OnExit(e);
}
Expand Down Expand Up @@ -268,7 +277,7 @@ private void RaisePropertyChanged([CallerMemberName] string propertyName = null)
#endregion

#region IDisposable members
private readonly LivetCompositeDisposable compositeDisposable = new LivetCompositeDisposable();
public readonly LivetCompositeDisposable compositeDisposable = new LivetCompositeDisposable();
ICollection<IDisposable> IDisposableHolder.CompositeDisposable => this.compositeDisposable;

void IDisposable.Dispose()
Expand Down
2 changes: 1 addition & 1 deletion source/SteamTools/Resources/Styles/Controls.ListBox.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<Setter Property="BorderBrush"
Value="{DynamicResource BorderBrushKey}" />
<Setter Property="BorderThickness"
Value=".99,.99,0,.99" />
Value=".99,.99,.99,.99" />
<Setter Property="FocusVisualStyle"
Value="{x:Null}" />
<Setter Property="ItemContainerStyle">
Expand Down
2 changes: 1 addition & 1 deletion source/SteamTools/Services/AutoUpdateService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,7 @@ private void OverwriteUpgrade(string zipFile)
if (ZipHelper.UnpackFiles(zipFile, out_dir))
{
File.Delete(zipFile);
App.Instance.compositeDisposable.Dispose();
var batpath = Path.Combine(AppContext.BaseDirectory, "update.cmd");
File.WriteAllText(batpath,
string.Format(SteamTool.Core.Properties.Resources.ProgramUpdateCmd,
Expand All @@ -166,7 +167,6 @@ private void OverwriteUpgrade(string zipFile)
p.StartInfo.CreateNoWindow = true;//不显示程序窗口
//管理员权限运行
p.StartInfo.Verb = "runas";
App.Current.Shutdown();
p.Start();//启动程序
}
}
Expand Down
16 changes: 16 additions & 0 deletions source/SteamTools/ViewModels/Content/Game/GameCommonViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
using SteamTool.Core.Common;
using System.Runtime.InteropServices;
using System.Windows.Forms;
using System.ComponentModel;

namespace SteamTools.ViewModels
{
Expand Down Expand Up @@ -45,6 +46,20 @@ public HandleWindow SelectWindow

#endregion

private BindingList<HandleWindow> _WindowList = new BindingList<HandleWindow>();
public BindingList<HandleWindow> WindowList
{
get { return this._WindowList; }
set
{
if (this._WindowList != value)
{
this._WindowList = value;
this.RaisePropertyChanged();
}
}
}

public void Cross_MouseDown()
{
//System.Windows.Forms.Cursor.Current = System.Windows.Forms.Cursors.Cross;
Expand Down Expand Up @@ -75,6 +90,7 @@ private void MouseHook_OnMouseUp(object sender, Point p)
Handle = handle,
Process = Process.GetProcessById(pid)
};
WindowList.Add(SelectWindow);
}

private bool IsHasProcessExits()
Expand Down
48 changes: 29 additions & 19 deletions source/SteamTools/ViewModels/Page/DebugPageViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,34 +49,44 @@ await Task.Run(() =>
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamUtils.GetAppId();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsAppInstalled(730);
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsSubscribedFromFamilySharing();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.GetAppInstallDir(730);
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.GetAppInstallDir(398980);
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsAppInstalled(398980);
DebugText += Environment.NewLine;
}).ContinueWith(s => { Logger.Error(s.Exception); WindowService.Current.ShowDialogWindow(s.Exception.Message); }, TaskContinuationOptions.OnlyOnFaulted).ContinueWith(s => s.Dispose());
}

public void Test_OnClick()
{
Task.Run(() =>
if (SteamConnectService.Current.IsConnectToSteam)
{
DebugText += SteamConnectService.Current.IsConnectToSteam;
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.GetSteamId64();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.CurrentSteamUser.SteamId3_Int;
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamUtils.GetAppId();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsAppInstalled(730);
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsSubscribedFromFamilySharing();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.GetAppInstallDir(730);
DebugText += Environment.NewLine;
}).ContinueWith(s => { Logger.Error(s.Exception); WindowService.Current.ShowDialogWindow(s.Exception.Message); }, TaskContinuationOptions.OnlyOnFaulted).ContinueWith(s => s.Dispose());
if (SteamConnectService.Current.ApiService.Initialize())
{
Task.Run(() =>
{
DebugText += SteamConnectService.Current.IsConnectToSteam;
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.GetSteamId64();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.CurrentSteamUser.SteamId3_Int;
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamUtils.GetAppId();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsSubscribedFromFamilySharing();
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.GetAppInstallDir(398980);
DebugText += Environment.NewLine;
DebugText += SteamConnectService.Current.ApiService.SteamClient.SteamApps008.IsAppInstalled(398980);
DebugText += Environment.NewLine;
}).ContinueWith(s => { Logger.Error(s.Exception); WindowService.Current.ShowDialogWindow(s.Exception.Message); }, TaskContinuationOptions.OnlyOnFaulted).ContinueWith(s =>
{
s.Dispose();
SteamConnectService.Current.DisposeSteamClient();
});
}
}
}
}
}
3 changes: 3 additions & 0 deletions source/SteamTools/ViewModels/Page/SteamAppPageViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,9 @@ private IObservable<Unit> UpdateAsync()
AppId = x.AppId,
Name = x.Name,
Type = x.Type,
Icon = x.Icon,
Logo = x.Logo,
InstalledDir = x.InstalledDir,
IsInstalled = x.IsInstalled,
}).ToList();
});
Expand Down
15 changes: 0 additions & 15 deletions source/SteamTools/Views/Content/About/AboutFAQ.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,16 +54,6 @@
<Run Text="A:脚本是要做用于对应的代理服务才的,所以对应的脚本需要启用了对应的代理服务,同时也必须启用了代理加速功能启用脚本才有效,例如steam商店史低查询脚本必须要启用steam商店代理服务才能生效。" />
<LineBreak/>
<LineBreak/>
<Run Text="Q:社区加速里的脚本启用了无效,为什么脚本前面的勾选框不会被保存?"></Run>
<LineBreak />
<Run Text="A:脚本是要做用于对应的代理服务才的,所以对应的脚本需要启用了对应的代理服务,同时也必须启用了代理加速功能启用脚本才有效,例如steam商店史低查询脚本必须要启用steam商店代理服务才能生效。" />
<LineBreak/>
<LineBreak/>
<Run Text="Q:库存游戏列表无法加载,一直是空的?"></Run>
<LineBreak />
<Run Text="A:因为库存游戏列表第一次加载是从steam webapi获取数据,数据量较大且网络本身较慢,所以加载速度比较有限,需要多等待一会。如果在这期间退出了Steam++程序,那么可能会造成在Steam++目录下存了一个错误的apps.json缓存文件,这会导致之后一直无法正确加载库存游戏列表数据,所以删除这个文件重新启动一下Steam++,在耐心等待一下,应该就能加载出来了。" />
<LineBreak/>
<LineBreak/>
<Run Text="Q:库存游戏列表无法加载,一直是空的?"></Run>
<LineBreak />
<Run Text="A:因为库存游戏列表第一次加载是从steam webapi获取数据,数据量较大且网络本身较慢,所以加载速度比较有限,需要多等待一会。如果在这期间退出了Steam++程序,那么可能会造成在Steam++目录下存了一个错误的apps.json缓存文件,这会导致之后一直无法正确加载库存游戏列表数据,所以删除这个文件重新启动一下Steam++,在耐心等待一下,应该就能加载出来了。" />
Expand All @@ -79,11 +69,6 @@
<Run Text="A:证书安装是否成功的检测方法为试试点击删除证书看看是否有反应,443端口被占用可以百度一下怎么查询占用端口的程序。注:Vmawre虚拟机也会导致提示443端口被占用服务无法启动。" />
<LineBreak/>
<LineBreak/>
<Run Text="Q:无法启动服务 提示证书安装失败或443端口占用?"></Run>
<LineBreak />
<Run Text="A:证书安装是否成功的检测方法为试试点击删除证书看看是否有反应,443端口被占用可以百度一下怎么查询占用端口的程序。注:Vmawre虚拟机也会导致提示443端口被占用服务无法启动。" />
<LineBreak/>
<LineBreak/>
<!--<Run Text="Q:软件启动时就报错,缺少根元素?"></Run>
<LineBreak />
<Run Text="A:配置文件加载出错了,检查下路径%HOMEPATH%\AppData\Local\rmbgame.net\Steam++以及%HOMEPATH%\AppData\Roaming\rmbgame.net\Steam++路径内的settings.json文件,如果没有重要数据可以删除此文件重置配置,或者手动还原备份settings.json.bak文件。同时可以考虑反馈settings.json.error文件给我排查问题。" />
Expand Down
Loading

0 comments on commit 866ad1a

Please sign in to comment.