Mercurial > mplayer.hg
comparison gui/win32/interface.c @ 37092:4eeb8a38a971
Simplify code.
Set guiInfo.AudioChannels in existing if/else statement.
author | ib |
---|---|
date | Wed, 07 May 2014 14:07:12 +0000 |
parents | ec312b34e302 |
children | cdb4677ef147 |
comparison
equal
deleted
inserted
replaced
37091:ec312b34e302 | 37092:4eeb8a38a971 |
---|---|
625 case GUI_SET_AUDIO: | 625 case GUI_SET_AUDIO: |
626 { | 626 { |
627 sh_audio = data; | 627 sh_audio = data; |
628 if (sh_audio) | 628 if (sh_audio) |
629 { | 629 { |
630 guiInfo.AudioChannels = sh_audio->channels; | |
630 ad = sh_audio->ad_driver; | 631 ad = sh_audio->ad_driver; |
631 guiInfo.AudioPassthrough = (gstrcmp(ad->info->short_name, "hwac3") == 0); | 632 guiInfo.AudioPassthrough = (gstrcmp(ad->info->short_name, "hwac3") == 0); |
632 } | 633 } |
633 else | 634 else |
635 { | |
636 guiInfo.AudioChannels = 0; | |
634 guiInfo.AudioPassthrough = FALSE; | 637 guiInfo.AudioPassthrough = FALSE; |
635 guiInfo.AudioChannels = sh_audio ? sh_audio->channels : 0; | 638 } |
636 if (sh_audio && !guiInfo.sh_video) guiInfo.VideoWindow = FALSE; | 639 if (sh_audio && !guiInfo.sh_video) guiInfo.VideoWindow = FALSE; |
637 if(IsWindowVisible(mygui->videowindow) && !guiInfo.VideoWindow) | 640 if(IsWindowVisible(mygui->videowindow) && !guiInfo.VideoWindow) |
638 ShowWindow(mygui->videowindow, SW_HIDE); | 641 ShowWindow(mygui->videowindow, SW_HIDE); |
639 break; | 642 break; |
640 } | 643 } |