]> git.saurik.com Git - wxWidgets.git/blob - include/wx/mac/carbon/accel.h
adding OS level Window Menu by default
[wxWidgets.git] / include / wx / mac / carbon / accel.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: accel.h
3 // Purpose: wxAcceleratorTable class
4 // Author: Stefan Csomor
5 // Modified by:
6 // Created: 1998-01-01
7 // RCS-ID: $Id$
8 // Copyright: (c) Stefan Csomor
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_ACCEL_H_
13 #define _WX_ACCEL_H_
14
15 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
16 #pragma interface "accel.h"
17 #endif
18
19 #include "wx/string.h"
20 #include "wx/event.h"
21
22 class WXDLLEXPORT wxAcceleratorTable: public wxObject
23 {
24 DECLARE_DYNAMIC_CLASS(wxAcceleratorTable)
25 public:
26 wxAcceleratorTable();
27 wxAcceleratorTable(int n, const wxAcceleratorEntry entries[]); // Load from array
28
29 // Copy constructors
30 wxAcceleratorTable(const wxAcceleratorTable& accel)
31 : wxObject()
32 { Ref(accel); }
33 wxAcceleratorTable(const wxAcceleratorTable* accel)
34 { if (accel) Ref(*accel); }
35
36 ~wxAcceleratorTable();
37
38 wxAcceleratorTable& operator = (const wxAcceleratorTable& accel)
39 { if (*this == accel) return (*this); Ref(accel); return *this; }
40 bool operator == (const wxAcceleratorTable& accel)
41 { return m_refData == accel.m_refData; }
42 bool operator != (const wxAcceleratorTable& accel)
43 { return m_refData != accel.m_refData; }
44
45 bool Ok() const;
46
47 int GetCommand( wxKeyEvent &event );
48 };
49
50 // WXDLLEXPORT_DATA(extern wxAcceleratorTable) wxNullAcceleratorTable;
51
52 #endif
53 // _WX_ACCEL_H_