[MPlayer-cvslog] r33042 - trunk/gui/mplayer/gui_common.c

ib subversion at mplayerhq.hu
Mon Mar 7 21:27:29 CET 2011


Author: ib
Date: Mon Mar  7 21:27:29 2011
New Revision: 33042

Log:
Go without gtk functions.

Normal string function are sufficient to handle item->text,
there is no need to use gtk functions.

Modified:
   trunk/gui/mplayer/gui_common.c

Modified: trunk/gui/mplayer/gui_common.c
==============================================================================
--- trunk/gui/mplayer/gui_common.c	Mon Mar  7 21:15:30 2011	(r33041)
+++ trunk/gui/mplayer/gui_common.c	Mon Mar  7 21:27:29 2011	(r33042)
@@ -18,7 +18,6 @@
  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-#include <gtk/gtk.h>
 #include <stdlib.h>
 #include <stdio.h>
 #include <inttypes.h>
@@ -291,10 +290,10 @@ void Render( wsTWindow * window,wItem * 
            int x;
            unsigned int d;
            char * t = Translate( item->label );
-           if ( g_strcmp0( item->text, t ) != 0 )
+           if ( !item->text || ( strcmp( item->text, t ) != 0 ) )
             {
-             g_free( item->text );
-             item->text = g_strdup( t );
+             free( item->text );
+             item->text = strdup( t );
              item->textwidth = fntTextWidth( item->fontid, t );
              item->starttime = GetTimerMS();
              item->last_x = 0;


More information about the MPlayer-cvslog mailing list