ReactOS 0.4.15-dev-7834-g00c4b3d
SimpleTextInEx.h File Reference
#include <SimpleTextIn.h>
Include dependency graph for SimpleTextInEx.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _EFI_KEY_STATE
 
struct  EFI_KEY_DATA
 
struct  _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL
 

Macros

#define EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL_GUID    {0xdd9e7534, 0x7762, 0x4698, { 0x8c, 0x14, 0xf5, 0x85, 0x17, 0xa6, 0x25, 0xaa } }
 
#define EFI_SHIFT_STATE_VALID   0x80000000
 
#define EFI_RIGHT_SHIFT_PRESSED   0x00000001
 
#define EFI_LEFT_SHIFT_PRESSED   0x00000002
 
#define EFI_RIGHT_CONTROL_PRESSED   0x00000004
 
#define EFI_LEFT_CONTROL_PRESSED   0x00000008
 
#define EFI_RIGHT_ALT_PRESSED   0x00000010
 
#define EFI_LEFT_ALT_PRESSED   0x00000020
 
#define EFI_RIGHT_LOGO_PRESSED   0x00000040
 
#define EFI_LEFT_LOGO_PRESSED   0x00000080
 
#define EFI_MENU_KEY_PRESSED   0x00000100
 
#define EFI_SYS_REQ_PRESSED   0x00000200
 
#define EFI_TOGGLE_STATE_VALID   0x80
 
#define EFI_KEY_STATE_EXPOSED   0x40
 
#define EFI_SCROLL_LOCK_ACTIVE   0x01
 
#define EFI_NUM_LOCK_ACTIVE   0x02
 
#define EFI_CAPS_LOCK_ACTIVE   0x04
 
#define SCAN_F11   0x0015
 
#define SCAN_F12   0x0016
 
#define SCAN_PAUSE   0x0048
 
#define SCAN_F13   0x0068
 
#define SCAN_F14   0x0069
 
#define SCAN_F15   0x006A
 
#define SCAN_F16   0x006B
 
#define SCAN_F17   0x006C
 
#define SCAN_F18   0x006D
 
#define SCAN_F19   0x006E
 
#define SCAN_F20   0x006F
 
#define SCAN_F21   0x0070
 
#define SCAN_F22   0x0071
 
#define SCAN_F23   0x0072
 
#define SCAN_F24   0x0073
 
#define SCAN_MUTE   0x007F
 
#define SCAN_VOLUME_UP   0x0080
 
#define SCAN_VOLUME_DOWN   0x0081
 
#define SCAN_BRIGHTNESS_UP   0x0100
 
#define SCAN_BRIGHTNESS_DOWN   0x0101
 
#define SCAN_SUSPEND   0x0102
 
#define SCAN_HIBERNATE   0x0103
 
#define SCAN_TOGGLE_DISPLAY   0x0104
 
#define SCAN_RECOVERY   0x0105
 
#define SCAN_EJECT   0x0106
 

Typedefs

typedef struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL
 
typedef EFI_STATUS(EFIAPIEFI_INPUT_RESET_EX) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN BOOLEAN ExtendedVerification)
 
typedef UINT8 EFI_KEY_TOGGLE_STATE
 
typedef struct _EFI_KEY_STATE EFI_KEY_STATE
 
typedef EFI_STATUS(EFIAPIEFI_INPUT_READ_KEY_EX) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, OUT EFI_KEY_DATA *KeyData)
 
typedef EFI_STATUS(EFIAPIEFI_SET_STATE) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_KEY_TOGGLE_STATE *KeyToggleState)
 
typedef EFI_STATUS(EFIAPIEFI_KEY_NOTIFY_FUNCTION) (IN EFI_KEY_DATA *KeyData)
 
typedef EFI_STATUS(EFIAPIEFI_REGISTER_KEYSTROKE_NOTIFY) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_KEY_DATA *KeyData, IN EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction, OUT EFI_HANDLE *NotifyHandle)
 
typedef EFI_STATUS(EFIAPIEFI_UNREGISTER_KEYSTROKE_NOTIFY) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_HANDLE NotificationHandle)
 

Variables

EFI_GUID gEfiSimpleTextInputExProtocolGuid
 

Detailed Description

Simple Text Input Ex protocol from the UEFI 2.0 specification.

