C# Class Microsoft.Practices.Prism.Regions.Behaviors.ClearChildViewsRegionBehavior

Behavior that removes the RegionManager attached property of all the views in a region once the RegionManager property of a region becomes null. This is useful when removing views with nested regions, to ensure these nested regions get removed from the RegionManager as well. This behavior does not apply by default. In order to activate it, the ClearChildViews attached property must be set to True in the view containing the affected child regions.
Inheritance: Microsoft.Practices.Prism.Regions.RegionBehavior
Afficher le fichier Open project: xperiandri/PortablePrism Class Usage Examples

Méthodes publiques

Свойство Type Description
ClearChildViewsProperty DependencyProperty

Méthodes publiques

Méthode Description
GetClearChildViews ( DependencyObject target ) : bool

Gets the ClearChildViews attached property from a DependencyObject.

SetClearChildViews ( DependencyObject target, bool value ) : void

Sets the ClearChildViews attached property in a DependencyObject.

Méthodes protégées

Méthode Description
OnAttach ( ) : void

Subscribes to the Region's PropertyChanged method to monitor its RegionManager property.

Private Methods

Méthode Description
ClearChildViews ( IRegion region ) : void
Region_PropertyChanged ( object sender, System e ) : void

Method Details

GetClearChildViews() public static méthode

Gets the ClearChildViews attached property from a DependencyObject.
public static GetClearChildViews ( DependencyObject target ) : bool
target DependencyObject The object from which to get the value.
Résultat bool

OnAttach() protected méthode

Subscribes to the Region's PropertyChanged method to monitor its RegionManager property.
protected OnAttach ( ) : void
Résultat void

SetClearChildViews() public static méthode

Sets the ClearChildViews attached property in a DependencyObject.
public static SetClearChildViews ( DependencyObject target, bool value ) : void
target DependencyObject The object in which to set the value.
value bool The value of to set in the target object's ClearChildViews attached property.
Résultat void

Property Details

ClearChildViewsProperty public_oe static_oe property

This attached property can be defined on a view to indicate that regions defined in it must be removed from the region manager when the parent view gets removed from a region.
public static DependencyProperty ClearChildViewsProperty
Résultat DependencyProperty