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