]> git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Include/Protocol/SimplePointer.h
Update DriverConfiguration2.h to avoid the name conflict with DriverConfiguration.h
[mirror_edk2.git] / MdePkg / Include / Protocol / SimplePointer.h
1 /** @file
2 Simple Pointer protocol from the EFI 1.1 specification.
3
4 Abstraction of a very simple pointer device like a mice or tracekballs.
5
6 Copyright (c) 2006, Intel Corporation
7 All rights reserved. This program and the accompanying materials
8 are licensed and made available under the terms and conditions of the BSD License
9 which accompanies this distribution. The full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
11
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
14
15 Module Name: SimplePointer.h
16
17 **/
18
19 #ifndef __SIMPLE_POINTER_H__
20 #define __SIMPLE_POINTER_H__
21
22 #define EFI_SIMPLE_POINTER_PROTOCOL_GUID \
23 { \
24 0x31878c87, 0xb75, 0x11d5, {0x9a, 0x4f, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d } \
25 }
26
27 typedef struct _EFI_SIMPLE_POINTER_PROTOCOL EFI_SIMPLE_POINTER_PROTOCOL;
28
29 //
30 // Data structures
31 //
32 typedef struct {
33 INT32 RelativeMovementX;
34 INT32 RelativeMovementY;
35 INT32 RelativeMovementZ;
36 BOOLEAN LeftButton;
37 BOOLEAN RightButton;
38 } EFI_SIMPLE_POINTER_STATE;
39
40 typedef struct {
41 UINT64 ResolutionX;
42 UINT64 ResolutionY;
43 UINT64 ResolutionZ;
44 BOOLEAN LeftButton;
45 BOOLEAN RightButton;
46 } EFI_SIMPLE_POINTER_MODE;
47
48 /**
49 Resets the pointer device hardware.
50
51 @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
52 instance.
53 @param ExtendedVerification Indicates that the driver may perform a more exhaustive
54 verification operation of the device during reset.
55
56 @retval EFI_SUCCESS The device was reset.
57 @retval EFI_DEVICE_ERROR The device is not functioning correctly and could not be reset.
58
59 **/
60 typedef
61 EFI_STATUS
62 (EFIAPI *EFI_SIMPLE_POINTER_RESET) (
63 IN EFI_SIMPLE_POINTER_PROTOCOL *This,
64 IN BOOLEAN ExtendedVerification
65 );
66
67 /**
68 Retrieves the current state of a pointer device.
69
70 @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
71 instance.
72 @param State A pointer to the state information on the pointer device.
73
74 @retval EFI_SUCCESS The state of the pointer device was returned in State.
75 @retval EFI_NOT_READY The state of the pointer device has not changed since the last call to
76 GetState().
77 @retval EFI_DEVICE_ERROR A device error occurred while attempting to retrieve the pointer device's
78 current state.
79
80 **/
81 typedef
82 EFI_STATUS
83 (EFIAPI *EFI_SIMPLE_POINTER_GET_STATE) (
84 IN EFI_SIMPLE_POINTER_PROTOCOL *This,
85 IN OUT EFI_SIMPLE_POINTER_STATE *State
86 );
87
88 struct _EFI_SIMPLE_POINTER_PROTOCOL {
89 EFI_SIMPLE_POINTER_RESET Reset;
90 EFI_SIMPLE_POINTER_GET_STATE GetState;
91 EFI_EVENT WaitForInput;
92 EFI_SIMPLE_POINTER_MODE *Mode;
93 };
94
95 extern EFI_GUID gEfiSimplePointerProtocolGuid;
96
97 #endif