[MPlayer-cvslog] r24968 - trunk/libmenu/menu.c

ulion subversion at mplayerhq.hu
Mon Nov 5 03:45:59 CET 2007


Author: ulion
Date: Mon Nov  5 03:45:59 2007
New Revision: 24968

Log:
Warning fixes:
menu.c:303: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:370: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:463: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:537: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:565: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:577: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:597: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type
menu.c:612: warning: passing argument 1 of 'utf8_get_char' from incompatible pointer type



Modified:
   trunk/libmenu/menu.c

Modified: trunk/libmenu/menu.c
==============================================================================
--- trunk/libmenu/menu.c	(original)
+++ trunk/libmenu/menu.c	Mon Nov  5 03:45:59 2007
@@ -300,7 +300,7 @@ static inline int get_height(int c,int h
 static void render_txt(char *txt)
 {
   while (*txt) {
-    int c = utf8_get_char(&txt);
+    int c = utf8_get_char((const char**)&txt);
     render_one_glyph(vo_font, c);
   }
 }
@@ -367,7 +367,7 @@ void menu_draw_text(mp_image_t* mpi,char
   render_txt(txt);
 
   while (*txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     if ((font=vo_font->font[c])>=0 && (x + vo_font->width[c] <= mpi->w) && (y + vo_font->pic_a[font]->h <= mpi->h))
       draw_alpha(vo_font->width[c], vo_font->pic_a[font]->h,
 		 vo_font->pic_b[font]->bmp+vo_font->start[c],
@@ -460,7 +460,7 @@ void menu_draw_text_full(mp_image_t* mpi
   
   // Jump some the beginnig text if needed
   while(sy < ymin && *txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     if(c == '\n' || (warp && ll + vo_font->width[c] > w)) {
       ll = 0;
       sy += vo_font->height + vspace;
@@ -534,7 +534,7 @@ void menu_draw_text_full(mp_image_t* mpi
     }
 
     while(sx < xmax && txt != line_end) {
-      int c=utf8_get_char(&txt);
+      int c=utf8_get_char((const char**)&txt);
       font = vo_font->font[c];
       if(font >= 0) {
  	int cs = (vo_font->pic_a[font]->h - vo_font->height) / 2;
@@ -562,7 +562,7 @@ int menu_text_length(char* txt) {
   int l = 0;
   render_txt(txt);
   while (*txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     l += vo_font->width[c]+vo_font->charspace;
   }
   return l - vo_font->charspace;
@@ -574,7 +574,7 @@ void menu_text_size(char* txt,int max_wi
 
   render_txt(txt);
   while (*txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     if(c == '\n' || (warp && i + vo_font->width[c] >= max_width)) {
       if(*txt)
 	l++;
@@ -594,7 +594,7 @@ int menu_text_num_lines(char* txt, int m
   int l = 1, i = 0;
   render_txt(txt);
   while (*txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     if(c == '\n' || i + vo_font->width[c] > max_width) {
       l++;
       i = 0;
@@ -609,7 +609,7 @@ char* menu_text_get_next_line(char* txt,
   int i = 0;
   render_txt(txt);
   while (*txt) {
-    int c=utf8_get_char(&txt);
+    int c=utf8_get_char((const char**)&txt);
     if(c == '\n') {
       txt++;
       break;



More information about the MPlayer-cvslog mailing list