changeset 4400:9134017bac3a SDL-1.2

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.
author Ryan C. Gordon <icculus@icculus.org>
date Sun, 24 Jan 2010 20:08:14 +0000
parents ae9c094e9200
children 1a7b62893c9d
files src/audio/pulse/SDL_pulseaudio.c
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/audio/pulse/SDL_pulseaudio.c	Sun Jan 24 17:54:57 2010 +0000
+++ b/src/audio/pulse/SDL_pulseaudio.c	Sun Jan 24 20:08:14 2010 +0000
@@ -497,7 +497,9 @@
 	}
 
 	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);