Mercurial > pidgin.yaz
annotate src/sound.c @ 6122:914f2d5da21c
[gaim-migrate @ 6596]
Fix 2 compiler warnings.
Make auto-login for IRC accounts without passwords work. Thanks to Luke for
finding this and making a kick-assingly correct guess as to the cause.
Fix the MSN sign-off-infinite-loops-after-getting-info-about-mail bug.
Fix "Yahoo smilies for the "angel" smiley are incorrect"
http://sourceforge.net/tracker/index.php?func=detail&aid=728663&group_id=235&atid=100235
Fix a bug that I introduced yesterday freaking afternoon. I would have
commited the fix yesterday, but SF CVS was not working.
<faceprint> KingAnt: you just broke the ticker
<KingAnt> faceprint: How so?
<KingAnt> Oh, event_signon?
<faceprint> the ticker is what needs event_buddy_signon to get called twice
<faceprint> i don't know what is the right behavior, but i'm in bootloader hell,
just thought i'd alert you
<KingAnt> faceprint: So that it doesn't always show people with the open door?
<faceprint> KingAnt: right
I just added an ugly little timeout that updates the icon after 11 seconds.
The icon in the blist gets updated after 10.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 14 Jul 2003 22:09:42 +0000 |
parents | 059d95c67cda |
children | 8f94cce8faa5 |
rev | line source |
---|---|
1 | 1 /* |
2 * gaim | |
3 * | |
4561 | 4 * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com> |
1 | 5 * |
6 * This program is free software; you can redistribute it and/or modify | |
7 * it under the terms of the GNU General Public License as published by | |
8 * the Free Software Foundation; either version 2 of the License, or | |
9 * (at your option) any later version. | |
10 * | |
11 * This program is distributed in the hope that it will be useful, | |
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 * GNU General Public License for more details. | |
15 * | |
16 * You should have received a copy of the GNU General Public License | |
17 * along with this program; if not, write to the Free Software | |
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
19 * | |
20 */ | |
5872
059d95c67cda
[gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
5684
diff
changeset
|
21 #include "internal.h" |
3630 | 22 |
4561 | 23 #include "sound.h" |
5545
7a64114641c3
[gaim-migrate @ 5946]
Christian Hammond <chipx86@chipx86.com>
parents:
5436
diff
changeset
|
24 #include "prefs.h" |
1 | 25 |
5872
059d95c67cda
[gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
5684
diff
changeset
|
26 /* XXX: this goes away when away messages become sane */ |
059d95c67cda
[gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
5684
diff
changeset
|
27 #include "ui.h" |
059d95c67cda
[gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
5684
diff
changeset
|
28 |
4019
e53d9f9969d0
[gaim-migrate @ 4219]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4014
diff
changeset
|
29 |
5684 | 30 static GaimSoundUiOps *sound_ui_ops = NULL; |
3319 | 31 |
5684 | 32 void gaim_set_sound_ui_ops(GaimSoundUiOps *ops) |
4430 | 33 { |
5684 | 34 if(sound_ui_ops && sound_ui_ops->shutdown) |
35 sound_ui_ops->shutdown(); | |
36 sound_ui_ops = ops; | |
37 if(sound_ui_ops && sound_ui_ops->init) | |
38 sound_ui_ops->init(); | |
4430 | 39 } |
40 | |
5684 | 41 GaimSoundUiOps *gaim_get_sound_ui_ops(void) |
4430 | 42 { |
5684 | 43 return sound_ui_ops; |
4581 | 44 } |
45 | |
5684 | 46 void gaim_sound_init() |
47 { | |
48 gaim_prefs_add_none("/core/sound"); | |
49 gaim_prefs_add_bool("/core/sound/while_away", FALSE); | |
50 } | |
4581 | 51 |
5684 | 52 void gaim_sound_shutdown() |
4430 | 53 { |
5684 | 54 if(sound_ui_ops && sound_ui_ops->shutdown) |
55 sound_ui_ops->shutdown(); | |
56 } | |
4430 | 57 |
5684 | 58 void gaim_sound_play_file(const char *filename) |
59 { | |
60 if(awaymessage && !gaim_prefs_get_bool("/core/sound/while_away")) | |
4561 | 61 return; |
4430 | 62 |
5684 | 63 if(sound_ui_ops && sound_ui_ops->play_file) |
64 sound_ui_ops->play_file(filename); | |
1006
0a4d0ed65e17
[gaim-migrate @ 1016]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
899
diff
changeset
|
65 } |
0a4d0ed65e17
[gaim-migrate @ 1016]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
899
diff
changeset
|
66 |
4561 | 67 void gaim_sound_play_event(GaimSoundEventID event) |
1 | 68 { |
5684 | 69 if(awaymessage && !gaim_prefs_get_bool("/core/sound/while_away")) |
4561 | 70 return; |
71 | |
5684 | 72 if(sound_ui_ops && sound_ui_ops->play_event) |
73 sound_ui_ops->play_event(event); | |
4561 | 74 } |