private void SV_Content_PreviewMouseWheel(object sender, MouseWheelEventArgs e) { GlobalHelper.HandleScroll(sender, e); //if (!fcrollOver) //{ // int threshold = 48; // ScrollViewer scrollViewer = (ScrollViewer)sender; // double target = scrollViewer.VerticalOffset - Math.Min(Math.Max(e.Delta, -threshold), threshold); // scrollViewer.ScrollToVerticalOffset(target); //} }
private async void SV_Emotions_PreviewMouseWheel(object sender, MouseWheelEventArgs e) { GlobalHelper.HandleScroll(sender, e); if (SV_Emotions.VerticalOffset == SV_Emotions.ScrollableHeight && e.Delta < 0 && !isEmotionWorking) { isEmotionWorking = true; var likes = await KakaoRequestClass.GetLikes(data, lastLikeID); if (likes.Count > 0) { lastLikeID = likes.Last().id; AddLikes(likes); } isEmotionWorking = false; } }
private async void SV_Shares_PreviewMouseWheel(object sender, MouseWheelEventArgs e) { GlobalHelper.HandleScroll(sender, e); if (SV_Shares.VerticalOffset == SV_Shares.ScrollableHeight && e.Delta < 0 && lastShareID != null && !isShareWorking) { isShareWorking = true; var shares = await KakaoRequestClass.GetShares(false, data, lastShareID); if (shares.Count > 0) { AddShares(shares); lastShareID = shares.Last().id; } isShareWorking = false; } }
private async void SV_UP_PreviewMouseWheel(object sender, MouseWheelEventArgs e) { GlobalHelper.HandleScroll(sender, e); if (SV_UP.VerticalOffset == SV_UP.ScrollableHeight && e.Delta < 0 && !isUPWorking) { isUPWorking = true; var ups = await KakaoRequestClass.GetShares(true, data, lastUPID); if (ups.Count > 0) { lastUPID = ups.Last().id; AddUps(ups); } isUPWorking = false; } }
private void ScrollViewer_PreviewMouseWheel(object sender, MouseWheelEventArgs e) { GlobalHelper.HandleScroll(sender, e); }