This protocol defines an extension to the EFI_SIMPLE_TEXT_INPUT_PROTOCOL which exposes much more state and modifier information from the input device, also allows one to register a notification for a particular keystroke.

Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

Definition in file SimpleTextInEx.h.

Macro Definition Documentation

◆ EFI_CAPS_LOCK_ACTIVE

#define EFI_CAPS_LOCK_ACTIVE   0x04

Definition at line 123 of file SimpleTextInEx.h.

◆ EFI_KEY_STATE_EXPOSED

#define EFI_KEY_STATE_EXPOSED   0x40

Definition at line 120 of file SimpleTextInEx.h.

◆ EFI_LEFT_ALT_PRESSED

#define EFI_LEFT_ALT_PRESSED   0x00000020

Definition at line 110 of file SimpleTextInEx.h.

◆ EFI_LEFT_CONTROL_PRESSED

#define EFI_LEFT_CONTROL_PRESSED   0x00000008

Definition at line 108 of file SimpleTextInEx.h.

◆ EFI_LEFT_LOGO_PRESSED

#define EFI_LEFT_LOGO_PRESSED   0x00000080

Definition at line 112 of file SimpleTextInEx.h.

◆ EFI_LEFT_SHIFT_PRESSED

#define EFI_LEFT_SHIFT_PRESSED   0x00000002

Definition at line 106 of file SimpleTextInEx.h.

◆ EFI_MENU_KEY_PRESSED

#define EFI_MENU_KEY_PRESSED   0x00000100

Definition at line 113 of file SimpleTextInEx.h.

◆ EFI_NUM_LOCK_ACTIVE

#define EFI_NUM_LOCK_ACTIVE   0x02

Definition at line 122 of file SimpleTextInEx.h.

◆ EFI_RIGHT_ALT_PRESSED

#define EFI_RIGHT_ALT_PRESSED   0x00000010

Definition at line 109 of file SimpleTextInEx.h.

◆ EFI_RIGHT_CONTROL_PRESSED

#define EFI_RIGHT_CONTROL_PRESSED   0x00000004

Definition at line 107 of file SimpleTextInEx.h.

◆ EFI_RIGHT_LOGO_PRESSED

#define EFI_RIGHT_LOGO_PRESSED   0x00000040

Definition at line 111 of file SimpleTextInEx.h.

◆ EFI_RIGHT_SHIFT_PRESSED

#define EFI_RIGHT_SHIFT_PRESSED   0x00000001

Definition at line 105 of file SimpleTextInEx.h.

◆ EFI_SCROLL_LOCK_ACTIVE

#define EFI_SCROLL_LOCK_ACTIVE   0x01

Definition at line 121 of file SimpleTextInEx.h.

◆ EFI_SHIFT_STATE_VALID

#define EFI_SHIFT_STATE_VALID   0x80000000

Definition at line 104 of file SimpleTextInEx.h.

◆ EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL_GUID

#define EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL_GUID    {0xdd9e7534, 0x7762, 0x4698, { 0x8c, 0x14, 0xf5, 0x85, 0x17, 0xa6, 0x25, 0xaa } }

Definition at line 24 of file SimpleTextInEx.h.

◆ EFI_SYS_REQ_PRESSED

#define EFI_SYS_REQ_PRESSED   0x00000200

Definition at line 114 of file SimpleTextInEx.h.

◆ EFI_TOGGLE_STATE_VALID

#define EFI_TOGGLE_STATE_VALID   0x80

Definition at line 119 of file SimpleTextInEx.h.

◆ SCAN_BRIGHTNESS_DOWN

#define SCAN_BRIGHTNESS_DOWN   0x0101

Definition at line 147 of file SimpleTextInEx.h.

◆ SCAN_BRIGHTNESS_UP

#define SCAN_BRIGHTNESS_UP   0x0100

Definition at line 146 of file SimpleTextInEx.h.

◆ SCAN_EJECT

#define SCAN_EJECT   0x0106

Definition at line 152 of file SimpleTextInEx.h.

◆ SCAN_F11

#define SCAN_F11   0x0015

Definition at line 128 of file SimpleTextInEx.h.

◆ SCAN_F12

#define SCAN_F12   0x0016

Definition at line 129 of file SimpleTextInEx.h.

◆ SCAN_F13

#define SCAN_F13   0x0068

Definition at line 131 of file SimpleTextInEx.h.

