Docking Window Interfaces

Docking windows require the use of four interfaces: IObjectWithSite, IDockingWindow, IDockingWindowFrame, and IDockingWindowSite. In the remainder of this section, we’ll discuss the four interfaces and their members that are relevant to developing docking windows.

IObjectWithSite

The shell provides a site pointer to the docking window via the IObjectWithSite interface in a manner similar to browser helper objects or band objects. The primary object—that is, the object that will create the docking window—uses IObjectWithSite to obtain references to IServiceProvider and, optionally, IWebBrowser2. The secondary component, which is the actual docking window implementation, uses IObjectWithSite to obtain IDockingWindowFrame. IObjectWithSite is summarized in Table 14.2, but for a more complete discussion, please refer to Chapter 12.

Table 14-1. IObjectWithSite Methods

Method

Description

GetSite

Returns the last site set with SetSite.

SetSite

Provides the IUnknown site pointer of Explorer.

IDockingWindow

We have already discussed IDockingWindow. If you remember our discussion of band objects, the IDeskband interface is derived from IDockingWindow. There is nothing new that we need to discuss concerning this interface. Table 14.1 provides a refresher course on the interface and on IOleWindow, the interface from which it is derived, but if you would like more detail, see Chapter 13. Methods marked with an asterisk are not implemented.

Table 14-2. IDockingWindow ...

Get VB Shell Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.