Qt 4.8
|
The QAxAggregated class is an abstract base class for implementations of additional COM interfaces. More...
#include <qaxaggregated.h>
Public Functions | |
virtual long | queryInterface (const QUuid &iid, void **iface)=0 |
Reimplement this pure virtual function to support additional COM interfaces. More... | |
Protected Functions | |
IUnknown * | controllingUnknown () const |
Returns the IUnknown interface of the ActiveX control. More... | |
QObject * | object () const |
Returns a pointer to the QObject subclass implementing the COM object. More... | |
QWidget * | widget () const |
Returns a pointer to the QWidget subclass implementing the ActiveX control. More... | |
virtual | ~QAxAggregated () |
The destructor is called internally by Qt. More... | |
Properties | |
IUnknown * | controlling_unknown |
QObject * | the_object |
Friends | |
class | QAxClientSite |
class | QAxServerBase |
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.
Definition at line 58 of file qaxaggregated.h.
|
inlineprotectedvirtual |
|
inlineprotected |
Returns the IUnknown
interface of the ActiveX control.
Implement the IUnknown
interface in your QAxAggregated subclass to delegate calls to QueryInterface()
, AddRef()
, and Release()
to the interface provided by this function.
Instead of declaring and implementing these three functions manually, you can use the QAXAGG_IUNKNOWN
macro in the class declaration of your subclass.
Definition at line 69 of file qaxaggregated.h.
|
inlineprotected |
Returns a pointer to the QObject subclass implementing the COM object.
This function might return 0.
Definition at line 75 of file qaxaggregated.h.
|
pure virtual |
Reimplement this pure virtual function to support additional COM interfaces.
Set the value of iface to point to this object to support the interface iid. Note that you must cast the this
pointer to the appropriate superclass.
Return the standard COM results S_OK
(interface is supported) or E_NOINTERFACE
(requested interface is not supported).
IUnknown
interface if you implement any COM interface you must not support the IUnknown
interface in your queryInterface() implementation. Referenced by QAxServerBase::InternalQueryInterface(), and QAxClientSite::QueryInterface().
|
inlineprotected |
Returns a pointer to the QWidget subclass implementing the ActiveX control.
This function might return 0.
Definition at line 71 of file qaxaggregated.h.
|
friend |
Definition at line 61 of file qaxaggregated.h.
|
friend |
Definition at line 60 of file qaxaggregated.h.
|
private |
Definition at line 78 of file qaxaggregated.h.
Referenced by controllingUnknown(), QAxServerBase::internalBind(), and QAxClientSite::QAxClientSite().
|
private |
Definition at line 79 of file qaxaggregated.h.
Referenced by QAxServerBase::internalBind(), object(), QAxClientSite::QAxClientSite(), widget(), and QAxClientSite::~QAxClientSite().