◆ SCAN_F14

#define SCAN_F14   0x0069

Definition at line 132 of file SimpleTextInEx.h.

◆ SCAN_F15

#define SCAN_F15   0x006A

Definition at line 133 of file SimpleTextInEx.h.

◆ SCAN_F16

#define SCAN_F16   0x006B

Definition at line 134 of file SimpleTextInEx.h.

◆ SCAN_F17

#define SCAN_F17   0x006C

Definition at line 135 of file SimpleTextInEx.h.

◆ SCAN_F18

#define SCAN_F18   0x006D

Definition at line 136 of file SimpleTextInEx.h.

◆ SCAN_F19

#define SCAN_F19   0x006E

Definition at line 137 of file SimpleTextInEx.h.

◆ SCAN_F20

#define SCAN_F20   0x006F

Definition at line 138 of file SimpleTextInEx.h.

◆ SCAN_F21

#define SCAN_F21   0x0070

Definition at line 139 of file SimpleTextInEx.h.

◆ SCAN_F22

#define SCAN_F22   0x0071

Definition at line 140 of file SimpleTextInEx.h.

◆ SCAN_F23

#define SCAN_F23   0x0072

Definition at line 141 of file SimpleTextInEx.h.

◆ SCAN_F24

#define SCAN_F24   0x0073

Definition at line 142 of file SimpleTextInEx.h.

◆ SCAN_HIBERNATE

#define SCAN_HIBERNATE   0x0103

Definition at line 149 of file SimpleTextInEx.h.

◆ SCAN_MUTE

#define SCAN_MUTE   0x007F

Definition at line 143 of file SimpleTextInEx.h.

◆ SCAN_PAUSE

#define SCAN_PAUSE   0x0048

Definition at line 130 of file SimpleTextInEx.h.

◆ SCAN_RECOVERY

#define SCAN_RECOVERY   0x0105

Definition at line 151 of file SimpleTextInEx.h.

◆ SCAN_SUSPEND

#define SCAN_SUSPEND   0x0102

Definition at line 148 of file SimpleTextInEx.h.

◆ SCAN_TOGGLE_DISPLAY

#define SCAN_TOGGLE_DISPLAY   0x0104

Definition at line 150 of file SimpleTextInEx.h.

◆ SCAN_VOLUME_DOWN

#define SCAN_VOLUME_DOWN   0x0081

Definition at line 145 of file SimpleTextInEx.h.

◆ SCAN_VOLUME_UP

#define SCAN_VOLUME_UP   0x0080

Definition at line 144 of file SimpleTextInEx.h.

Typedef Documentation

◆ EFI_INPUT_READ_KEY_EX

typedef EFI_STATUS(EFIAPI * EFI_INPUT_READ_KEY_EX) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, OUT EFI_KEY_DATA *KeyData)

The function reads the next keystroke from the input device. If there is no pending keystroke the function returns EFI_NOT_READY. If there is a pending keystroke, then KeyData.Key.ScanCode is the EFI scan code defined in Error! Reference source not found. The KeyData.Key.UnicodeChar is the actual printable character or is zero if the key does not represent a printable character (control key, function key, etc.). The KeyData.KeyState is shift state for the character reflected in KeyData.Key.UnicodeChar or KeyData.Key.ScanCode . When interpreting the data from this function, it should be noted that if a class of printable characters that are normally adjusted by shift modifiers (e.g. Shift Key + "f" key) would be presented solely as a KeyData.Key.UnicodeChar without the associated shift state. So in the previous example of a Shift Key + "f" key being pressed, the only pertinent data returned would be KeyData.Key.UnicodeChar with the value of "F". This of course would not typically be the case for non-printable characters such as the pressing of the Right Shift Key + F10 key since the corresponding returned data would be reflected both in the KeyData.KeyState.KeyShiftState and KeyData.Key.ScanCode values. UEFI drivers which implement the EFI_SIMPLE_TEXT_INPUT_EX protocol are required to return KeyData.Key and KeyData.KeyState values. These drivers must always return the most current state of KeyData.KeyState.KeyShiftState and KeyData.KeyState.KeyToggleState. It should also be noted that certain input devices may not be able to produce shift or toggle state information, and in those cases the high order bit in the respective Toggle and Shift state fields should not be active.

