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.

78 lines
1.7 KiB

  1. using HandyControl.Controls;
  2. using HKCardIN.ViewModels;
  3. using Stylet;
  4. using StyletIoC;
  5. using System;
  6. using System.Configuration;
  7. using System.Windows.Controls;
  8. using System.Windows.Threading;
  9. using System.Windows;
  10. namespace HKCardIN
  11. {
  12. public class Bootstrapper : Bootstrapper<RootViewModel>
  13. {
  14. /// <summary>
  15. /// 程序启动
  16. /// </summary>
  17. protected override void OnStart()
  18. {
  19. }
  20. protected override void ConfigureIoC(IStyletIoCBuilder builder)
  21. {
  22. }
  23. /// <summary>
  24. /// 初始化系统相关参数配置
  25. /// </summary>
  26. protected override void Configure()
  27. {
  28. base.Configure();
  29. }
  30. /// <summary>
  31. /// 初始化VM
  32. /// </summary>
  33. protected override void Launch()
  34. {
  35. base.Launch();
  36. }
  37. /// <summary>
  38. /// 加载首页VM
  39. /// </summary>
  40. /// <param name="rootViewModel"></param>
  41. protected override void DisplayRootView(object rootViewModel)
  42. {
  43. base.DisplayRootView(rootViewModel);
  44. }
  45. /// <summary>
  46. ///VM加载完毕
  47. /// </summary>
  48. protected override void OnLaunch()
  49. {
  50. base.OnLaunch();
  51. }
  52. /// <summary>
  53. /// 退出
  54. /// </summary>
  55. /// <param name="e"></param>
  56. protected override void OnExit(ExitEventArgs e)
  57. {
  58. base.OnExit(e);
  59. }
  60. /// <summary>
  61. /// 全局异常捕获
  62. /// </summary>
  63. /// <param name="e"></param>
  64. protected override void OnUnhandledException(DispatcherUnhandledExceptionEventArgs e)
  65. {
  66. GC.Collect();
  67. }
  68. }
  69. }