MainWindowViewModel.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. using Avalonia;
  2. using Avalonia.Controls;
  3. using Avalonia.Controls.Shapes;
  4. using Avalonia.Media;
  5. using Avalonia.Threading;
  6. using Culusas.Models;
  7. using Culusas.Views;
  8. using ReactiveUI;
  9. using System;
  10. using System.Drawing.Drawing2D;
  11. using System.Drawing.Printing;
  12. using static System.Net.Mime.MediaTypeNames;
  13. namespace Culusas.ViewModels
  14. {
  15. public class MainWindowViewModel : ViewModelBase
  16. {
  17. UserControl user = new Autorizahon();
  18. public UserControl US
  19. {
  20. get => user;
  21. set => this.RaiseAndSetIfChanged(ref user, value);
  22. }
  23. AutorizahonPagesViewModel autorixVM = new AutorizahonPagesViewModel();
  24. public AutorizahonPagesViewModel AutorixVM { get => autorixVM; set => autorixVM = value; }
  25. public void Autorixis()
  26. {
  27. US = new Autorizahon();
  28. }
  29. public CululViewModel cululVM = new CululViewModel();
  30. public CululViewModel CululVM { get => cululVM; set => cululVM = value; }
  31. public void NextCui()
  32. {
  33. if (AutorixVM.NextCulucu())
  34. {
  35. US = new Culuculator();
  36. }
  37. }
  38. }
  39. }