mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-26 23:43:29 +01:00
busy status mutes beeping
This commit is contained in:
parent
a833be730f
commit
44d9f7fe61
@ -21,7 +21,7 @@ extern int store_data(Tox *m, char *path);
|
|||||||
extern FileSender file_senders[MAX_FILES];
|
extern FileSender file_senders[MAX_FILES];
|
||||||
extern ToxicFriend friends[MAX_FRIENDS_NUM];
|
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. */
|
/* Array of chat command names used for tab completion. */
|
||||||
static const uint8_t chat_cmd_list[AC_NUM_CHAT_COMMANDS][MAX_CMDNAME_SIZE] = {
|
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" },
|
{ "/myid" },
|
||||||
{ "/nick" },
|
{ "/nick" },
|
||||||
{ "/note" },
|
{ "/note" },
|
||||||
{ "/q" },
|
|
||||||
{ "/quit" },
|
{ "/quit" },
|
||||||
{ "/savefile" },
|
{ "/savefile" },
|
||||||
{ "/sendfile" },
|
{ "/sendfile" },
|
||||||
|
@ -10,6 +10,8 @@
|
|||||||
#include "toxic_windows.h"
|
#include "toxic_windows.h"
|
||||||
#include "misc_tools.h"
|
#include "misc_tools.h"
|
||||||
|
|
||||||
|
extern ToxWindow *prompt;
|
||||||
|
|
||||||
// XXX: FIX
|
// XXX: FIX
|
||||||
unsigned char *hex_string_to_bin(char hex_string[])
|
unsigned char *hex_string_to_bin(char hex_string[])
|
||||||
{
|
{
|
||||||
@ -154,7 +156,9 @@ void alert_window(ToxWindow *self, int type, bool is_beep)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_beep)
|
StatusBar *stb = prompt->stb;
|
||||||
|
|
||||||
|
if (is_beep && stb->status != TOX_USERSTATUS_BUSY)
|
||||||
beep();
|
beep();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ const uint8_t glob_cmd_list[AC_NUM_GLOB_COMMANDS][MAX_CMDNAME_SIZE] = {
|
|||||||
{ "/myid" },
|
{ "/myid" },
|
||||||
{ "/nick" },
|
{ "/nick" },
|
||||||
{ "/note" },
|
{ "/note" },
|
||||||
{ "/q" },
|
|
||||||
{ "/quit" },
|
{ "/quit" },
|
||||||
{ "/status" },
|
{ "/status" },
|
||||||
};
|
};
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
#define X_OFST 2 /* offset to account for prompt char */
|
#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);
|
ToxWindow new_prompt(void);
|
||||||
void prep_prompt_win(void);
|
void prep_prompt_win(void);
|
||||||
|
Loading…
Reference in New Issue
Block a user