3 Copyright (c) 2004 - 2005, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
18 Console based on Win32 APIs.
20 This file attaches a SimpleTextIn protocol to a previously open window.
22 The constructor for this protocol depends on an open window. Currently
23 the SimpleTextOut protocol creates a window when it's constructor is called.
24 Thus this code must run after the constructor for the SimpleTextOut
32 #define UNIX_SIMPLE_TEXT_PRIVATE_DATA_SIGNATURE \
33 EFI_SIGNATURE_32('U','X','s','c')
40 EFI_SIMPLE_TEXT_OUT_PROTOCOL SimpleTextOut
;
41 EFI_SIMPLE_TEXT_OUTPUT_MODE SimpleTextOutMode
;
43 EFI_UNIX_IO_PROTOCOL
*UnixIo
;
44 EFI_UNIX_THUNK_PROTOCOL
*UnixThunk
;
47 // SimpleTextOut Private Data including Win32 types.
49 // HANDLE NtOutHandle;
52 //COORD MaxScreenSize;
57 EFI_SIMPLE_TEXT_IN_PROTOCOL SimpleTextIn
;
59 EFI_UNICODE_STRING_TABLE
*ControllerNameTable
;
61 } UNIX_SIMPLE_TEXT_PRIVATE_DATA
;
63 #define UNIX_SIMPLE_TEXT_OUT_PRIVATE_DATA_FROM_THIS(a) \
64 CR(a, UNIX_SIMPLE_TEXT_PRIVATE_DATA, SimpleTextOut, UNIX_SIMPLE_TEXT_PRIVATE_DATA_SIGNATURE)
66 #define UNIX_SIMPLE_TEXT_IN_PRIVATE_DATA_FROM_THIS(a) \
67 CR(a, UNIX_SIMPLE_TEXT_PRIVATE_DATA, SimpleTextIn, UNIX_SIMPLE_TEXT_PRIVATE_DATA_SIGNATURE)
70 // Console Globale Variables
72 extern EFI_DRIVER_BINDING_PROTOCOL gUnixConsoleDriverBinding
;
73 extern EFI_COMPONENT_NAME_PROTOCOL gUnixConsoleComponentName
;
78 } UNIX_SIMPLE_TEXT_OUT_MODE
;
82 // Simple Text Out protocol member functions
88 UnixSimpleTextOutReset (
89 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
90 IN BOOLEAN ExtendedVerification
96 TODO: Add function description
100 This - TODO: add argument description
101 ExtendedVerification - TODO: add argument description
105 TODO: add return values
113 UnixSimpleTextOutOutputString (
114 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
121 TODO: Add function description
125 This - TODO: add argument description
126 String - TODO: add argument description
130 TODO: add return values
138 UnixSimpleTextOutTestString (
139 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
146 TODO: Add function description
150 This - TODO: add argument description
151 String - TODO: add argument description
155 TODO: add return values
163 UnixSimpleTextOutQueryMode (
164 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
173 TODO: Add function description
177 This - TODO: add argument description
178 ModeNumber - TODO: add argument description
179 Columns - TODO: add argument description
180 Rows - TODO: add argument description
184 TODO: add return values
191 UnixSimpleTextOutSetMode (
192 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
199 TODO: Add function description
203 This - TODO: add argument description
204 ModeNumber - TODO: add argument description
208 TODO: add return values
216 UnixSimpleTextOutSetAttribute (
217 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
224 TODO: Add function description
228 This - TODO: add argument description
229 Attribute - TODO: add argument description
233 TODO: add return values
241 UnixSimpleTextOutClearScreen (
242 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
248 TODO: Add function description
252 This - TODO: add argument description
256 TODO: add return values
264 UnixSimpleTextOutSetCursorPosition (
265 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
273 TODO: Add function description
277 This - TODO: add argument description
278 Column - TODO: add argument description
279 Row - TODO: add argument description
283 TODO: add return values
291 UnixSimpleTextOutEnableCursor (
292 IN EFI_SIMPLE_TEXT_OUT_PROTOCOL
*This
,
299 TODO: Add function description
303 This - TODO: add argument description
304 Enable - TODO: add argument description
308 TODO: add return values
315 // Simple Text Out constructor and destructor.
318 UnixSimpleTextOutOpenWindow (
319 IN OUT UNIX_SIMPLE_TEXT_PRIVATE_DATA
*Private
325 TODO: Add function description
329 Private - TODO: add argument description
333 TODO: add return values
339 UnixSimpleTextOutCloseWindow (
340 IN OUT UNIX_SIMPLE_TEXT_PRIVATE_DATA
*Console
346 TODO: Add function description
350 Console - TODO: add argument description
354 TODO: add return values
361 // Simple Text In protocol member functions.
366 UnixSimpleTextInReset (
367 IN EFI_SIMPLE_TEXT_IN_PROTOCOL
*This
,
368 IN BOOLEAN ExtendedVerification
374 TODO: Add function description
378 This - TODO: add argument description
379 ExtendedVerification - TODO: add argument description
383 TODO: add return values
391 UnixSimpleTextInReadKeyStroke (
392 IN EFI_SIMPLE_TEXT_IN_PROTOCOL
*This
,
393 OUT EFI_INPUT_KEY
*Key
399 TODO: Add function description
403 This - TODO: add argument description
404 Key - TODO: add argument description
408 TODO: add return values
416 UnixSimpleTextInWaitForKey (
424 TODO: Add function description
428 Event - TODO: add argument description
429 Context - TODO: add argument description
433 TODO: add return values
440 // Simple Text In constructor
443 UnixSimpleTextInAttachToWindow (
444 IN UNIX_SIMPLE_TEXT_PRIVATE_DATA
*Private
450 TODO: Add function description
454 Private - TODO: add argument description
458 TODO: add return values
468 InitializeUnixConsole (
469 IN EFI_HANDLE ImageHandle
,
470 IN EFI_SYSTEM_TABLE
*SystemTable
476 TODO: Add function description
480 ImageHandle - TODO: add argument description
481 SystemTable - TODO: add argument description
485 TODO: add return values
491 AppendDevicePathInstanceToVar (
492 IN CHAR16
*VariableName
,
493 IN EFI_DEVICE_PATH_PROTOCOL
*DevicePathInstance
499 TODO: Add function description
503 VariableName - TODO: add argument description
504 DevicePathInstance - TODO: add argument description
508 TODO: add return values