]> git.proxmox.com Git - mirror_edk2.git/blame - Tools/Source/TianoTools/Include/Protocol/SimpleTextIn.h
1. Removed the unnecessary #include statements and include files
[mirror_edk2.git] / Tools / Source / TianoTools / Include / Protocol / SimpleTextIn.h
CommitLineData
21b50a27 1/** @file\r
2 Simple Text In protocol from the EFI 1.0 specification.\r
3\r
4 Abstraction of a very simple input device like a keyboard or serial\r
5 terminal.\r
6\r
7 Copyright (c) 2006, Intel Corporation \r
8 All rights reserved. This program and the accompanying materials \r
9 are licensed and made available under the terms and conditions of the BSD License \r
10 which accompanies this distribution. The full text of the license may be found at \r
11 http://opensource.org/licenses/bsd-license.php \r
12\r
13 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
14 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
15\r
16 Module Name: SimpleTextIn.h\r
17\r
18**/\r
19\r
20#ifndef __SIMPLE_TEXT_IN_PROTOCOL_H__\r
21#define __SIMPLE_TEXT_IN_PROTOCOL_H__\r
22\r
23#define EFI_SIMPLE_TEXT_IN_PROTOCOL_GUID \\r
24 { \\r
25 0x387477c1, 0x69c7, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b } \\r
26 }\r
27\r
28#define EFI_SIMPLE_INPUT_PROTOCOL_GUID EFI_SIMPLE_TEXT_IN_PROTOCOL_GUID\r
29#define EFI_SIMPLE_TEXT_INPUT_PROTOCOL_GUID EFI_SIMPLE_TEXT_IN_PROTOCOL_GUID\r
30\r
31typedef struct _EFI_SIMPLE_TEXT_IN_PROTOCOL EFI_SIMPLE_TEXT_IN_PROTOCOL;\r
32typedef struct _EFI_SIMPLE_TEXT_IN_PROTOCOL EFI_SIMPLE_TEXT_INPUT_PROTOCOL;\r
33\r
34//\r
35// Data structures\r
36//\r
37typedef struct {\r
38 UINT16 ScanCode;\r
39 CHAR16 UnicodeChar;\r
40} EFI_INPUT_KEY;\r
41\r
42//\r
43// Required unicode control chars\r
44//\r
45#define CHAR_NULL 0x0000\r
46#define CHAR_BACKSPACE 0x0008\r
47#define CHAR_TAB 0x0009\r
48#define CHAR_LINEFEED 0x000A\r
49#define CHAR_CARRIAGE_RETURN 0x000D\r
50\r
51//\r
52// EFI Scan codes\r
53//\r
54#define SCAN_NULL 0x0000\r
55#define SCAN_UP 0x0001\r
56#define SCAN_DOWN 0x0002\r
57#define SCAN_RIGHT 0x0003\r
58#define SCAN_LEFT 0x0004\r
59#define SCAN_HOME 0x0005\r
60#define SCAN_END 0x0006\r
61#define SCAN_INSERT 0x0007\r
62#define SCAN_DELETE 0x0008\r
63#define SCAN_PAGE_UP 0x0009\r
64#define SCAN_PAGE_DOWN 0x000A\r
65#define SCAN_F1 0x000B\r
66#define SCAN_F2 0x000C\r
67#define SCAN_F3 0x000D\r
68#define SCAN_F4 0x000E\r
69#define SCAN_F5 0x000F\r
70#define SCAN_F6 0x0010\r
71#define SCAN_F7 0x0011\r
72#define SCAN_F8 0x0012\r
73#define SCAN_F9 0x0013\r
74#define SCAN_F10 0x0014\r
75#define SCAN_F11 0x0015\r
76#define SCAN_F12 0x0016\r
77#define SCAN_ESC 0x0017\r
78\r
79/**\r
80 Reset the input device and optionaly run diagnostics\r
81\r
82 @param This Protocol instance pointer.\r
83 @param ExtendedVerification Driver may perform diagnostics on reset.\r
84\r
85 @retval EFI_SUCCESS The device was reset.\r
86 @retval EFI_DEVICE_ERROR The device is not functioning properly and could not be reset.\r
87\r
88**/\r
89typedef\r
90EFI_STATUS\r
91(EFIAPI *EFI_INPUT_RESET) (\r
92 IN EFI_SIMPLE_TEXT_IN_PROTOCOL *This,\r
93 IN BOOLEAN ExtendedVerification\r
94 )\r
95;\r
96\r
97/**\r
98 Reads the next keystroke from the input device. The WaitForKey Event can \r
99 be used to test for existance of a keystroke via WaitForEvent () call.\r
100\r
101 @param This Protocol instance pointer.\r
102 @param Key Driver may perform diagnostics on reset.\r
103\r
104 @retval EFI_SUCCESS The keystroke information was returned.\r
105 @retval EFI_NOT_READY There was no keystroke data availiable.\r
106 @retval EFI_DEVICE_ERROR The keydtroke information was not returned due to\r
107 hardware errors.\r
108\r
109**/\r
110typedef\r
111EFI_STATUS\r
112(EFIAPI *EFI_INPUT_READ_KEY) (\r
113 IN EFI_SIMPLE_TEXT_IN_PROTOCOL *This,\r
114 OUT EFI_INPUT_KEY *Key\r
115 )\r
116;\r
117\r
118struct _EFI_SIMPLE_TEXT_IN_PROTOCOL {\r
119 EFI_INPUT_RESET Reset;\r
120 EFI_INPUT_READ_KEY ReadKeyStroke;\r
121 EFI_EVENT WaitForKey;\r
122} EFI_SIMPLE_INPUT_PROTOCOL;\r
123\r
124extern EFI_GUID gEfiSimpleTextInProtocolGuid;\r
125\r
126#endif\r