diff options
Diffstat (limited to 'src/edbox.c')
| -rw-r--r-- | src/edbox.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/src/edbox.c b/src/edbox.c index ff61359..126762a 100644 --- a/src/edbox.c +++ b/src/edbox.c @@ -13,25 +13,19 @@ static char old_len; static char typeover; char edbox_visible = 0; -static char edbox_pos; /* range 0 to EDBOX_SIZE - 1 */ +char edbox_pos; /* range 0 to EDBOX_SIZE - 1 */ char edbox_len; /* idem */ void (*edbox_callback)(void); -static void hide_cursor(void) { +void hide_cursor(void) { edit_box[edbox_pos] &= 0x7f; } -static void show_cursor(void) { +void show_cursor(void) { edit_box[edbox_pos] |= 0x80; } -void edbox_clear(void) { - bzero(edit_box, EDBOX_SIZE + 1); - edbox_pos = edbox_len = 0; - show_cursor(); // not needed? seems it is.. -} - void edbox_show(void) { u16 addr; @@ -291,6 +285,14 @@ void edbox_keystroke(char c) { if(edbox_visible) edbox_show(); } +/* see edboxutl.s for the asm rewrites of these */ +#if 0 +void edbox_clear(void) { + bzero(edit_box, EDBOX_SIZE + 1); + edbox_pos = edbox_len = 0; + show_cursor(); // not needed? seems it is.. +} + void edbox_addchr(char c) { edit_box[edbox_len++] = c; edbox_pos = edbox_len; @@ -307,3 +309,4 @@ void edbox_set(char *contents) { } edbox_pos = edbox_len; } +#endif |
