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