# # old_revision [f388ae7c8eb8f7f38f0b5c8fa5e43547bd781925] # # patch "pidgin/gtksound.c" # from [157c658a8c11b9ee9b26b32a6b988f9981d1891b] # to [f727eef65d89d407ebb1d8879befa75bcf7b9137] # ============================================================ --- pidgin/gtksound.c 157c658a8c11b9ee9b26b32a6b988f9981d1891b +++ pidgin/gtksound.c f727eef65d89d407ebb1d8879befa75bcf7b9137 @@ -298,6 +298,9 @@ pidgin_sound_init(void) purple_prefs_add_bool(PIDGIN_PREFS_ROOT "/sound/mute", FALSE); purple_prefs_add_path(PIDGIN_PREFS_ROOT "/sound/command", ""); purple_prefs_add_string(PIDGIN_PREFS_ROOT "/sound/method", "automatic"); +#ifndef USE_GSTREAMER + purple_prefs_add_bool(PIDGIN_PREFS_ROOT "/sound/rhel4migrated", FALSE); +#endif purple_prefs_add_int(PIDGIN_PREFS_ROOT "/sound/volume", 50); #ifdef USE_GSTREAMER @@ -433,6 +436,17 @@ pidgin_sound_play_file(const char *filen return; } +#ifndef USE_GSTREAMER + /* RHEL4 migration code */ + if (!purple_prefs_get_bool(PIDGIN_PREFS_ROOT "/sound/rhel4migrated")) { + purple_prefs_set_bool(PIDGIN_PREFS_ROOT "/sound/rhel4migrated", TRUE); + if(!strcmp(method, "automatic")) { + purple_prefs_set_string(PIDGIN_PREFS_ROOT "/sound/method", "custom"); + purple_prefs_set_path(PIDGIN_PREFS_ROOT "/sound/command", "aplay %s"); + } + } +#endif + #ifndef _WIN32 if (!strcmp(method, "custom")) { const char *sound_cmd;