Date
1 - 2 of 2
回复: [edk2-discuss] Refresh currently displayed form
gaoliming
VFR question has attribute refresh interval (Refresh interval in seconds). It will trig call back regularly.
toggle quoted message
Show quoted text
There is one example is in edk2\MdeModulePkg\Universal\DriverSampleDxe\Vfr.vfr You can add the logic in this question callback function to refresh the boot option. If so, the boot option can be updated. Thanks Liming -----邮件原件----- |
|
Tim Crawford
BootManager elements are generated dynamically. There are no questions or actions to attach a refresh interval or refreshguid to. I don't believe a refresh interval would produce the behavior I want; that is, to update *as soon as* an event (plugging/pulling a USB drive) happens.
But after looking at ANTLR syntax (BaseTools/Source/C/VfrCompile/VfrSyntax.g) I found that refreshguid can be used at the form level. This was added some time ago [1], but is not in the VFR specification [2]. Using this with CreateEventEx(), with refreshguid and EventGroup being the same GUID, produces the behavior I want. [1] https://github.com/tianocore/edk2/commit/e2a5feb9d6c468c0ddb0caed2581d10585819db5 [2] https://edk2-docs.gitbook.io/edk-ii-vfr-specification/2_vfr_description_in_bnf/211_vfr_form_definition Thanks, Tim |
|