mirror of
https://github.com/yourtion/30dayMakeOS.git
synced 2026-02-02 17:49:01 +08:00
增加更多的命令行窗口
This commit is contained in:
@@ -21,7 +21,7 @@ void HariMain(void)
|
||||
struct MOUSE_DEC mdec;
|
||||
struct MEMMAN *memman = (struct MEMMAN *) MEMMAN_ADDR;
|
||||
unsigned char *buf_back, buf_mouse[256], *buf_cons[2];
|
||||
struct SHEET *sht_back, *sht_mouse, *sht_cons[2];
|
||||
struct SHEET *sht_back, *sht_mouse;
|
||||
struct TASK *task_a, *task_cons[2], *task;
|
||||
static char keytable0[0x80] = {
|
||||
0, 0, '1', '2', '3', '4', '5', '6', '7', '8', '9', '0', '-', '^', 0x08, 0,
|
||||
@@ -77,8 +77,7 @@ void HariMain(void)
|
||||
init_screen8(buf_back, binfo->scrnx, binfo->scrny);
|
||||
|
||||
/* sht_cons */
|
||||
sht_cons[0] = open_console(shtctl, memtotal);
|
||||
sht_cons[1] = 0;
|
||||
key_win = open_console(shtctl, memtotal);
|
||||
|
||||
/* sht_mouse */
|
||||
sht_mouse = sheet_alloc(shtctl);
|
||||
@@ -88,12 +87,11 @@ void HariMain(void)
|
||||
my = (binfo->scrny - 28 - 16) / 2;
|
||||
|
||||
sheet_slide(sht_back, 0, 0);
|
||||
sheet_slide(sht_cons[0], 32, 4);
|
||||
sheet_slide(key_win, 32, 4);
|
||||
sheet_slide(sht_mouse, mx, my);
|
||||
sheet_updown(sht_back, 0);
|
||||
sheet_updown(sht_cons[0], 1);
|
||||
sheet_updown(key_win, 1);
|
||||
sheet_updown(sht_mouse, 2);
|
||||
key_win = sht_cons[0];
|
||||
keywin_on(key_win);
|
||||
|
||||
/*为了避免和键盘当前状态冲突,在一开始先进行设置*/
|
||||
@@ -194,13 +192,11 @@ void HariMain(void)
|
||||
io_sti();
|
||||
}
|
||||
}
|
||||
if (i == 256 + 0x3c && key_shift != 0 && sht_cons[1] == 0) { /* Shift+F2 */
|
||||
sht_cons[1] = open_console(shtctl, memtotal);
|
||||
sheet_slide(sht_cons[1], 32, 4);
|
||||
sheet_updown(sht_cons[1], shtctl->top);
|
||||
/*自动将输入焦点切换到新打开的命令行窗口(这样比较方便吧?) */
|
||||
if (i == 256 + 0x3c && key_shift != 0 ) { /* Shift+F2 */
|
||||
keywin_off(key_win);
|
||||
key_win = sht_cons[1];
|
||||
key_win = open_console(shtctl, memtotal);
|
||||
sheet_slide(key_win, 32, 4);
|
||||
sheet_updown(key_win, shtctl->top);
|
||||
keywin_on(key_win);
|
||||
}
|
||||
if (i == 256 + 0x57) { /* F11 */
|
||||
|
||||
Reference in New Issue
Block a user