Compare commits

..

1 commit

Author SHA1 Message Date
DHR60
0ef20667e7 Add global fakeip and fakeip filter 2025-09-10 12:44:12 +08:00
5 changed files with 23 additions and 12 deletions

View file

@ -1,13 +1,10 @@
using ReactiveUI;
using ReactiveUI.Fody.Helpers;
namespace ServiceLib.Models;
public class CheckUpdateModel : ReactiveObject
public class CheckUpdateModel
{
public bool? IsSelected { get; set; }
public string? CoreType { get; set; }
[Reactive] public string? Remarks { get; set; }
public string? Remarks { get; set; }
public string? FileName { get; set; }
public bool? IsFinished { get; set; }
}

View file

@ -1,10 +1,7 @@
using ReactiveUI;
using ReactiveUI.Fody.Helpers;
namespace ServiceLib.Models;
[Serializable]
public class ClashProxyModel : ReactiveObject
public class ClashProxyModel
{
public string? Name { get; set; }
@ -12,9 +9,9 @@ public class ClashProxyModel : ReactiveObject
public string? Now { get; set; }
[Reactive] public int Delay { get; set; }
public int Delay { get; set; }
[Reactive] public string? DelayName { get; set; }
public string? DelayName { get; set; }
public bool IsActive { get; set; }
}

View file

@ -334,6 +334,9 @@ public class CheckUpdateViewModel : MyReactiveObject
{
return;
}
found.Remarks = model.Remarks;
var itemCopy = JsonUtils.DeepCopy(found);
itemCopy.Remarks = model.Remarks;
CheckUpdateModels.Replace(found, itemCopy);
}
}

View file

@ -391,6 +391,7 @@ public class ClashProxiesViewModel : MyReactiveObject
public async Task ProxiesDelayTestResult(SpeedTestResult result)
{
//UpdateHandler(false, $"{item.name}={result}");
var detail = ProxyDetails.FirstOrDefault(it => it.Name == result.IndexId);
if (detail == null)
{
@ -413,6 +414,7 @@ public class ClashProxiesViewModel : MyReactiveObject
detail.Delay = _delayTimeout;
detail.DelayName = string.Empty;
}
ProxyDetails.Replace(detail, JsonUtils.DeepCopy(detail));
}
#endregion proxy function

View file

@ -293,6 +293,7 @@ public class ProfilesViewModel : MyReactiveObject
{
item.SpeedVal = result.Speed ?? string.Empty;
}
//_profileItems.Replace(item, JsonUtils.DeepCopy(item));
}
public async Task UpdateStatistics(ServerSpeedItem update)
@ -313,6 +314,17 @@ public class ProfilesViewModel : MyReactiveObject
item.TodayUp = Utils.HumanFy(update.TodayUp);
item.TotalDown = Utils.HumanFy(update.TotalDown);
item.TotalUp = Utils.HumanFy(update.TotalUp);
//if (SelectedProfile?.IndexId == item.IndexId)
//{
// var temp = JsonUtils.DeepCopy(item);
// _profileItems.Replace(item, temp);
// SelectedProfile = temp;
//}
//else
//{
// _profileItems.Replace(item, JsonUtils.DeepCopy(item));
//}
}
}
catch