C# Class Catel.Android.App.Activity

View implementation that automatically takes care of view models.
Inheritance: global::Android.App.Activity, IPage
Show file Open project: Catel/Catel

Public Methods

Method Description
Activity ( ) : System

Initializes a new instance of the Activity class.

Protected Methods

Method Description
AddBindings ( BindingContext bindingContext, IViewModel viewModel ) : void

Called when the bindings must be added. This can happen Normally the binding system would take care of this.

OnPause ( ) : void

Called as part of the activity lifecycle when an activity is going into the background, but has not (yet) been killed.

OnPropertyChanged ( PropertyChangedEventArgs e ) : void

Called when a dependency property on this control has changed.

OnResume ( ) : void

Called when the view is loaded.

OnViewModelChanged ( ) : void

Called when the ViewModel has changed.

This method does not implement any logic and saves a developer from subscribing/unsubscribing to the ViewModelChanged event inside the same user control.

OnViewModelPropertyChanged ( PropertyChangedEventArgs e ) : void

Called when a property on the current ViewModel has changed.

Private Methods

Method Description
InitializeBindingContext ( ) : void
OnBindingUpdateRequired ( object sender, EventArgs e ) : void
RaiseViewModelChanged ( ) : void
UninitializeBindingContext ( ) : void

Method Details

Activity() public method

Initializes a new instance of the Activity class.
public Activity ( ) : System
return System

AddBindings() protected method

Called when the bindings must be added. This can happen Normally the binding system would take care of this.
protected AddBindings ( BindingContext bindingContext, IViewModel viewModel ) : void
bindingContext BindingContext The binding context.
viewModel IViewModel The view model.
return void

OnPause() protected method

Called as part of the activity lifecycle when an activity is going into the background, but has not (yet) been killed.
protected OnPause ( ) : void
return void

OnPropertyChanged() protected method

Called when a dependency property on this control has changed.
protected OnPropertyChanged ( PropertyChangedEventArgs e ) : void
e System.ComponentModel.PropertyChangedEventArgs The instance containing the event data.
return void

OnResume() protected method

Called when the view is loaded.
protected OnResume ( ) : void
return void

OnViewModelChanged() protected method

Called when the ViewModel has changed.
This method does not implement any logic and saves a developer from subscribing/unsubscribing to the ViewModelChanged event inside the same user control.
protected OnViewModelChanged ( ) : void
return void

OnViewModelPropertyChanged() protected method

Called when a property on the current ViewModel has changed.
protected OnViewModelPropertyChanged ( PropertyChangedEventArgs e ) : void
e System.ComponentModel.PropertyChangedEventArgs The instance containing the event data.
return void