IOleInPlaceObjectWindowlessImpl Class

 

For the latest documentation on Visual Studio 2017, see Visual Studio 2017 Documentation.

For the latest documentation on Visual Studio 2017, see IOleInPlaceObjectWindowlessImpl Class on docs.microsoft.com. This class implements IUnknown and provides methods that enable a windowless control to receive window messages and to participate in drag-and-drop operations.

System_CAPS_ICON_important.jpg Important

This class and its members cannot be used in applications that execute in the Windows Runtime.

template<class T>
class IOleInPlaceObjectWindowlessImpl

Parameters

T
Your class, derived from IOleInPlaceObjectWindowlessImpl.

Public Methods

NameDescription
IOleInPlaceObjectWindowlessImpl::ContextSensitiveHelpEnables context-sensitive help. The ATL implementation returns E_NOTIMPL.
IOleInPlaceObjectWindowlessImpl::GetDropTargetSupplies the IDropTarget interface for an in-place active, windowless object that supports drag and drop. The ATL implementation returns E_NOTIMPL.
IOleInPlaceObjectWindowlessImpl::GetWindowGets a window handle.
IOleInPlaceObjectWindowlessImpl::InPlaceDeactivateDeactivates an active in-place control.
IOleInPlaceObjectWindowlessImpl::OnWindowMessageDispatches a message from the container to a windowless control that is in-place active.
IOleInPlaceObjectWindowlessImpl::ReactivateAndUndoReactivates a previously deactivated control. The ATL implementation returns E_NOTIMPL.
IOleInPlaceObjectWindowlessImpl::SetObjectRectsIndicates what part of the in-place control is visible.
IOleInPlaceObjectWindowlessImpl::UIDeactivateDeactivates and removes the user interface that supports in-place activation.

The IOleInPlaceObject interface manages the reactivation and deactivation of in-place controls and determines how much of the control should be visible. The IOleInPlaceObjectWindowless interface enables a windowless control to receive window messages and to participate in drag-and-drop operations. Class IOleInPlaceObjectWindowlessImpl provides a default implementation of IOleInPlaceObject and IOleInPlaceObjectWindowless and implements IUnknown by sending information to the dump device in debug builds.

Related Articles ATL Tutorial, Creating an ATL Project

IOleInPlaceObjectWindowless

IOleInPlaceObjectWindowlessImpl

Header: atlctl.h

Returns E_NOTIMPL.

HRESULT ContextSensitiveHelp(BOOL fEnterMode);

Remarks

See IOleWindow::ContextSensitiveHelp in the Windows SDK.

Returns E_NOTIMPL.

HRESULT GetDropTarget(IDropTarget** ppDropTarget);

Remarks

See IOleInPlaceObjectWindowless::GetDropTarget in the Windows SDK.

The container calls this function to get the window handle of the control.

HRESULT GetWindow(HWND* phwnd);

Remarks

Some containers will not work with a control that has been windowless, even if it is currently windowed. In ATL's implementation, if the control class's data member m_bWasOnceWindowless is TRUE, the function returns E_FAIL. Otherwise, if phwnd is not NULL, GetWindow sets * phwnd to the control class's data member m_hWnd and returns S_OK.

See IOleWindow::GetWindow in the Windows SDK.

Called by the container to deactivate an in-place active control.

HRESULT InPlaceDeactivate(HWND* phwnd);

Remarks

This method performs a full or partial deactivation depending on the state of the control. If necessary, the control's user interface is deactivated, and the control's window, if any, is destroyed. The container is notified that the control is no longer active in place. The IOleInPlaceUIWindow interface used by the container to negotiate menus and border space is released.

See IOleInPlaceObject::InPlaceDeactivate in the Windows SDK.

Dispatches a message from a container to a windowless control that is in-place active.

HRESULT OnWindowMessage(
    UINT msg,
    WPARAM WParam,
    LPARAM LParam,
    LRESULT plResultParam);

Remarks

See IOleInPlaceObjectWindowless::OnWindowMessage in the Windows SDK.

Returns E_NOTIMPL.

HRESULT ReactivateAndUndo();

Remarks

See IOleInPlaceObject::ReactivateAndUndo in the Windows SDK.

Called by the container to inform the control that its size and/or position has changed.

HRESULT SetObjectRects(LPCRECT prcPos, LPCRECT prcClip);

Remarks

Updates the control's m_rcPos data member and the control display. Only the part of the control that intersects the clip region is displayed. If a control's display was previously clipped but the clipping has been removed, this function can be called to redraw a full view of the control.

See IOleInPlaceObject::SetObjectRects in the Windows SDK.

Deactivates and removes the control's user interface that supports in-place activation.

HRESULT UIDeactivate();

Remarks

Sets the control class's data member m_bUIActive to FALSE. The ATL implementation of this function always returns S_OK.

See IOleInPlaceObject::UIDeactivate in the Windows SDK.

CComControl Class
Class Overview

Show: