Export (0) Print
Expand All

Mouse Class

Provides static methods for performing mouse actions in a user interface (UI) test.

Object
  Microsoft.VisualStudio.TestTools.UITesting.Mouse

Namespace:  Microsoft.VisualStudio.TestTools.UITesting
Assembly:  Microsoft.VisualStudio.TestTools.UITesting (in Microsoft.VisualStudio.TestTools.UITesting.dll)

'Declaration
<CLSCompliantAttribute(True)> _
Public Class Mouse _
	Implements IDisposable

The Mouse type exposes the following members.

  NameDescription
Protected methodMouseInfrastructure. Initializes a new instance of the Mouse class.
Top

  NameDescription
Public propertyStatic memberHoverDurationGets or sets the mouse hover duration in milliseconds.
Public propertyStatic memberInstanceGets or sets the Mouse instance.
Public propertyStatic memberLocationGets or sets the location of the Mouse.
Protected propertyLocationImplementationGets or sets the current location of the Mouse.
Public propertyStatic memberMouseDragSpeedGets or sets the mouse move speed.
Public propertyStatic memberMouseMoveSpeedGets or sets the mouse move speed.
Top

  NameDescription
Public methodStatic memberClickClicks the default mouse button.
Public methodStatic memberClick(Point)Clicks the default mouse button at the specified location.
Public methodStatic memberClick(MouseButtons)Clicks the specified mouse button.
Public methodStatic memberClick(ModifierKeys)Clicks the default mouse button while holding the specified modifier keys.
Public methodStatic memberClick(UITestControl)Clicks the default mouse button on the specified control.
Public methodStatic memberClick(UITestControl, Point)Clicks the default mouse button on the specified control at the specified location relative to that control.
Public methodStatic memberClick(UITestControl, MouseButtons)Clicks the specified mouse button on the specified control.
Public methodStatic memberClick(UITestControl, ModifierKeys)Clicks the default mouse button on the specified control while holding the specified modifier keys.
Public methodStatic memberClick(MouseButtons, ModifierKeys, Point)Clicks the specified mouse button while holding the specified modifier keys at the specified location.
Public methodStatic memberClick(UITestControl, MouseButtons, ModifierKeys, Point)Clicks the specified mouse button on the specified control while holding the specified modifier keys at the specified location relative to that control.
Protected methodClickImplementationClicks the specified mouse button on the specified control while holding the specified modifier keys at the specified location that is relative to that control.
Public methodDisposeReleases all resources that are used by the current instance of the Mouse class.
Protected methodDispose(Boolean)Cleans up any resources that are used.
Public methodStatic memberDoubleClickDouble-clicks the mouse button.
Public methodStatic memberDoubleClick(Point)Double-clicks the default mouse button at the specified location.
Public methodStatic memberDoubleClick(MouseButtons)Double-clicks the specified mouse button.
Public methodStatic memberDoubleClick(ModifierKeys)Double-clicks the default mouse button that has modifiers.
Public methodStatic memberDoubleClick(UITestControl)Double-clicks the default mouse button on the specified control.
Public methodStatic memberDoubleClick(UITestControl, Point)Double-clicks the default mouse button on the specified control at the specified location that is relative to the control.
Public methodStatic memberDoubleClick(UITestControl, MouseButtons)Double-clicks the specified mouse button on the specified control.
Public methodStatic memberDoubleClick(UITestControl, ModifierKeys)Double-clicks the default mouse button on the control with modifiers.
Public methodStatic memberDoubleClick(MouseButtons, ModifierKeys, Point)Double-clicks the specified mouse button while holding the specified modifier keys at the specified screen location.
Public methodStatic memberDoubleClick(UITestControl, MouseButtons, ModifierKeys, Point)Double-clicks the specified mouse button on the specified control while holding the specified modifier keys at the specified location that is relative to that control.
Protected methodDoubleClickImplementationDouble-clicks the specified mouse button on the specified control while holding the specified modifier keys at the specified location that is relative to that control.
Public methodEqualsDetermines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodFinalizeThe finalizer method. (Overrides Object.Finalize.)
Public methodGetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodStatic memberHover(Point)Moves the mouse to the specified location.
Public methodStatic memberHover(UITestControl)Pauses the mouse on the specified control.
Public methodStatic memberHover(Point, Int32)Pause the mouse at the specified point for a specified duration.
Public methodStatic memberHover(UITestControl, Point)Moves the mouse to the specified location that is relative to the specified control.
Public methodStatic memberHover(UITestControl, Point, Int32)Pauses the mouse at the specified location that is relative to the specified control for a specified duration.
Protected methodHoverImplementationPauses the mouse at the specified location that is relative to the specified control for a specified duration.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodStatic memberMove(Point)Moves the mouse to the specified location.
Public methodStatic memberMove(UITestControl, Point)Moves the mouse to the specified location that is relative to the specified control.
Protected methodMoveImplementationMoves the mouse to the specified location that is relative to the specified control.
Public methodStatic memberMoveScrollWheel(Int32)Scrolls the mouse wheel the specified number of times.
Public methodStatic memberMoveScrollWheel(Int32, ModifierKeys)Scrolls the mouse wheel the specified number of times while pressing the specified modifier keys.
Public methodStatic memberMoveScrollWheel(UITestControl, Int32)Scrolls the mouse wheel on the specified control the specified number of times.
Public methodStatic memberMoveScrollWheel(UITestControl, Int32, ModifierKeys)Scrolls the mouse wheel on the specified control the specified number of times while pressing the specified modifier keys.
Protected methodMoveScrollWheelImplementationScrolls the mouse wheel on the specified control the specified number of times while pressing the specified modifier keys.
Public methodStatic memberStartDraggingStarts dragging the mouse.
Public methodStatic memberStartDragging(UITestControl)Starts dragging the mouse from the specified control.
Public methodStatic memberStartDragging(UITestControl, Point)Starts dragging the mouse from the specified point that is relative to the specified control or from an absolute control, if control is Nothing.
Public methodStatic memberStartDragging(UITestControl, MouseButtons)Starts dragging the mouse while holding down the specified mouse buttons from the specified control.
Public methodStatic memberStartDragging(UITestControl, Point, MouseButtons, ModifierKeys)Starts dragging the mouse while holding down the specified mouse buttons and the specified keys from the specified point that is relative to the specified control or from an absolute control, if control is Nothing.
Protected methodStartDraggingImplementationStarts dragging the mouse while holding down the specified mouse buttons and the specified keys from the specified point relative to the specified control or from an absolute control, if control is Nothing.
Public methodStatic memberStopDragging(Point)Stops the drag operation.
Public methodStatic memberStopDragging(UITestControl)Stops the drag operation on the specified control.
Public methodStatic memberStopDragging(Int32, Int32)Stops the drag operation.
Public methodStatic memberStopDragging(UITestControl, Point)Stops the drag operation on the specified control.
Public methodStatic memberStopDragging(UITestControl, Int32, Int32)Stops the drag operation on the specified control.
Protected methodStopDraggingImplementationStops the drag operation on the specified control.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show:
© 2014 Microsoft