Mercurial > mplayer.hg
changeset 10607:a17ebe817e33
Fixed a long standing issue: if configured a not available (not existing, permission denied, ...) skin, the gui never ever started again. Now it reverts to 'default' if it can't open the selected skin, if 'default' fails too, the gui exits with error.
author | alex |
---|---|
date | Thu, 14 Aug 2003 01:54:27 +0000 |
parents | f9c1b97a71cb |
children | 2cae82f2ab02 |
files | Gui/interface.c |
diffstat | 1 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/Gui/interface.c Thu Aug 14 01:45:16 2003 +0000 +++ b/Gui/interface.c Thu Aug 14 01:54:27 2003 +0000 @@ -186,8 +186,14 @@ printf("SKIN dir 1: '%s'\n",skinDirInHome); printf("SKIN dir 2: '%s'\n",skinMPlayerDir); if ( !skinName ) skinName=strdup( "default" ); - switch ( skinRead( skinName ) ) - { + i = skinRead( skinName ); + if ((i == -1) && strcmp(skinName,"default")) + { + mp_msg( MSGT_GPLAYER,MSGL_INFO,"Selected skin ( %s ) not found, trying 'default'...\n", skinName); + skinName=strdup( "default" ); + i = skinRead( skinName ); + } + switch (i) { case -1: mp_msg( MSGT_GPLAYER,MSGL_ERR,MSGTR_SKIN_SKINCFG_SkinNotFound,skinName ); exit( 0 ); case -2: mp_msg( MSGT_GPLAYER,MSGL_ERR,MSGTR_SKIN_SKINCFG_SkinCfgReadError,skinName ); exit( 0 ); }