IPointerInactive  2_JLPB5

The IPointerInactive interface enables an object to remain inactive most of the time, yet still participate in interaction with the mouse, including drag and drop.

Objects can be active (in-place or UI active) or they can be inactive (loaded or running). An active object creates a window and can receive Windows mouse and keyboard messages. An inactive object can render itself and provide a representation of its data in a given format. While they provide more functionality, active objects also consume more resources than inactive objects. Typically, they are larger and slower than inactive objects. Thus, keeping an object inactive can provide performance improvements.

However, an object, such as a control, needs to be able to control the mouse pointer, fire mouse events, and act as a drop target so it can participate in the user interface of its container application.

When to Implement

Implement this interface on an object, such as a control, so the object can support a minimal level of interaction with the mouse and keyboard while it is in the inactive state. The object can control the mouse pointer, fire mouse events, and act as a drop target without being in the active state at all times. The object does not have to set the OLEMISC_ACTIVATEWHENVISIBLE enumeration value, does not have to have a window, and thus, can increase its performance.

If the object must work with down-level containers, it may have to set the OLEMISC_ACTIVATEWHENVISIBLE enumeration value. However, an updated container that supports objects that implement IPointerInactive can use the OLEMISC_IGNOREACTIVATEWHENVISIBLE enumeration value to override OLEMISC_ACTIVATEWHENVISIBLE.

When to Use

A container calls the methods in this interface for its embedded objects so that the embedded objects can participate in the user interface for the application.

Methods in Vtable Order

IUnknown1NEM0LU Methods

Description

QueryInterface2Y54585

Returns a pointer to a specified interface.

AddRef1SHW0SS

Increments the reference count.

ReleaseDUW01A

Decrements the reference count.

 

IPointerInactive Methods

Description

GetActivationPolicyXA3J.1

Returns the present activation policy for the object.

OnInactiveMouseMove1N_7XRD

Notifies the object that the mouse pointer has moved over it so the object can fire mouse events.

OnInactiveSetCursorHW7KSQ

Sets the mouse pointer for an inactive object.

 

See Also

OLEMISC