C# Class HelixToolkit.Wpf.MouseGestureHandler

An abstract base class for the mouse gesture handlers.
Mostrar archivo Open project: litdev1/LitDev

Private Properties

Property Type Description
SetMouseDownPoint void

Public Methods

Method Description
Completed ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void

Occurs when the manipulation is completed.

Delta ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void

Occurs when the position is changed during a manipulation.

Execute ( object sender, System.Windows.Input.ExecutedRoutedEventArgs e ) : void

Executes the mousegesture command.

Started ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void

Occurs when the manipulation is started.

UnProject ( Point p ) : Point3D?

Un projects a point from the screen (2D) to a point on the plane trough the camera target point.

UnProject ( Point p, System.Windows.Media.Media3D.Point3D position, System.Windows.Media.Media3D.Vector3D normal ) : Point3D?

Un projects a point from the screen (2D) to a point on plane (3D)

Protected Methods

Method Description
CanExecute ( ) : bool

Occurs when the command associated with this handler initiates a check to determine whether the command can be executed on the command target.

GetCursor ( ) : System.Windows.Input.Cursor

Gets the cursor for the gesture.

GetRay ( Point position ) : Ray3D

Get the ray into the view volume given by the position in 2D (screen coordinates)

MouseGestureHandler ( CameraController controller ) : System

Initializes a new instance of the MouseGestureHandler class.

OnInertiaStarting ( int elapsedTime ) : void

Called when inertia is starting.

OnMouseDown ( object sender, System.Windows.Input.MouseEventArgs e ) : void

Called when the mouse button is pressed down.

OnMouseMove ( object sender, System.Windows.Input.MouseEventArgs e ) : void

The on mouse move.

OnMouseUp ( object sender, System.Windows.Input.MouseButtonEventArgs e ) : void

The on mouse up.

Project ( System.Windows.Media.Media3D.Point3D p ) : Point

Calculate the screen position of a 3D point.

Private Methods

Method Description
SetMouseDownPoint ( Point position ) : void

The set mouse down point.

Method Details

CanExecute() protected method

Occurs when the command associated with this handler initiates a check to determine whether the command can be executed on the command target.
protected CanExecute ( ) : bool
return bool

Completed() public method

Occurs when the manipulation is completed.
public Completed ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void
e HelixToolkit.Wpf.ManipulationEventArgs /// The instance containing the event data. ///
return void

Delta() public method

Occurs when the position is changed during a manipulation.
public Delta ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void
e HelixToolkit.Wpf.ManipulationEventArgs /// The instance containing the event data. ///
return void

Execute() public method

Executes the mousegesture command.
public Execute ( object sender, System.Windows.Input.ExecutedRoutedEventArgs e ) : void
sender object /// The sender. ///
e System.Windows.Input.ExecutedRoutedEventArgs /// The event arguments. ///
return void

GetCursor() protected abstract method

Gets the cursor for the gesture.
protected abstract GetCursor ( ) : System.Windows.Input.Cursor
return System.Windows.Input.Cursor

GetRay() protected method

Get the ray into the view volume given by the position in 2D (screen coordinates)
protected GetRay ( Point position ) : Ray3D
position System.Windows.Point /// A 2D point. ///
return Ray3D

MouseGestureHandler() protected method

Initializes a new instance of the MouseGestureHandler class.
protected MouseGestureHandler ( CameraController controller ) : System
controller CameraController /// The controller. ///
return System

OnInertiaStarting() protected method

Called when inertia is starting.
protected OnInertiaStarting ( int elapsedTime ) : void
elapsedTime int /// The elapsed time (milliseconds). ///
return void

OnMouseDown() protected method

Called when the mouse button is pressed down.
protected OnMouseDown ( object sender, System.Windows.Input.MouseEventArgs e ) : void
sender object /// The sender. ///
e System.Windows.Input.MouseEventArgs /// The instance containing the event data. ///
return void

OnMouseMove() protected method

The on mouse move.
protected OnMouseMove ( object sender, System.Windows.Input.MouseEventArgs e ) : void
sender object /// The sender. ///
e System.Windows.Input.MouseEventArgs /// The event arguments. ///
return void

OnMouseUp() protected method

The on mouse up.
protected OnMouseUp ( object sender, System.Windows.Input.MouseButtonEventArgs e ) : void
sender object /// The sender. ///
e System.Windows.Input.MouseButtonEventArgs /// The event arguments. ///
return void

Project() protected method

Calculate the screen position of a 3D point.
protected Project ( System.Windows.Media.Media3D.Point3D p ) : Point
p System.Windows.Media.Media3D.Point3D /// The 3D point. ///
return System.Windows.Point

Started() public method

Occurs when the manipulation is started.
public Started ( HelixToolkit.Wpf.ManipulationEventArgs e ) : void
e HelixToolkit.Wpf.ManipulationEventArgs /// The instance containing the event data. ///
return void

UnProject() public method

Un projects a point from the screen (2D) to a point on the plane trough the camera target point.
public UnProject ( Point p ) : Point3D?
p System.Windows.Point /// The 2D point. ///
return Point3D?

UnProject() public method

Un projects a point from the screen (2D) to a point on plane (3D)
public UnProject ( Point p, System.Windows.Media.Media3D.Point3D position, System.Windows.Media.Media3D.Vector3D normal ) : Point3D?
p System.Windows.Point /// The 2D point. ///
position System.Windows.Media.Media3D.Point3D /// A point on the plane . ///
normal System.Windows.Media.Media3D.Vector3D /// The plane normal. ///
return Point3D?