VisualStateManager.RaiseCurrentStateChanged Metodo
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Genera l'evento CurrentStateChanging sull'oggetto specificato VisualStateGroup .
protected:
void RaiseCurrentStateChanged(System::Windows::VisualStateGroup ^ stateGroup, System::Windows::VisualState ^ oldState, System::Windows::VisualState ^ newState, System::Windows::FrameworkElement ^ control, System::Windows::FrameworkElement ^ stateGroupsRoot);
protected void RaiseCurrentStateChanged(System.Windows.VisualStateGroup stateGroup, System.Windows.VisualState oldState, System.Windows.VisualState newState, System.Windows.FrameworkElement control, System.Windows.FrameworkElement stateGroupsRoot);
member this.RaiseCurrentStateChanged : System.Windows.VisualStateGroup * System.Windows.VisualState * System.Windows.VisualState * System.Windows.FrameworkElement * System.Windows.FrameworkElement -> unit
Protected Sub RaiseCurrentStateChanged (stateGroup As VisualStateGroup, oldState As VisualState, newState As VisualState, control As FrameworkElement, stateGroupsRoot As FrameworkElement)
Parametri
- stateGroup
- VisualStateGroup
Oggetto su cui si è verificato l'evento CurrentStateChanging .
- oldState
- VisualState
Stato da cui viene eseguita la transizione del controllo.
- newState
- VisualState
Stato in cui viene eseguita la transizione del controllo.
- control
- FrameworkElement
Controllo che esegue la transizione degli stati.
- stateGroupsRoot
- FrameworkElement
Elemento radice che contiene l'oggetto VisualStateManager.
Eccezioni
Commenti
Quando l'oggetto VisualStateGroupControlTemplate è impostato su di un controllo , il control parametro viene impostato sul controllo proprietario ControlTemplatedi . Quando l'oggetto VisualStateGroup è impostato su , FrameworkElementcontrol è null ed è necessario usare il stateGroupsRoot parametro .
Note per gli eredi
Quando si esegue l'override RaiseCurrentStateChanged(VisualStateGroup, VisualState, VisualState, FrameworkElement, FrameworkElement) in una classe derivata, assicurarsi di chiamare il metodo della RaiseCurrentStateChanged(VisualStateGroup, VisualState, VisualState, FrameworkElement, FrameworkElement) classe base in modo che i delegati registrati ricevano l'evento.