Mercurial > pidgin.yaz
comparison src/sound.c @ 3319:3a05fcb133c4
[gaim-migrate @ 3337]
No UI for this (yet)... but plugins can use it.
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Sun, 16 Jun 2002 20:03:31 +0000 |
parents | 7b867d79da96 |
children | 03daf01a8000 |
comparison
equal
deleted
inserted
replaced
3318:26311f474ef7 | 3319:3a05fcb133c4 |
---|---|
50 #include "sounds/BuddyLeave.h" | 50 #include "sounds/BuddyLeave.h" |
51 #include "sounds/Send.h" | 51 #include "sounds/Send.h" |
52 #include "sounds/Receive.h" | 52 #include "sounds/Receive.h" |
53 #include "sounds/RedAlert.h" | 53 #include "sounds/RedAlert.h" |
54 | 54 |
55 | |
56 gboolean mute_sounds = 0; | |
57 | |
55 /* label and opt are null for the buddy pounce because it's configured * | 58 /* label and opt are null for the buddy pounce because it's configured * |
56 * per pounce. NULL option means it doesn't get displayed in the sound * | 59 * per pounce. NULL option means it doesn't get displayed in the sound * |
57 * preferences box */ | 60 * preferences box */ |
58 struct sound_struct sounds[NUM_SOUNDS] = { | 61 struct sound_struct sounds[NUM_SOUNDS] = { |
59 {N_("Buddy logs in"), OPT_SOUND_LOGIN, BuddyArrive, sizeof(BuddyArrive)}, | 62 {N_("Buddy logs in"), OPT_SOUND_LOGIN, BuddyArrive, sizeof(BuddyArrive)}, |
549 | 552 |
550 extern int logins_not_muted; | 553 extern int logins_not_muted; |
551 | 554 |
552 void play_sound(int sound) | 555 void play_sound(int sound) |
553 { | 556 { |
557 | |
558 if (mute_sounds) | |
559 return; | |
560 | |
554 if (awaymessage && !(sound_options & OPT_SOUND_WHEN_AWAY)) | 561 if (awaymessage && !(sound_options & OPT_SOUND_WHEN_AWAY)) |
555 return; | 562 return; |
556 | 563 |
557 if ((sound == SND_BUDDY_ARRIVE) && !logins_not_muted) | 564 if ((sound == SND_BUDDY_ARRIVE) && !logins_not_muted) |
558 return; | 565 return; |