Skip to content

Commit

Permalink
Removed FloatingContentOnPointer event handling
Browse files Browse the repository at this point in the history
  • Loading branch information
taivasverkko committed May 9, 2024
1 parent c1244e5 commit b6b0c3e
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions src/LibVLCSharp.Avalonia/VideoView.cs
Original file line number Diff line number Diff line change
Expand Up @@ -209,9 +209,6 @@ private void InitializeNativeOverlay()
Opacity = 1.0,
DataContext = DataContext
};

_floatingContent.PointerEntered += FloatingContentOnPointerEntered;
_floatingContent.PointerExited += FloatingContentOnPointerExited;
_floatingContent.Bind(ContentControl.ContentProperty, this.GetObservable(ContentProperty));

ContentProperty.Changed.AddClassHandler<VideoView>((o, _) => o.UpdateOverlayPosition());
Expand All @@ -222,22 +219,6 @@ private void InitializeNativeOverlay()
ShowNativeOverlay(IsEffectivelyVisible);
}

private void FloatingContentOnPointerExited(object sender, PointerEventArgs e)
{
if (_floatingContent != null)
{
_floatingContent.Opacity = 0;
}
}

private void FloatingContentOnPointerEntered(object sender, PointerEventArgs e)
{
if (_floatingContent != null)
{
_floatingContent.Opacity = 1.0;
}
}

private void ShowNativeOverlay(bool show)
{
if (_floatingContent == null || _floatingContent.IsVisible == show || VisualRoot is not Window visualRoot)
Expand Down

0 comments on commit b6b0c3e

Please sign in to comment.