]> git.saurik.com Git - wxWidgets.git/blob - include/wx/palmos/accel.h
reverted r51340: don't use wxWeakRef in the library code as long as not all supported...
[wxWidgets.git] / include / wx / palmos / accel.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/palmos/accel.h
3 // Purpose: wxAcceleratorTable class
4 // Author: William Osborne - minimal working wxPalmOS port
5 // Modified by:
6 // Created: 10/13/04
7 // RCS-ID: $Id$
8 // Copyright: (c) William Osborne
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_ACCEL_H_
13 #define _WX_ACCEL_H_
14
15 // ----------------------------------------------------------------------------
16 // the accel table has all accelerators for a given window or menu
17 // ----------------------------------------------------------------------------
18
19 class WXDLLEXPORT wxAcceleratorTable : public wxObject
20 {
21 public:
22 // default ctor
23 wxAcceleratorTable();
24
25 // load from .rc resource (Windows specific)
26 wxAcceleratorTable(const wxString& resource);
27
28 // initialize from array
29 wxAcceleratorTable(int n, const wxAcceleratorEntry entries[]);
30
31 virtual ~wxAcceleratorTable();
32
33 bool Ok() const { return IsOk(); }
34 bool IsOk() const;
35 void SetHACCEL(WXHACCEL hAccel);
36 WXHACCEL GetHACCEL() const;
37
38 // translate the accelerator, return true if done
39 bool Translate(wxWindow *window, WXMSG *msg) const;
40
41 private:
42 DECLARE_DYNAMIC_CLASS(wxAcceleratorTable)
43 };
44
45 #endif
46 // _WX_ACCEL_H_