mirror of
https://github.com/wwiinnddyy/LanMountainDesktop.git
synced 2026-06-20 23:54:26 +08:00
Introduce privacy/telemetry support: add PrivacyConfig and PrivacyAgreementState models, and a PrivacyAgreementService that saves/validates agreement state with HMAC integrity protection (privacy-agreement.state.json). Update AppJsonContext to include new types. Extend OOBE UI (OobeWindow.axaml/.cs) with a Data Location redesign and a new Privacy step (telemetry toggles, telemetry ID, agreement checkbox) and wire up handlers to save privacy-config.json and agreement state. Add a PrivacyPolicyWindow using Markdown.Avalonia to display the privacy policy; add CommunityToolkit.Mvvm and Markdown.Avalonia package references.
23 lines
525 B
C#
23 lines
525 B
C#
namespace LanMountainDesktop.Launcher.Models;
|
|
|
|
/// <summary>
|
|
/// 隐私配置模型
|
|
/// </summary>
|
|
public class PrivacyConfig
|
|
{
|
|
/// <summary>
|
|
/// 是否启用崩溃报告遥测
|
|
/// </summary>
|
|
public bool CrashTelemetryEnabled { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// 是否启用使用统计遥测
|
|
/// </summary>
|
|
public bool UsageTelemetryEnabled { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// 隐私追踪 ID
|
|
/// </summary>
|
|
public string TelemetryId { get; set; } = string.Empty;
|
|
}
|