]>
Commit | Line | Data |
---|---|---|
23324ae1 FM |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: msw/ole/activex.h | |
e54c96f1 | 3 | // Purpose: interface of wxActiveXEvent |
23324ae1 FM |
4 | // Author: wxWidgets team |
5 | // RCS-ID: $Id$ | |
6 | // Licence: wxWindows license | |
7 | ///////////////////////////////////////////////////////////////////////////// | |
8 | ||
9 | /** | |
10 | @class wxActiveXEvent | |
11 | @headerfile ole/activex.h wx/msw/ole/activex.h | |
4cc4bfaf | 12 | |
23324ae1 FM |
13 | An event class for handling activex events passed from |
14 | wxActiveXContainer. ActiveX events are basically | |
15 | a function call with the parameters passed through an array of wxVariants along | |
16 | with a return value that is a wxVariant itself. What type the parameters or | |
17 | return value are depends on the context (i.e. what the .idl specifies). | |
4cc4bfaf | 18 | |
23324ae1 | 19 | Note that unlike the third party wxActiveX function names are not supported. |
4cc4bfaf | 20 | |
23324ae1 FM |
21 | @library{wxbase} |
22 | @category{FIXME} | |
23 | */ | |
24 | class wxActiveXEvent : public wxCommandEvent | |
25 | { | |
26 | public: | |
27 | /** | |
28 | Returns the dispatch id of this activex event. This is the numeric value from | |
29 | the .idl file specified by the id(). | |
30 | */ | |
328f5751 | 31 | DISPID GetDispatchId(int idx) const; |
23324ae1 FM |
32 | |
33 | /** | |
34 | Obtains the number of parameters passed through the activex event. | |
35 | */ | |
328f5751 | 36 | size_t ParamCount() const; |
23324ae1 FM |
37 | |
38 | /** | |
39 | Obtains the param name of the param number idx specifies as a string. | |
40 | */ | |
328f5751 | 41 | wxString ParamName(size_t idx) const; |
23324ae1 FM |
42 | |
43 | /** | |
44 | Obtains the param type of the param number idx specifies as a string. | |
45 | */ | |
328f5751 | 46 | wxString ParamType(size_t idx) const; |
23324ae1 FM |
47 | |
48 | /** | |
49 | Obtains the actual parameter value specified by idx. | |
50 | */ | |
51 | wxVariant operator[](size_t idx); | |
52 | }; | |
53 | ||
54 | ||
e54c96f1 | 55 | |
23324ae1 FM |
56 | /** |
57 | @class wxActiveXContainer | |
58 | @headerfile ole/activex.h wx/msw/ole/activex.h | |
4cc4bfaf | 59 | |
23324ae1 FM |
60 | wxActiveXContainer is a host for an activex control on Windows (and |
61 | as such is a platform-specific class). Note that the HWND that the class | |
62 | contains is the actual HWND of the activex control so using dynamic events | |
63 | and connecting to wxEVT_SIZE, for example, will recieve the actual size | |
64 | message sent to the control. | |
4cc4bfaf | 65 | |
23324ae1 | 66 | It is somewhat similar to the ATL class CAxWindow in operation. |
4cc4bfaf | 67 | |
23324ae1 FM |
68 | The size of the activex control's content is generally gauranteed to be that |
69 | of the client size of the parent of this wxActiveXContainer. | |
4cc4bfaf | 70 | |
23324ae1 FM |
71 | You can also process activex events through wxEVT_ACTIVEX or the |
72 | corresponding message map macro EVT_ACTIVEX. | |
4cc4bfaf | 73 | |
23324ae1 FM |
74 | @library{wxbase} |
75 | @category{FIXME} | |
4cc4bfaf | 76 | |
e54c96f1 | 77 | @see wxActiveXEvent |
23324ae1 FM |
78 | */ |
79 | class wxActiveXContainer : public wxControl | |
80 | { | |
81 | public: | |
82 | /** | |
83 | Creates this activex container. | |
84 | ||
4cc4bfaf FM |
85 | @param parent |
86 | parent of this control. Must not be @NULL. | |
87 | @param iid | |
88 | COM IID of pUnk to query. Must be a valid interface to an activex control. | |
89 | @param pUnk | |
90 | Interface of activex control | |
23324ae1 FM |
91 | */ |
92 | wxActiveXContainer(wxWindow* parent, REFIID iid, IUnknown* pUnk); | |
93 | }; | |
e54c96f1 | 94 |