summaryrefslogtreecommitdiffstats
path: root/Gui/app.c
diff options
context:
space:
mode:
authorpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-09-07 21:04:14 +0000
committerpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-09-07 21:04:14 +0000
commit83e1eed13d1b566420b416fef2ec044cfd3ba92b (patch)
tree3e809bd0883bc06c7ad94fb8eb59d7732a2894ce /Gui/app.c
parent70c0a8df28688ae933c392fdf0ccecc88c57bd6e (diff)
downloadmpv-83e1eed13d1b566420b416fef2ec044cfd3ba92b.tar.bz2
mpv-83e1eed13d1b566420b416fef2ec044cfd3ba92b.tar.xz
some bug fix, and add decoration item to skin conffile. faszom(C)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1867 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'Gui/app.c')
-rw-r--r--Gui/app.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/Gui/app.c b/Gui/app.c
index 771e861e29..950ead9a83 100644
--- a/Gui/app.c
+++ b/Gui/app.c
@@ -5,20 +5,16 @@
#include "app.h"
#include "../config.h"
-#include "config.h"
#include "error.h"
#include "wm/wskeys.h"
#include "skin/skin.h"
#include "mplayer/mplayer.h"
listItems appMPlayer;
-listItems appTV;
-listItems appRadio;
-//char * appMPlayerDirInHome=NULL;
-//char * appMPlayerDir=NULL;
char * skinDirInHome=NULL;
char * skinMPlayerDir=NULL;
+char * skinName = NULL;
void appClearItem( wItem * item )
{
@@ -71,6 +67,7 @@ void appInitStruct( listItems * item )
memset( item->MenuItems,0,32 * sizeof( wItem ) );
appClearItem( &item->main );
+ item->mainDecoration=0;
appClearItem( &item->sub );
item->sub.Bitmap.Width=384; item->sub.Bitmap.Height=384;
item->sub.width=384; item->sub.height=384;
@@ -104,12 +101,13 @@ void appInit( int argc,char* argv[], char *envp[], void* disp )
skinMPlayerDir=DATADIR "/Skin";
printf("SKIN dir 1: '%s'\n",skinDirInHome);
printf("SKIN dir 2: '%s'\n",skinMPlayerDir);
-
+ if ( !skinName )
+ {
+ if ( ( skinName=(char *)calloc( 1,7 ) ) == NULL ) { dbprintf( 0,"[config] Not enough memory.\n" ); exit( 1 ); }
+ strcpy( skinName,"default" );
+ }
initDebug(NULL); // write messages to stderr
-
- cfgDefaults(); // set skin to "default"
- cfgRead(); // empty function - NOP
- switch ( skinRead( cfgSkin ) )
+ switch ( skinRead( skinName ) )
{
case -1: dbprintf( 0,"[app] skin configfile not found.\n" ); exit( 0 );
case -2: dbprintf( 0,"[app] skin configfile read error.\n" ); exit( 0 );