QAxAggregated Class

The QAxAggregated class is an abstract base class for implementations of additional COM interfaces. More...

Header: #include <QAxAggregated>
qmake: QT += axserver

Public Functions

virtual long queryInterface(const QUuid &iid, void **iface) = 0

Protected Functions

QAxAggregated()
virtual ~QAxAggregated()
IUnknown *controllingUnknown() const
QObject *object() const
QWidget *widget() const

Detailed Description

The QAxAggregated class is an abstract base class for implementations of additional COM interfaces.

Create a subclass of QAxAggregated and reimplement queryInterface() to support additional COM interfaces. Use multiple inheritance from those COM interfaces. Implement the IUnknown interface of those COM interfaces by delegating the calls to QueryInterface(), AddRef() and Release() to the interface provided by controllingUnknown().

Use the widget() method if you need to make calls to the QWidget implementing the ActiveX control. You must not store that pointer in your subclass (unless you use QPointer), as the QWidget can be destroyed by the ActiveQt framework at any time.

See also QAxBindable, QAxFactory, and Active Qt.

Member Function Documentation

[protected] QAxAggregated::QAxAggregated()

Default constructs an instance of QAxAggregated.

[virtual protected] QAxAggregated::~QAxAggregated()

Destroys the instance of QAxAggregated. The destructor is virtual.

[protected] IUnknown *QAxAggregated::controllingUnknown() const

[protected] QObject *QAxAggregated::object() const

[pure virtual] long QAxAggregated::queryInterface(const QUuid &iid, void **iface)

[protected] QWidget *QAxAggregated::widget() const

Returns a pointer to the QWidget subclass implementing the ActiveX control. This function might return 0.

Warning: You must not store the returned pointer, unless you use a QPointer, since the QWidget can be destroyed by ActiveQt at any time.