Mercurial > sdl-ios-xcode
comparison src/audio/pulse/SDL_pulseaudio.c @ 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 | fe15c4e8efe6 |
children |
comparison
equal
deleted
inserted
replaced
4399:ae9c094e9200 | 4400:9134017bac3a |
---|---|
495 SDL_SetError("pa_mainloop_new() failed"); | 495 SDL_SetError("pa_mainloop_new() failed"); |
496 return(-1); | 496 return(-1); |
497 } | 497 } |
498 | 498 |
499 if (this->hidden->caption == NULL) { | 499 if (this->hidden->caption == NULL) { |
500 this->hidden->caption = SDL_strdup(get_progname()); | 500 char *title = NULL; |
501 SDL_WM_GetCaption(&title, NULL); | |
502 PULSE_SetCaption(this, title); | |
501 } | 503 } |
502 | 504 |
503 mainloop_api = SDL_NAME(pa_mainloop_get_api)(mainloop); | 505 mainloop_api = SDL_NAME(pa_mainloop_get_api)(mainloop); |
504 if (!(context = SDL_NAME(pa_context_new)(mainloop_api, | 506 if (!(context = SDL_NAME(pa_context_new)(mainloop_api, |
505 this->hidden->caption))) { | 507 this->hidden->caption))) { |