IUICollectionChangedEvent interface (uiribbon.h)

The IUICollectionChangedEvent interface is implemented by the application and defines the method required to handle changes to a collection at run time.

Inheritance

The IUICollectionChangedEvent interface inherits from the IUnknown interface. IUICollectionChangedEvent also has these types of members:

Methods

The IUICollectionChangedEvent interface has these methods.

 
IUICollectionChangedEvent::OnChanged

Called when an IUICollection changes.

Remarks

The Windows Ribbon framework incorporates the standard Component Object Model (COM) client-server mechanism of connectable objects to listen for and handle collection changed events at run time.

The Ribbon acts as the COM server connectable object that defines both incoming and outgoing notification interfaces for the client, which is the Ribbon host application. The incoming interfaces are implemented by the Ribbon. The outgoing interfaces are implemented by the application in a dedicated object that is created by the application and referred to as the client connection sink. This sink is used to establish a connection to the connectable object.

In addition to defining the incoming and outgoing interfaces, the Ribbon must also implement the IConnectionPointContainer interface and create at least one connection point object that implements the IConnectionPoint interface and manages the connection with the client sink.

Note  The client must query the connectable object for IConnectionPointContainer to determine whether the object is connectable before the client attempts to create a sink object.
 
In the case of the Ribbon, IUICollectionChangedEvent is the outgoing interface defined by the framework and implemented by the application. The Ribbon triggers the IUICollectionChangedEvent::OnChanged event in the client by sending an outgoing notification when a collection changes, for example, adding a Command to the Quick Access Toolbar (QAT).

Requirements

Requirement Value
Minimum supported client Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps only]
Target Platform Windows
Header uiribbon.h

See also

Events in COM and Connectable Objects

Gallery Sample

IUICollection