_IManipulationEvents::ManipulationStarted method

Handles the event for when manipulation or inertia begins.

Syntax

HRESULT ManipulationStarted(
  FLOAT x,
  FLOAT y
);

Parameters

x

The origin x-coordinate in user-defined coordinates.

y

The origin y-coordinate in user-defined coordinates.

Return Value

If the method succeeds, it returns S_OK. If it fails, it returns an HRESULT error code.

Remarks

Manipulation events are generated for both the IInertiaProcessor and IManipulationProcessor interfaces. If you are using the values from the TOUCHINPUT structure in calls to ProcessDown, the coordinates will be in hundredths of a pixel.

Examples

The following code shows an implementation of the ManipulationStarted method.


HRESULT STDMETHODCALLTYPE CManipulationEventSink::ManipulationStarted( 
    /* [in] */ FLOAT x,
    /* [in] */ FLOAT y)
{
    m_cStartedEventCount ++;

    // place your code handler here to do any operations based on the manipulation

    return S_OK;
}
    
    

Requirements

   
Minimum supported client Windows 7 [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Target Platform Windows
Header manipulations.h (include Manipulations.h)

See Also

Adding Manipulation Support to Unmanaged Code

Handling Inertia in Unmanaged Code

Methods

_IManipulationEvents