From b435d9ac6a77fe80c9c4598fd056e5a436a293bd Mon Sep 17 00:00:00 2001 From: res Date: Fri, 4 Jan 2008 17:45:53 +0000 Subject: [PATCH] Made gecko bindings a bit more chatty in developer mode. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7899 d7cf8633-e32d-0410-b094-e92efae38249 --- cl_gecko.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/cl_gecko.c b/cl_gecko.c index c4a6f7a5..7b7b2d8b 100644 --- a/cl_gecko.c +++ b/cl_gecko.c @@ -38,6 +38,9 @@ static clgecko_t * cl_gecko_findunusedinstance( void ) { return instance; } } + if( developer.integer > 0 ) { + Con_Printf( "cl_gecko_findunusedinstance: out of geckos\n" ); + } return NULL; } @@ -58,6 +61,10 @@ clgecko_t * CL_Gecko_FindBrowser( const char *name ) { } } + if( developer.integer > 0 ) { + Con_Printf( "CL_Gecko_FindBrowser: No browser named '%s'!\n", name ); + } + return NULL; } @@ -135,8 +142,13 @@ clgecko_t * CL_Gecko_CreateBrowser( const char *name ) { if( cl_geckoembedding == NULL ) { char profile_path [MAX_OSPATH]; OSGK_GeckoResult grc; + OSGK_EmbeddingOptions *options; + + if( developer.integer > 0 ) { + Con_Printf( "CL_Gecko_CreateBrowser: setting up gecko embedding\n" ); + } - OSGK_EmbeddingOptions *options = osgk_embedding_options_create(); + options = osgk_embedding_options_create(); osgk_embedding_options_add_search_path( options, "./xulrunner/" ); dpsnprintf (profile_path, sizeof (profile_path), "%s/xulrunner_profile/", fs_gamedir); osgk_embedding_options_set_profile_dir( options, profile_path, 0 ); @@ -146,6 +158,8 @@ clgecko_t * CL_Gecko_CreateBrowser( const char *name ) { if( cl_geckoembedding == NULL ) { Con_Printf( "CL_Gecko_CreateBrowser: Couldn't retrieve gecko embedding object (%.8x)!\n", grc ); return NULL; + } else if( developer.integer > 0 ) { + Con_Printf( "CL_Gecko_CreateBrowser: Embedding set up correctly\n" ); } } -- 2.39.2