终端一体化运控平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

35 lines
1.1 KiB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Linq;
  5. using System.Runtime.CompilerServices;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. using BPASmartClient.Message;
  9. using Microsoft.Toolkit.Mvvm.ComponentModel;
  10. namespace BPASmartClient.CustomResource.Pages.ViewModel
  11. {
  12. public class DebugLogViewModel : ObservableObject
  13. {
  14. public DebugLogViewModel()
  15. {
  16. MessageLog.GetInstance.DebugLog = new Action<string>((o) =>
  17. {
  18. Message = MessageLog.GetInstance.DebugLogInfo;
  19. });
  20. }
  21. public static string Message { get { return _mMessage; } set { _mMessage = value; OnStaticPropertyChanged(); } }
  22. private static string _mMessage = string.Empty;
  23. public static event EventHandler<PropertyChangedEventArgs> StaticPropertyChanged;
  24. private static void OnStaticPropertyChanged([CallerMemberName] string PropName = "")
  25. {
  26. StaticPropertyChanged?.Invoke(null, new PropertyChangedEventArgs(PropName));
  27. }
  28. }
  29. }