iPXE
SimplePointer.h
Go to the documentation of this file.
1/** @file
2 Simple Pointer protocol from the UEFI 2.0 specification.
3
4 Abstraction of a very simple pointer device like a mouse or trackball.
5
6 Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
7 SPDX-License-Identifier: BSD-2-Clause-Patent
8
9**/
10
11#ifndef __SIMPLE_POINTER_H__
12#define __SIMPLE_POINTER_H__
13
14FILE_LICENCE ( BSD2_PATENT );
15FILE_SECBOOT ( PERMITTED );
16
17#define EFI_SIMPLE_POINTER_PROTOCOL_GUID \
18 { \
19 0x31878c87, 0xb75, 0x11d5, {0x9a, 0x4f, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d } \
20 }
21
23
24//
25// Data structures
26//
27typedef struct {
28 ///
29 /// The signed distance in counts that the pointer device has been moved along the x-axis.
30 ///
32 ///
33 /// The signed distance in counts that the pointer device has been moved along the y-axis.
34 ///
36 ///
37 /// The signed distance in counts that the pointer device has been moved along the z-axis.
38 ///
40 ///
41 /// If TRUE, then the left button of the pointer device is being
42 /// pressed. If FALSE, then the left button of the pointer device is not being pressed.
43 ///
45 ///
46 /// If TRUE, then the right button of the pointer device is being
47 /// pressed. If FALSE, then the right button of the pointer device is not being pressed.
48 ///
51
52typedef struct {
53 ///
54 /// The resolution of the pointer device on the x-axis in counts/mm.
55 /// If 0, then the pointer device does not support an x-axis.
56 ///
58 ///
59 /// The resolution of the pointer device on the y-axis in counts/mm.
60 /// If 0, then the pointer device does not support a y-axis.
61 ///
63 ///
64 /// The resolution of the pointer device on the z-axis in counts/mm.
65 /// If 0, then the pointer device does not support a z-axis.
66 ///
68 ///
69 /// TRUE if a left button is present on the pointer device. Otherwise FALSE.
70 ///
72 ///
73 /// TRUE if a right button is present on the pointer device. Otherwise FALSE.
74 ///
77
78/**
79 Resets the pointer device hardware.
80
81 @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
82 instance.
83 @param ExtendedVerification Indicates that the driver may perform a more exhaustive
84 verification operation of the device during reset.
85
86 @retval EFI_SUCCESS The device was reset.
87 @retval EFI_DEVICE_ERROR The device is not functioning correctly and could not be reset.
88
89**/
90typedef
94 IN BOOLEAN ExtendedVerification
95 );
96
97/**
98 Retrieves the current state of a pointer device.
99
100 @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
101 instance.
102 @param State A pointer to the state information on the pointer device.
103
104 @retval EFI_SUCCESS The state of the pointer device was returned in State.
105 @retval EFI_NOT_READY The state of the pointer device has not changed since the last call to
106 GetState().
107 @retval EFI_DEVICE_ERROR A device error occurred while attempting to retrieve the pointer device's
108 current state.
109
110**/
111typedef
116 );
117
118///
119/// The EFI_SIMPLE_POINTER_PROTOCOL provides a set of services for a pointer
120/// device that can use used as an input device from an application written
121/// to this specification. The services include the ability to reset the
122/// pointer device, retrieve get the state of the pointer device, and
123/// retrieve the capabilities of the pointer device.
124///
128 ///
129 /// Event to use with WaitForEvent() to wait for input from the pointer device.
130 ///
132 ///
133 /// Pointer to EFI_SIMPLE_POINTER_MODE data.
134 ///
136};
137
139
140#endif
unsigned char BOOLEAN
Logical Boolean.
unsigned long long UINT64
8-byte unsigned value.
int INT32
4-byte signed value.
#define EFIAPI
EFI_STATUS(EFIAPI * EFI_SIMPLE_POINTER_RESET)(IN EFI_SIMPLE_POINTER_PROTOCOL *This, IN BOOLEAN ExtendedVerification)
Resets the pointer device hardware.
struct _EFI_SIMPLE_POINTER_PROTOCOL EFI_SIMPLE_POINTER_PROTOCOL
EFI_STATUS(EFIAPI * EFI_SIMPLE_POINTER_GET_STATE)(IN EFI_SIMPLE_POINTER_PROTOCOL *This, OUT EFI_SIMPLE_POINTER_STATE *State)
Retrieves the current state of a pointer device.
EFI_GUID gEfiSimplePointerProtocolGuid
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
GUID EFI_GUID
128-bit buffer containing a unique identifier value.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
Definition compiler.h:896
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
Definition compiler.h:926
#define EFI_EVENT
Definition efi.h:54
#define IN
Definition mlx_utils.h:28
#define OUT
Definition mlx_utils.h:29
UINT64 ResolutionY
The resolution of the pointer device on the y-axis in counts/mm.
UINT64 ResolutionX
The resolution of the pointer device on the x-axis in counts/mm.
UINT64 ResolutionZ
The resolution of the pointer device on the z-axis in counts/mm.
BOOLEAN LeftButton
TRUE if a left button is present on the pointer device.
BOOLEAN RightButton
TRUE if a right button is present on the pointer device.
INT32 RelativeMovementY
The signed distance in counts that the pointer device has been moved along the y-axis.
BOOLEAN LeftButton
If TRUE, then the left button of the pointer device is being pressed.
INT32 RelativeMovementX
The signed distance in counts that the pointer device has been moved along the x-axis.
INT32 RelativeMovementZ
The signed distance in counts that the pointer device has been moved along the z-axis.
BOOLEAN RightButton
If TRUE, then the right button of the pointer device is being pressed.
The EFI_SIMPLE_POINTER_PROTOCOL provides a set of services for a pointer device that can use used as ...
EFI_SIMPLE_POINTER_GET_STATE GetState
EFI_EVENT WaitForInput
Event to use with WaitForEvent() to wait for input from the pointer device.
EFI_SIMPLE_POINTER_MODE * Mode
Pointer to EFI_SIMPLE_POINTER_MODE data.
EFI_SIMPLE_POINTER_RESET Reset