Parameters
ThisA pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
KeyDataA pointer to a buffer that is filled in with the keystroke state data for the key that was pressed.
Return values
EFI_SUCCESSThe keystroke information was returned.
EFI_NOT_READYThere was no keystroke data available. EFI_DEVICE_ERROR The keystroke information was not returned due to hardware errors.

Definition at line 204 of file SimpleTextInEx.h.

◆ EFI_INPUT_RESET_EX

typedef EFI_STATUS(EFIAPI * EFI_INPUT_RESET_EX) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN BOOLEAN ExtendedVerification)

The Reset() function resets the input device hardware. As part of initialization process, the firmware/device will make a quick but reasonable attempt to verify that the device is functioning. If the ExtendedVerification flag is TRUE the firmware may take an extended amount of time to verify the device is operating on reset. Otherwise the reset operation is to occur as quickly as possible. The hardware verification process is not defined by this specification and is left up to the platform firmware or driver to implement.

Parameters
ThisA pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
ExtendedVerificationIndicates that the driver may perform a more exhaustive verification operation of the device during reset.
Return values
EFI_SUCCESSThe device was reset.
EFI_DEVICE_ERRORThe device is not functioning correctly and could not be reset.

Definition at line 56 of file SimpleTextInEx.h.

◆ EFI_KEY_NOTIFY_FUNCTION

typedef EFI_STATUS(EFIAPI * EFI_KEY_NOTIFY_FUNCTION) (IN EFI_KEY_DATA *KeyData)

The function will be called when the key sequence is typed specified by KeyData.

Definition at line 241 of file SimpleTextInEx.h.

◆ EFI_KEY_STATE

◆ EFI_KEY_TOGGLE_STATE

EFI_KEY_TOGGLE_STATE. The toggle states are defined. They are: EFI_TOGGLE_STATE_VALID, EFI_SCROLL_LOCK_ACTIVE EFI_NUM_LOCK_ACTIVE, EFI_CAPS_LOCK_ACTIVE

Definition at line 68 of file SimpleTextInEx.h.

◆ EFI_REGISTER_KEYSTROKE_NOTIFY

typedef EFI_STATUS(EFIAPI * EFI_REGISTER_KEYSTROKE_NOTIFY) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_KEY_DATA *KeyData, IN EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction, OUT EFI_HANDLE *NotifyHandle)

The RegisterKeystrokeNotify() function registers a function which will be called when a specified keystroke will occur.

Parameters
ThisA pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
KeyDataA pointer to a buffer that is filled in with the keystroke information for the key that was pressed.
KeyNotificationFunctionPoints to the function to be called when the key sequence is typed specified by KeyData.
NotifyHandlePoints to the unique handle assigned to the registered notification.
Return values
EFI_SUCCESSThe device state was set appropriately.
EFI_OUT_OF_RESOURCESUnable to allocate necessary data structures.

Definition at line 272 of file SimpleTextInEx.h.

◆ EFI_SET_STATE

typedef EFI_STATUS(EFIAPI * EFI_SET_STATE) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_KEY_TOGGLE_STATE *KeyToggleState)

The SetState() function allows the input device hardware to have state settings adjusted.

Parameters
ThisA pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
KeyToggleStatePointer to the EFI_KEY_TOGGLE_STATE to set the state for the input device.
Return values
EFI_SUCCESSThe device state was set appropriately.
EFI_DEVICE_ERRORThe device is not functioning correctly and could not have the setting adjusted.
EFI_UNSUPPORTEDThe device does not support the ability to have its state set.

Definition at line 231 of file SimpleTextInEx.h.

◆ EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL

◆ EFI_UNREGISTER_KEYSTROKE_NOTIFY

typedef EFI_STATUS(EFIAPI * EFI_UNREGISTER_KEYSTROKE_NOTIFY) (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This, IN EFI_HANDLE NotificationHandle)

The UnregisterKeystrokeNotify() function removes the notification which was previously registered.

Parameters
ThisA pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
NotificationHandleThe handle of the notification function being unregistered.
Return values
EFI_SUCCESSThe device state was set appropriately.
EFI_INVALID_PARAMETERThe NotificationHandle is invalid.

Definition at line 296 of file SimpleTextInEx.h.

Variable Documentation

◆ gEfiSimpleTextInputExProtocolGuid

EFI_GUID gEfiSimpleTextInputExProtocolGuid
extern