Beispiel #1
0
 private void Sc_ViewChanged(object sender, ScrollViewerViewChangedEventArgs e)
 {
     if (IsPausedWhileScrolling)
     {
         if (e.IsIntermediate)
         {
             GifImageSource.PauseAllGifs();
         }
         else
         {
             //scroll is stopping
             GifImageSource.ResumeAllGifs();
         }
     }
 }
Beispiel #2
0
        public ListViewTest()
        {
            this.DataContext = this;

            this.InitializeComponent();
#if WINDOWS_APP
            this.navBackButton.Style      = (Style)Resources["NavigationBackButtonNormalStyle"];
            this.navBackButton.Visibility = Windows.UI.Xaml.Visibility.Visible;
            _scrollResumeTimer.Interval   = TimeSpan.FromMilliseconds(500);
            _scrollResumeTimer.Tick      += (s, args) =>
            {
                _scrollResumeTimer.Stop();
                GifImageSource.ResumeAllGifs();
            };
#elif WINDOWS_PHONE_APP
            HardwareButtons.BackPressed += HardwareButtons_BackPressed;
#endif
        }
Beispiel #3
0
        private void Sc_ViewChanged(object sender, ScrollViewerViewChangedEventArgs e)
        {
            if (IsPausedWhileScrolling)
            {
#if WINDOWS_APP
                _scrollResumeTimer.Stop();
                _scrollResumeTimer.Start();
                GifImageSource.PauseAllGifs();
#else
                if (e.IsIntermediate)
                {
                    GifImageSource.PauseAllGifs();
                }
                else
                {
                    //scroll is stopping
                    GifImageSource.ResumeAllGifs();
                }
#endif
            }
        }