Added keyboard_entry_redirect() function to keyboard.[ch] which sends

the signal "gui entry redirect" signal. Added possibility to keep the
entry hidden.

/OPER [<nick> [<password>]] - syntax changed. If password isn't given,
it's asked.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1063 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2001-01-04 18:01:51 +00:00 committed by cras
commit 596ef586b2
8 changed files with 105 additions and 21 deletions

View file

@ -24,6 +24,7 @@
static GString *entry;
static int promptlen, permanent_prompt, pos, scrstart, scrpos;
static int prompt_hidden;
static char *prompt;
static void entry_screenpos(void)
@ -54,7 +55,9 @@ static void entry_update(void)
move(LINES-1, promptlen);
for (p = entry->str+scrstart, n = 0; n < len; n++, p++) {
if ((unsigned char) *p >= 32)
if (prompt_hidden)
addch(' ');
else if ((unsigned char) *p >= 32)
addch((unsigned char) *p);
else {
set_color(stdscr, ATTR_REVERSE);
@ -97,6 +100,11 @@ void gui_entry_set_perm_prompt(const char *str)
gui_entry_set_prompt(NULL);
}
void gui_entry_set_hidden(int hidden)
{
prompt_hidden = hidden;
}
void gui_entry_remove_perm_prompt(void)
{
permanent_prompt = FALSE;
@ -248,6 +256,7 @@ void gui_entry_init(void)
pos = scrpos = 0;
prompt = NULL; promptlen = 0;
permanent_prompt = FALSE;
prompt_hidden = FALSE;
}
void gui_entry_deinit(void)