Пример #1
0
 // If the DoubleClick on the ThumbnailGrid selected an image or video, display it.
 private void ThumbnailGrid_DoubleClick(object sender, ThumbnailGridEventArgs e)
 {
     if (e.ImageRow != null)
     {
         // Switch to either the video or image view as needed
         if (this.DataHandler.ImageCache.Current.IsVideo && this.DataHandler.ImageCache.Current.IsDisplayable(this.FolderPath))
         {
             this.MarkableCanvas.SwitchToVideoView();
         }
         else
         {
             this.MarkableCanvas.SwitchToImageView();
         }
         this.FileNavigatorSlider_EnableOrDisableValueChangedCallback(false);
         this.FileShow(this.DataHandler.FileDatabase.GetFileOrNextFileIndex(e.ImageRow.ID));
         this.FileNavigatorSlider_EnableOrDisableValueChangedCallback(true);
     }
 }
Пример #2
0
 // This event handler is invoked whenever the user does a selection in the overview.
 // It is used to refresh (and match) what rows are selected in the DataGrid.
 // However, because user selections can change rapidly (e.g., by dragging within the overview), we throttle the refresh using a timer
 private void ThumbanilGrid_SelectionChanged(object sender, ThumbnailGridEventArgs e)
 {
     this.DataGridSelectionsTimer_Reset();
 }