C# Class Microsoft.Practices.Prism.ViewModel.DataTemplateSelector

This custom ContentControl changes its ContentTemplate based on the content it is presenting.
In order to determine the template it must use for the new content, this control retrieves it from its resources using the name for the type of the new content as the key.
Inheritance: System.Windows.Controls.ContentControl
Afficher le fichier Open project: jeffras/Prism-4-with-WinForms Class Usage Examples

Méthodes protégées

Méthode Description
OnContentChanged ( object oldContent, object newContent ) : void

Called when the value of the P:System.Windows.Controls.ContentControl.Content property changes.

Will attempt to discover the DataTemplate from the ResourceDictionary by matching the type name of newContent.

Private Methods

Méthode Description
GetDefaultContentTemplate ( ) : System.Windows.DataTemplate

Method Details

OnContentChanged() protected méthode

Called when the value of the P:System.Windows.Controls.ContentControl.Content property changes.
Will attempt to discover the DataTemplate from the ResourceDictionary by matching the type name of newContent.
protected OnContentChanged ( object oldContent, object newContent ) : void
oldContent object The old value of the property.
newContent object The new value of the property.
Résultat void