/** * CurrentPosition調整用Thumbがクリックされた */ private void OnThumbPressed(object sender, PointerRoutedEventArgs e) { ((UIElement)sender).CapturePointer(e.Pointer); beginTracking(e, 1, MWidth, AbsoluteCurrentPosition, TotalRange - TrimEnd - TrimStart); mTracking.Moved = (v, last) => { CurrentPosition = v; if (mTracking.Ext != AbsoluteCurrentPosition) { mTracking.Ext = AbsoluteCurrentPosition; CurrentPositionChanged?.Invoke(this, CurrentPosition, false); } }; CmLog.debug("WvvTrimmingSlider.OnThumbPressed"); e.Handled = true; }
public void ReportCurrentPositionChanged(TimeSpan newPosition, TimeSpan newBufferedPosition) { CurrentPositionChanged?.Invoke(this, new PositionChangedEventArgs(newPosition, newBufferedPosition)); }
private void ReportPositionChanged(TimeSpan newPosition, TimeSpan newBufferedPosition) { // TODO fix the interval listener and remove the null conditional operator CurrentPositionChanged?.Invoke(this, new PositionChangedEventArgs(newPosition, newBufferedPosition)); Element?.ReportCurrentPositionChanged(newPosition, newBufferedPosition); }
private void ReportPositionChanged(TimeSpan newPosition, TimeSpan newBufferedPosition) { CurrentPositionChanged?.Invoke(this, new PositionChangedEventArgs(newPosition, newBufferedPosition)); Element.ReportCurrentPositionChanged(newPosition, newBufferedPosition); }