C# (CSharp) ReactiveUI ViewModelActivator - 6개의 예제가 발견되었습니다. 이것들은 오픈소스 프로젝트에서 추출된 C# (CSharp)의 ReactiveUI.ViewModelActivator에 대한 실세계 최고 등급의 예제들입니다. 예제들을 평가하여 예제의 품질 향상에 도움을 줄 수 있습니다.
관련
Related in langs
ViewModelActivator is a helper class that you instantiate in your ViewModel classes in order to help with Activation. Views will internally call this class when the corresponding View comes on screen. This means you can set up resources such as subscriptions to global objects that should be cleaned up on exit. Once you instantiate this class, use the WhenActivated method to register what to do when activated. View Activation is **not** the same as being loaded / unloaded; Views are Activated when they *enter* the Visual Tree, and are Deactivated when they *leave* the Visual Tree. This is a critical difference when it comes to views that are recycled, such as UITableViews or Virtualizing ScrollViews. Create this class solely in the **Base Class** of any classes that inherit from this class (i.e. if you create a FooViewModel that supports activation, the instance should be protected and a child BarViewModel should use the existing ViewModelActivator). NOTE: You **must** set up Activation in the corresponding View when using ViewModel Activation.