IDirectManipulationDragDropBehavior::SetConfiguration method (directmanipulation.h)
Sets the configuration of the drag-drop interaction for the viewport this behavior is attached to.
Syntax
HRESULT SetConfiguration(
[in] DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION configuration
);
Parameters
[in] configuration
Combination of values from DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION.
For the configuration to be valid, configuration must contain exactly one of the following three values:
- DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_SELECT_ONLY
- DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_SELECT_DRAG
- DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_HOLD_DRAG
If DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_SELECT_ONLY or DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_SELECT_DRAG is specified, one of DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_VERTICAL or DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_HORIZONTAL is required.
If DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_HOLD_DRAG is specified, both DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_VERTICAL and DIRECTMANIPULATION_DRAG_DROP_CONFIGURATION_HORIZONTAL are required.
Return value
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
The configuration of the behavior can be set before or after it has been added to a viewport. If a configuration change is made while an interaction is occurring, the new configuration takes effect on the next interaction.
IDirectManipulationViewport::ActivateConfiguration should not be called prior to calling IDirectManipulationDragDropBehavior::SetConfiguration. This will result in unexpected behavior.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 8.1 [desktop apps only] |
Minimum supported server | Windows Server 2012 R2 [desktop apps only] |
Target Platform | Windows |
Header | directmanipulation.h |