uefi_raw/protocol/hii/
popup.rs1use super::{HiiHandle, StringId};
6use crate::{Guid, Status, guid, newtype_enum};
7
8newtype_enum! {
9 pub enum HiiPopupStyle: u32 => {
11 INFO = 0,
12 WARNING = 1,
13 ERROR = 2,
14 }
15}
16
17newtype_enum! {
18 pub enum HiiPopupType: u32 => {
20 OK = 0,
21 OK_CANCEL = 1,
22 YES_NO = 2,
23 YES_NO_CANCEL = 3,
24 }
25}
26
27newtype_enum! {
28 pub enum HiiPopupSelection: u32 => {
30 OK = 0,
31 CANCEL = 1,
32 YES = 2,
33 NO = 3,
34 }
35}
36
37#[derive(Debug)]
39#[repr(C)]
40pub struct HiiPopupProtocol {
41 pub revision: u64,
42 pub create_popup: unsafe extern "efiapi" fn(
43 this: *const Self,
44 popup_style: HiiPopupStyle,
45 popup_type: HiiPopupType,
46 hii_handle: HiiHandle,
47 message: StringId,
48 user_selection: *mut HiiPopupSelection,
49 ) -> Status,
50}
51
52impl HiiPopupProtocol {
53 pub const GUID: Guid = guid!("4311edc0-6054-46d4-9e40-893ea952fccc");
54 pub const REVISION: u64 = 1;
55}