[MPlayer-cvslog] CVS: main/Gui bitmap.c, 1.12, 1.13 cfg.c, 1.41, 1.42 interface.c, 1.97, 1.98
Diego Biurrun CVS
syncmail at mplayerhq.hu
Wed Dec 15 02:22:26 CET 2004
CVS change done by Diego Biurrun CVS
Update of /cvsroot/mplayer/main/Gui
In directory mail:/var2/tmp/cvs-serv31292/Gui
Modified Files:
bitmap.c cfg.c interface.c
Log Message:
printf --> mp_msg conversion, less verbosity
Index: bitmap.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/bitmap.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- bitmap.c 23 May 2003 17:23:35 -0000 1.12
+++ bitmap.c 15 Dec 2004 01:22:23 -0000 1.13
@@ -4,7 +4,8 @@
#include <png.h>
-#include "../../mp_msg.h"
+#include "../mp_msg.h"
+#include "../help_mp.h"
#include "bitmap.h"
int pngRead( unsigned char * fname,txSample * bf )
@@ -21,7 +22,7 @@
FILE *fp=fopen( fname,"rb" );
if ( !fp )
{
- mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] file read error ( %s ).\n",fname );
+ mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] file read error ( %s )\n",fname );
return 1;
}
@@ -40,13 +41,13 @@
row_p=(png_bytep *)malloc( sizeof( png_bytep ) * bf->Height );
if ( !row_p )
{
- mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] Not enough memory for row buffer.\n" );
+ mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] not enough memory for row buffer\n" );
return 2;
}
bf->Image=(png_bytep)malloc( png_get_rowbytes( png,info ) * bf->Height );
if ( !bf->Image )
{
- mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] Not enough memory for image buffer.\n" );
+ mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[png] not enough memory for image buffer\n" );
return 2;
}
for ( i=0; i < bf->Height; i++ ) row_p[i]=&bf->Image[png_get_rowbytes( png,info ) * i];
@@ -102,7 +103,7 @@
bf->BPP=32;
if ( ( bf->Image=malloc( bf->ImageSize ) ) == NULL )
{
- mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[bitmap] Not enough memory for image.\n" );
+ mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[bitmap] not enough memory for image\n" );
return 1;
}
memset( bf->Image,0,bf->ImageSize );
@@ -173,7 +174,7 @@
if ( fname == NULL ) return -2;
if ( pngRead( fname,bf ) )
{
- mp_dbg( MSGT_GPLAYER,MSGL_FATAL,"[bitmap] Unknown file type ( %s ).\n",fname );
+ mp_dbg( MSGT_GPLAYER,MSGL_FATAL,"[bitmap] unknown file type ( %s )\n",fname );
return -5;
}
if ( bf->BPP < 24 )
@@ -198,7 +199,7 @@
out->ImageSize=(out->Width * out->Height + 7) / 8;
mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[c32to1] imagesize: %d\n",out->ImageSize );
out->Image=(char *)calloc( 1,out->ImageSize );
- if ( out->Image == NULL ) mp_msg( MSGT_GPLAYER,MSGL_STATUS,"[c32to1] Not enough memory for image.\n" );
+ if ( out->Image == NULL ) mp_msg( MSGT_GPLAYER,MSGL_WARN,MSGTR_NotEnoughMemoryC32To1 );
{
int i,b,c=0; unsigned int * buf = NULL; unsigned char tmp = 0; int nothaveshape = 1;
buf=(unsigned int *)in->Image;
@@ -222,7 +223,7 @@
out->ImageSize=out->Width * out->Height * 4;
out->Image=(char *)calloc( 1,out->ImageSize );
mp_dbg( MSGT_GPLAYER,MSGL_DBG2,"[c1to32] imagesize: %d\n",out->ImageSize );
- if ( out->Image == NULL ) mp_msg( MSGT_GPLAYER,MSGL_STATUS,"[c1to32] Not enough memory for image.\n" );
+ if ( out->Image == NULL ) mp_msg( MSGT_GPLAYER,MSGL_WARN,MSGTR_NotEnoughMemoryC1To32 );
{
int i,b,c=0; unsigned int * buf = NULL; unsigned char tmp = 0;
buf=(unsigned int *)out->Image;
Index: cfg.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/cfg.c,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -r1.41 -r1.42
--- cfg.c 30 Jul 2004 15:58:36 -0000 1.41
+++ cfg.c 15 Dec 2004 01:22:23 -0000 1.42
@@ -5,6 +5,7 @@
#include "../config.h"
#include "../mp_msg.h"
+#include "../help_mp.h"
#include "../mplayer.h"
#include "../m_config.h"
#include "../m_option.h"
@@ -212,12 +213,12 @@
#endif
// -- read configuration
- mp_msg( MSGT_GPLAYER,MSGL_STATUS,"[cfg] read config file: %s\n",cfg );
+ mp_msg( MSGT_GPLAYER,MSGL_V,"[cfg] reading config file: %s\n",cfg );
gui_conf=m_config_new();
m_config_register_options( gui_conf,gui_opts );
if ( m_config_parse_config_file( gui_conf,cfg ) < 0 )
{
- mp_msg( MSGT_GPLAYER,MSGL_FATAL,"[cfg] config file read error ...\n" );
+ mp_msg( MSGT_GPLAYER,MSGL_FATAL,MSGTR_ConfigfileError );
// exit( 1 );
}
free( cfg );
@@ -298,7 +299,7 @@
fprintf( f,"%s = \"%s\"\n",gui_opts[i].name, v);
free(v);
} else if((int)v == -1)
- mp_msg(MSGT_GPLAYER,MSGL_WARN,"Unable to save the '%s' option\n", gui_opts[i].name);
+ mp_msg(MSGT_GPLAYER,MSGL_WARN,MSGTR_UnableToSaveOption, gui_opts[i].name);
}
fclose( f );
}
Index: interface.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/interface.c,v
retrieving revision 1.97
retrieving revision 1.98
diff -u -r1.97 -r1.98
--- interface.c 12 Dec 2004 22:24:32 -0000 1.97
+++ interface.c 15 Dec 2004 01:22:23 -0000 1.98
@@ -185,13 +185,13 @@
// --- load skin
skinDirInHome=get_path("Skin");
skinMPlayerDir=MPLAYER_DATADIR "/Skin";
- printf("SKIN dir 1: '%s'\n",skinDirInHome);
- printf("SKIN dir 2: '%s'\n",skinMPlayerDir);
+ mp_msg( MSGT_GPLAYER,MSGL_V,"SKIN dir 1: '%s'\n",skinDirInHome);
+ mp_msg( MSGT_GPLAYER,MSGL_V,"SKIN dir 2: '%s'\n",skinMPlayerDir);
if ( !skinName ) skinName=strdup( "default" );
i = skinRead( skinName );
if ((i == -1) && strcmp(skinName,"default"))
{
- mp_msg( MSGT_GPLAYER,MSGL_INFO,"Selected skin ( %s ) not found, trying 'default'...\n", skinName);
+ mp_msg( MSGT_GPLAYER,MSGL_WARN,MSGTR_SKIN_SKINCFG_SelectedSkinNotFound, skinName);
skinName=strdup( "default" );
i = skinRead( skinName );
}
@@ -246,7 +246,7 @@
wsXDNDMakeAwareness(&appMPlayer.mainWindow);
#ifdef DEBUG
- mp_msg( MSGT_GPLAYER,MSGL_DBG2,"[main] Depth on screen: %d\n",wsDepthOnScreen );
+ mp_msg( MSGT_GPLAYER,MSGL_DBG2,"[main] depth on screen: %d\n",wsDepthOnScreen );
mp_msg( MSGT_GPLAYER,MSGL_DBG2,"[main] parent: 0x%x\n",(int)appMPlayer.mainWindow.WindowID );
mp_msg( MSGT_GPLAYER,MSGL_DBG2,"[main] sub: 0x%x\n",(int)appMPlayer.subWindow.WindowID );
#endif
@@ -340,7 +340,7 @@
void guiDone( void )
{
mplMainRender=0;
- mp_msg( MSGT_GPLAYER,MSGL_V,"[gui] done.\n" );
+ mp_msg( MSGT_GPLAYER,MSGL_V,"[GUI] done.\n" );
if ( gui_save_pos )
{
@@ -430,7 +430,7 @@
}
if ( subdata )
{
- mp_msg( MSGT_GPLAYER,MSGL_INFO,"[gui] Delete subtitles.\n" );
+ mp_msg( MSGT_GPLAYER,MSGL_INFO,MSGTR_DeletingSubtitles );
sub_free( subdata );
subdata=NULL;
vo_sub=NULL;
@@ -453,7 +453,7 @@
}
if ( name )
{
- mp_msg( MSGT_GPLAYER,MSGL_INFO,"[gui] Load subtitle: %s\n",name );
+ mp_msg( MSGT_GPLAYER,MSGL_INFO,MSGTR_LoadingSubtitles,name );
subdata=sub_read_file( gstrdup( name ), guiIntfStruct.FPS );
if ( !subdata ) mp_msg( MSGT_GPLAYER,MSGL_ERR,MSGTR_CantLoadSub,name );
sub_name = (malloc(2 * sizeof(char*))); //when mplayer will be restarted
@@ -467,7 +467,7 @@
static void add_vop( char * str )
{
- mp_msg( MSGT_GPLAYER,MSGL_STATUS,"[gui] add video filter: %s\n",str );
+ mp_msg( MSGT_GPLAYER,MSGL_STATUS,MSGTR_AddingVideoFilter,str );
if ( vo_plugin_args )
{
int i = 0;
@@ -483,7 +483,7 @@
if ( !vo_plugin_args ) return;
- mp_msg( MSGT_GPLAYER,MSGL_STATUS,"[gui] remove video filter: %s\n",str );
+ mp_msg( MSGT_GPLAYER,MSGL_STATUS,MSGTR_RemovingVideoFilter,str );
while ( vo_plugin_args[n++].name ); n--;
if ( n > -1 )
More information about the MPlayer-cvslog
mailing list