/// <summary>
 /// The event handler that is listening to the preview invoke event that is fired by
 /// the trigger. Setting PreviewInvokeEventArgs.Cancelling to True will
 /// cancel the invocation.
 /// </summary>
 /// <param name="sender">The trigger base object.</param>
 /// <param name="e">An object of type PreviewInvokeEventArgs where e.Cancelling can be set to True.</param>
 private void OnPreviewInvoke(object sender, PreviewInvokeEventArgs e)
 {
     if (this.Condition != null)
     {
         e.Cancelling = !this.Condition.Evaluate();
     }
 }
Esempio n. 2
0
 void OnPreviewInvoke(object sender, PreviewInvokeEventArgs e)
 {
     DataBindingHelper.EnsureDataBindingOnActionsUpToDate(this);
 }