1
0
mirror of https://github.com/Tha14/toxic.git synced 2024-12-23 15:43:24 +01:00

busy status mutes beeping

This commit is contained in:
Jfreegman 2013-12-09 19:25:09 -05:00
parent a833be730f
commit 44d9f7fe61
4 changed files with 8 additions and 6 deletions

View File

@ -21,7 +21,7 @@ extern int store_data(Tox *m, char *path);
extern FileSender file_senders[MAX_FILES];
extern ToxicFriend friends[MAX_FRIENDS_NUM];
#define AC_NUM_CHAT_COMMANDS 18
#define AC_NUM_CHAT_COMMANDS 17
/* Array of chat command names used for tab completion. */
static const uint8_t chat_cmd_list[AC_NUM_CHAT_COMMANDS][MAX_CMDNAME_SIZE] = {
@ -38,7 +38,6 @@ static const uint8_t chat_cmd_list[AC_NUM_CHAT_COMMANDS][MAX_CMDNAME_SIZE] = {
{ "/myid" },
{ "/nick" },
{ "/note" },
{ "/q" },
{ "/quit" },
{ "/savefile" },
{ "/sendfile" },

View File

@ -10,6 +10,8 @@
#include "toxic_windows.h"
#include "misc_tools.h"
extern ToxWindow *prompt;
// XXX: FIX
unsigned char *hex_string_to_bin(char hex_string[])
{
@ -153,8 +155,10 @@ void alert_window(ToxWindow *self, int type, bool is_beep)
self->alert2 = true;
break;
}
if (is_beep)
StatusBar *stb = prompt->stb;
if (is_beep && stb->status != TOX_USERSTATUS_BUSY)
beep();
}

View File

@ -32,7 +32,6 @@ const uint8_t glob_cmd_list[AC_NUM_GLOB_COMMANDS][MAX_CMDNAME_SIZE] = {
{ "/myid" },
{ "/nick" },
{ "/note" },
{ "/q" },
{ "/quit" },
{ "/status" },
};

View File

@ -7,7 +7,7 @@
#define X_OFST 2 /* offset to account for prompt char */
#define AC_NUM_GLOB_COMMANDS 15
#define AC_NUM_GLOB_COMMANDS 14
ToxWindow new_prompt(void);
void prep_prompt_win(void);