1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
9 #include "mozilla/StandardInteger.h"
12 * This is in a separate header file because it needs to be included
13 * in many places where including nsGUIEvent.h would bring in many
14 * header files that are totally unnecessary.
17 enum UIStateChangeType
{
18 UIStateChangeType_NoChange
,
19 UIStateChangeType_Set
,
20 UIStateChangeType_Clear
24 * Return status for event processors.
28 /// The event is ignored, do default processing
29 nsEventStatus_eIgnore
,
30 /// The event is consumed, don't do default processing
31 nsEventStatus_eConsumeNoDefault
,
32 /// The event is consumed, but do default processing
33 nsEventStatus_eConsumeDoDefault
37 * sizemode is an adjunct to widget size
40 nsSizeMode_Normal
= 0,
46 struct nsAlternativeCharCode
;
47 struct nsTextRangeStyle
;
52 class nsScriptErrorEvent
;
53 class nsScrollbarEvent
;
54 class nsScrollPortEvent
;
55 class nsScrollAreaEvent
;
57 class nsMouseEvent_base
;
62 class nsCompositionEvent
;
63 class nsMouseScrollEvent
;
64 class nsGestureNotifyEvent
;
65 class nsQueryContentEvent
;
67 class nsSelectionEvent
;
68 class nsContentCommandEvent
;
69 class nsMozTouchEvent
;
74 class nsSimpleGestureEvent
;
75 class nsTransitionEvent
;
76 class nsAnimationEvent
;
84 // All modifier keys should be defined here. This is used for managing
85 // modifier states for DOM Level 3 or later.
87 MODIFIER_ALT
= 0x0001,
88 MODIFIER_ALTGRAPH
= 0x0002,
89 MODIFIER_CAPSLOCK
= 0x0004,
90 MODIFIER_CONTROL
= 0x0008,
92 MODIFIER_META
= 0x0020,
93 MODIFIER_NUMLOCK
= 0x0040,
94 MODIFIER_SCROLLLOCK
= 0x0080,
95 MODIFIER_SHIFT
= 0x0100,
96 MODIFIER_SYMBOLLOCK
= 0x0200,
100 typedef uint16_t Modifiers
;
102 } // namespace widget
103 } // namespace mozilla
105 #define NS_DOM_KEYNAME_ALT "Alt"
106 #define NS_DOM_KEYNAME_ALTGRAPH "AltGraph"
107 #define NS_DOM_KEYNAME_CAPSLOCK "CapsLock"
108 #define NS_DOM_KEYNAME_CONTROL "Control"
109 #define NS_DOM_KEYNAME_FN "Fn"
110 #define NS_DOM_KEYNAME_META "Meta"
111 #define NS_DOM_KEYNAME_NUMLOCK "NumLock"
112 #define NS_DOM_KEYNAME_SCROLLLOCK "ScrollLock"
113 #define NS_DOM_KEYNAME_SHIFT "Shift"
114 #define NS_DOM_KEYNAME_SYMBOLLOCK "SymbolLock"
115 #define NS_DOM_KEYNAME_OS "OS"
117 #endif // nsEvent_h__