Udostępnij za pośrednictwem


IOleInPlaceComponent Interface

Definition

Allows in-place VSPackage objects to operate as a fully integrated component of the environment by using the SOleComponentUIManager service.

public interface class IOleInPlaceComponent
public interface class IOleInPlaceComponent
__interface IOleInPlaceComponent
[System.Runtime.InteropServices.Guid("5EFC7970-14BC-11CF-9B2B-00AA00573819")]
[System.Runtime.InteropServices.InterfaceType(1)]
public interface IOleInPlaceComponent
[System.Runtime.InteropServices.Guid("5EFC7970-14BC-11CF-9B2B-00AA00573819")]
[System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)]
public interface IOleInPlaceComponent
[<System.Runtime.InteropServices.Guid("5EFC7970-14BC-11CF-9B2B-00AA00573819")>]
[<System.Runtime.InteropServices.InterfaceType(1)>]
type IOleInPlaceComponent = interface
[<System.Runtime.InteropServices.Guid("5EFC7970-14BC-11CF-9B2B-00AA00573819")>]
[<System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)>]
type IOleInPlaceComponent = interface
Public Interface IOleInPlaceComponent
Attributes

Remarks

The SOleComponentUIManager service is an alternative to the traditional OLE in-place activation. Rather than require the in-place object to participate in menu merging, this service integrates the menus, toolbars, and commands of the object into the environment and issues notifications of state changes. Allows in-place VSPackage objects to operate as a fully integrated component of the environment by using the SOleComponentUIManager service. The T:Microsoft.VisualStudio.Shell.Interop.SOleComponentUIManager service is an alternative to the traditional OLE in-place activation. Rather than require the in-place object to participate in menu merging, this service integrates the menus, toolbars, and commands of the object into the environment and issues notifications of state changes.

Notes to Implementers

VSPackages implement IOleInPlaceComponent if they support an in-place object with UI elements that should be integrated into the environment's user interface. IOleInPlaceComponent is also implemented if the VSPackage wants to participate in handling the in-place object's commands when it activates.

In-place VSPackage objects that implement IOleInPlaceComponent also implement IOleInPlaceObject, IOleInPlaceActiveObject and IOleCommandTarget. To initiate use of the SOleComponentUIManager services, an in-place object calls IOleInPlaceActiveObject when it activates.

Notes to Callers

The environment's SOleComponentUIManager service makes calls to an in-place VSPackage object's IOleInPlaceComponent interface to communicate state changes and allow the object to handle commands. The environment calls an in-place object's QueryInterface method using the IOleInPlaceObject interface to receive an IOleInPlaceComponent pointer.

Methods

FDoIdle(UInt32)

Queries an in-place VSPackage about its need to perform idle time tasks.

FQueryClose(Int32)

Queries an in-place VSPackage object to determine whether or not the object can terminate.

GetCntrContextMenu(UInt32, Guid, Int32, POINTS[], Guid, OLEMENUID[], UInt32)

Allows an in-place VSPackage object assuming the role of main component to override the context menu requested by an object assuming the subcomponent or component control role.

GetCntrHelp(UInt32, Guid, POINT, UInt32, String, String, UInt32, UInt32)

Allows an in-place VSPackage object assuming the main component role to override the help topic requested by an object assuming the subcomponent or component control role.

GetCntrMessage(UInt32, Guid, String, String, String, String, String, String, UInt32, OLEMSGBUTTON[], OLEMSGDEFBUTTON[], OLEMSGICON[], Int32)

Allows an in-place VSPackage object assuming the main component role to override a message belonging to an object assuming the subcomponent or component control role.

OnEnterState(UInt32, Int32)

Informs an in-place VSPackage object that the environment has entered or left a state.

OnWindowActivate(UInt32, Int32)

Informs an in-place VSPackage object of important window activation events.

TranslateCntrAccelerator(MSG[])

Requests that an in-place VSPackage object translate a command accelerator.

UseComponentUIManager(UInt32, UInt32, IOleComponentUIManager, IOleInPlaceComponentSite)

Informs an in-place object of its role in the environment, providing pointers to the IOleComponentUIManager and IOleInPlaceComponentSite interfaces.

Applies to