コード例 #1
0
 void TriggerForward()
 {
     if (Forward != null)
     {
         Forward.Invoke(this, new EventArgs());
     }
 }
コード例 #2
0
 private void Button_KeyDown_Forward(object sender, KeyEventArgs e)
 {
     if (e.Key == Key.Right)
     {
         Forward?.Invoke(this, new RoutedEventArgs());
     }
 }
コード例 #3
0
 private void ForwardButton_Click(object sender, RoutedEventArgs e) => Forward?.Invoke(this, new RoutedEventArgs());
コード例 #4
0
 private void BackwardButtonClick(object sender, RoutedEventArgs e)
 {
     Forward?.Invoke(this, EventArgs.Empty);
 }
コード例 #5
0
 private void OnForwardButton_Click(object sender, RoutedEventArgs e) => Forward?.Invoke(this, EventArgs.Empty);
コード例 #6
0
 /// <summary>
 /// 来源转为目标。
 /// </summary>
 /// <param name="source">给定的 <typeparamref name="TSource"/>。</param>
 /// <returns>返回 <typeparamref name="TTarget"/>。</returns>
 public virtual TTarget ConvertTo(TSource source)
 => Forward.Invoke(source);
コード例 #7
0
 /// <summary>
 /// 将来源序列化为目标。
 /// </summary>
 /// <param name="source">给定的 <typeparamref name="TSource"/>。</param>
 /// <returns>返回 <typeparamref name="TTarget"/>。</returns>
 public virtual TTarget Serialize(TSource source)
 => Forward.Invoke(source);