]>
Commit | Line | Data |
---|---|---|
110f3205 | 1 | ///////////////////////////////////////////////////////////////////////////// |
1e6feb95 | 2 | // Name: wx/msw/accel.h |
110f3205 JS |
3 | // Purpose: wxAcceleratorTable class |
4 | // Author: Julian Smart | |
5 | // Modified by: | |
6 | // Created: 31/7/98 | |
7 | // RCS-ID: $Id$ | |
8 | // Copyright: (c) Julian Smart | |
65571936 | 9 | // Licence: wxWindows licence |
110f3205 JS |
10 | ///////////////////////////////////////////////////////////////////////////// |
11 | ||
12 | #ifndef _WX_ACCEL_H_ | |
13 | #define _WX_ACCEL_H_ | |
14 | ||
706e740f PC |
15 | class WXDLLIMPEXP_CORE wxWindow; |
16 | ||
c50f1fb9 VZ |
17 | // ---------------------------------------------------------------------------- |
18 | // the accel table has all accelerators for a given window or menu | |
19 | // ---------------------------------------------------------------------------- | |
20 | ||
21 | class WXDLLEXPORT wxAcceleratorTable : public wxObject | |
110f3205 | 22 | { |
110f3205 | 23 | public: |
1e6feb95 | 24 | // default ctor |
f8855e47 | 25 | wxAcceleratorTable() { } |
1e6feb95 VZ |
26 | |
27 | // load from .rc resource (Windows specific) | |
28 | wxAcceleratorTable(const wxString& resource); | |
29 | ||
30 | // initialize from array | |
31 | wxAcceleratorTable(int n, const wxAcceleratorEntry entries[]); | |
110f3205 | 32 | |
a21d4ad1 | 33 | bool operator==(const wxAcceleratorTable& accel) const; |
1e6feb95 VZ |
34 | bool operator!=(const wxAcceleratorTable& accel) const |
35 | { return !(*this == accel); } | |
c50f1fb9 | 36 | |
b7cacb43 VZ |
37 | bool Ok() const { return IsOk(); } |
38 | bool IsOk() const; | |
110f3205 JS |
39 | void SetHACCEL(WXHACCEL hAccel); |
40 | WXHACCEL GetHACCEL() const; | |
c50f1fb9 | 41 | |
77c46f00 | 42 | // translate the accelerator, return true if done |
c50f1fb9 | 43 | bool Translate(wxWindow *window, WXMSG *msg) const; |
110f3205 | 44 | |
1e6feb95 VZ |
45 | private: |
46 | DECLARE_DYNAMIC_CLASS(wxAcceleratorTable) | |
47 | }; | |
110f3205 JS |
48 | |
49 | #endif | |
50 | // _WX_ACCEL_H_ |