C# 클래스 BaconographyWP8.View.ScalingPictureView

상속: System.Windows.Controls.UserControl
파일 보기 프로젝트 열기: Synergex/Baconography

공개 프로퍼티들

프로퍼티 타입 설명
ImageSourceProperty System.Windows.DependencyProperty

공개 메소드들

메소드 설명
ScalingPictureView ( ) : System

This is a very simple page. We simply bind to the CurrentPicture property on the AlbumsViewModel

비공개 메소드들

메소드 설명
CoerceScale ( bool recompute ) : void

Coerce the scale into being within the proper range. Optionally compute the constraints on the scale so that it will always fill the entire screen and will never get too big to be contained in a hardware surface.

CoerceScaleImpl ( double viewWidth, double viewHeight, double bitmapWidth, double bitmapHeight, double scale ) : double>.Tuple
OnDoubleTap ( object sender, System e ) : void
OnImageOpened ( object sender, RoutedEventArgs e ) : void

When a new image is opened, set its initial scale.

OnImageSourceChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void
OnManipulationCompleted ( object sender, System.Windows.Input.ManipulationCompletedEventArgs e ) : void

The manipulation has completed (no touch points anymore) so reset state.

OnManipulationDelta ( object sender, System.Windows.Input.ManipulationDeltaEventArgs e ) : void

Handler for the ManipulationDelta event. It may or may not be a pinch. If it is not a pinch, the ViewportControl will take care of it.

OnManipulationStarted ( object sender, System.Windows.Input.ManipulationStartedEventArgs e ) : void

Handler for the ManipulationStarted event. Set initial state in case it becomes a pinch later.

ResizeImage ( bool center ) : void

Adjust the size of the image according to the coerced scale factor. Optionally center the image, otherwise, try to keep the original midpoint of the pinch in the same spot on the screen regardless of the scale.

ScalingPictureView_Loaded ( object sender, RoutedEventArgs e ) : void
_bitmap_ImageFailed ( object sender, System.Windows.ExceptionRoutedEventArgs e ) : void
viewport_ViewportChanged ( object sender, System e ) : void

Either the user has manipulated the image or the size of the viewport has changed. We only care about the size.

메소드 상세

ScalingPictureView() 공개 메소드

This is a very simple page. We simply bind to the CurrentPicture property on the AlbumsViewModel
public ScalingPictureView ( ) : System
리턴 System

프로퍼티 상세

ImageSourceProperty 공개적으로 정적으로 프로퍼티

public static DependencyProperty,System.Windows ImageSourceProperty
리턴 System.Windows.DependencyProperty