From f0e0c4056132b7eb10809cf94e53a90ab605a44e Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 24 Jan 2010 20:08:14 +0000 Subject: [PATCH] PulseAudio: get the window title for the context name if it wasn't set already. Will still fall back to get_progname() if it can't figure out the title. --HG-- branch : SDL-1.2 extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404450 --- src/audio/pulse/SDL_pulseaudio.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/audio/pulse/SDL_pulseaudio.c b/src/audio/pulse/SDL_pulseaudio.c index 98c4a5090..3594612af 100644 --- a/src/audio/pulse/SDL_pulseaudio.c +++ b/src/audio/pulse/SDL_pulseaudio.c @@ -497,7 +497,9 @@ static int PULSE_OpenAudio(_THIS, SDL_AudioSpec *spec) } if (this->hidden->caption == NULL) { - this->hidden->caption = SDL_strdup(get_progname()); + char *title = NULL; + SDL_WM_GetCaption(&title, NULL); + PULSE_SetCaption(this, title); } mainloop_api = SDL_NAME(pa_mainloop_get_api)(mainloop);