]>
Commit | Line | Data |
---|---|---|
2c40a813 | 1 | /*++\r |
2 | \r | |
3 | Copyright (c) 2007, Intel Corporation \r | |
4 | All rights reserved. This program and the accompanying materials \r | |
5 | are licensed and made available under the terms and conditions of the BSD License \r | |
6 | which accompanies this distribution. The full text of the license may be found at \r | |
7 | http://opensource.org/licenses/bsd-license.php \r | |
8 | \r | |
9 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
10 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
11 | \r | |
12 | Module Name:\r | |
13 | \r | |
14 | AbsolutePointer.h\r | |
15 | \r | |
16 | Abstract:\r | |
17 | \r | |
18 | EFI_ABSOLUTE_POINTER_PROTOCOL from the UEFI 2.1 specification.\r | |
19 | \r | |
20 | This protocol specifies a simple method for accessing absolute pointer devices. \r | |
21 | \r | |
22 | --*/\r | |
23 | \r | |
24 | #ifndef __ABSOLUTE_POINTER_H__\r | |
25 | #define __ABSOLUTE_POINTER_H__\r | |
26 | \r | |
27 | #define EFI_ABSOLUTE_POINTER_PROTOCOL_GUID \\r | |
28 | { \\r | |
29 | 0x8D59D32B, 0xC655, 0x4AE9, 0x9B, 0x15, 0xF2, 0x59, 0x04, 0x99, 0x2A, 0x43 \\r | |
30 | }\r | |
31 | \r | |
32 | EFI_FORWARD_DECLARATION (EFI_ABSOLUTE_POINTER_PROTOCOL);\r | |
33 | \r | |
34 | //\r | |
35 | // Data structures\r | |
36 | //\r | |
37 | \r | |
38 | typedef struct {\r | |
39 | UINT64 AbsoluteMinX;\r | |
40 | UINT64 AbsoluteMinY;\r | |
41 | UINT64 AbsoluteMinZ;\r | |
42 | UINT64 AbsoluteMaxX;\r | |
43 | UINT64 AbsoluteMaxY;\r | |
44 | UINT64 AbsoluteMaxZ;\r | |
45 | UINT32 Attributes;\r | |
46 | } EFI_ABSOLUTE_POINTER_MODE;\r | |
47 | \r | |
48 | typedef struct {\r | |
49 | UINT64 CurrentX;\r | |
50 | UINT64 CurrentY;\r | |
51 | UINT64 CurrentZ;\r | |
52 | UINT32 ActiveButtons;\r | |
53 | } EFI_ABSOLUTE_POINTER_STATE;\r | |
54 | \r | |
55 | #define EFI_ABSP_SupportsAltActive 0x00000001\r | |
56 | #define EFI_ABSP_SupportsPressureAsZ 0x00000002\r | |
57 | \r | |
58 | #define EFI_ABSP_TouchActive 0x00000001\r | |
59 | #define EFI_ABS_AltActive 0x00000002 \r | |
60 | \r | |
61 | typedef\r | |
62 | EFI_STATUS\r | |
63 | (EFIAPI *EFI_ABSOLUTE_POINTER_RESET) (\r | |
64 | IN EFI_ABSOLUTE_POINTER_PROTOCOL *This,\r | |
65 | IN BOOLEAN ExtendedVerification\r | |
66 | )\r | |
67 | /*++\r | |
68 | \r | |
69 | Routine Description:\r | |
70 | Resets the pointer device hardware.\r | |
71 | \r | |
72 | Arguments:\r | |
73 | This - Protocol instance pointer.\r | |
74 | ExtendedVerification - Driver may perform diagnostics on reset.\r | |
75 | \r | |
76 | Returns:\r | |
77 | EFI_SUCCESS - The device was reset.\r | |
78 | EFI_DEVICE_ERROR - The device is not functioning correctly and could \r | |
79 | not be reset.\r | |
80 | \r | |
81 | --*/\r | |
82 | ;\r | |
83 | \r | |
84 | typedef\r | |
85 | EFI_STATUS\r | |
86 | (EFIAPI *EFI_ABSOLUTE_POINTER_GET_STATE) (\r | |
87 | IN EFI_ABSOLUTE_POINTER_PROTOCOL *This,\r | |
88 | IN OUT EFI_ABSOLUTE_POINTER_STATE *State\r | |
89 | )\r | |
90 | /*++\r | |
91 | \r | |
92 | Routine Description:\r | |
93 | Retrieves the current state of a pointer device.\r | |
94 | \r | |
95 | Arguments:\r | |
96 | This - Protocol instance pointer.\r | |
97 | State - A pointer to the state information on the pointer device.\r | |
98 | \r | |
99 | Returns:\r | |
100 | EFI_SUCCESS - The state of the pointer device was returned in State..\r | |
101 | EFI_NOT_READY - The state of the pointer device has not changed since the last call to\r | |
102 | GetState(). \r | |
103 | EFI_DEVICE_ERROR - A device error occurred while attempting to retrieve the pointer\r | |
104 | device's current state. \r | |
105 | --*/\r | |
106 | ;\r | |
107 | \r | |
e5bce275 | 108 | struct _EFI_ABSOLUTE_POINTER_PROTOCOL {\r |
2c40a813 | 109 | EFI_ABSOLUTE_POINTER_RESET Reset;\r |
110 | EFI_ABSOLUTE_POINTER_GET_STATE GetState;\r | |
111 | EFI_EVENT WaitForInput;\r | |
112 | EFI_ABSOLUTE_POINTER_MODE *Mode;\r | |
e5bce275 | 113 | };\r |
2c40a813 | 114 | \r |
115 | extern EFI_GUID gEfiAbsolutePointerProtocolGuid;\r | |
116 | \r | |
117 | #endif\r |