aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/keywords1
-rw-r--r--core/keywords.inc3
-rw-r--r--core/parseconfig.inc9
-rw-r--r--core/ui.inc8
4 files changed, 14 insertions, 7 deletions
diff --git a/core/keywords b/core/keywords
index 7cd9ace5..aeafb96d 100644
--- a/core/keywords
+++ b/core/keywords
@@ -5,6 +5,7 @@ append
initrd
config
default
+ui
display
font
implicit
diff --git a/core/keywords.inc b/core/keywords.inc
index f563b9d4..f2940e8a 100644
--- a/core/keywords.inc
+++ b/core/keywords.inc
@@ -50,7 +50,8 @@ keywd_table:
keyword include, pc_opencmd, pc_include
keyword append, pc_append
keyword initrd, pc_filename, InitRD
- keyword default, pc_default
+ keyword default, pc_default, 1
+ keyword ui, pc_default, 2
keyword display, pc_opencmd, get_msg_file
keyword font, pc_opencmd, loadfont
keyword implicit, pc_setint16, AllowImplicit
diff --git a/core/parseconfig.inc b/core/parseconfig.inc
index 55d6fbb0..2fb26fdd 100644
--- a/core/parseconfig.inc
+++ b/core/parseconfig.inc
@@ -18,12 +18,14 @@
section .text
;
-; "default" command
+; "default" or "ui" command, with level (1 = default, 2 = ui)
;
-pc_default: mov di,default_cmd
+pc_default: cmp ax,[DefaultLevel]
+ jb .skip
+ mov di,default_cmd
call getline
mov byte [di-1],0 ; null-terminate
- ret
+.skip: ret
;
; "ontimeout" command
@@ -467,6 +469,7 @@ NoComplete dw 0 ; No label completion on TAB key
AllowImplicit dw 1 ; Allow implicit kernels
AllowOptions dw 1 ; User-specified options allowed
IncludeLevel dw 1 ; Nesting level
+DefaultLevel dw 0 ; The current level of default
SerialPort dw 0 ; Serial port base (or 0 for no serial port)
VKernel db 0 ; Have we seen any "label" statements?
diff --git a/core/ui.inc b/core/ui.inc
index 4f5b1fdc..7f88cda0 100644
--- a/core/ui.inc
+++ b/core/ui.inc
@@ -48,10 +48,12 @@ no_config_file:
; Check whether or not we are supposed to display the boot prompt.
;
check_for_key:
- cmp word [ForcePrompt],0 ; Force prompt?
- jnz enter_command
test byte [KbdFlags],5Bh ; Shift Alt Caps Scroll
- jz auto_boot ; If neither, default boot
+ jnz enter_command
+ cmp word [ForcePrompt],0 ; Force prompt?
+ jz auto_boot
+ cmp word [DefaultLevel],1 ; Active UI statement?
+ ja auto_boot
enter_command:
cmp word [NoEscape],0 ; If NOESCAPE, no prompt,