Blob Blame History Raw
--- xzgv-0.9/src/main.c	2009-01-06 21:41:26.000000000 +0100
+++ xzgv-0.9.new/src/main.c	2009-01-06 21:43:42.000000000 +0100
@@ -201,7 +201,7 @@
 /* required prototypes */
 void render_pixmap(int reset_pos);
 void cb_nextprev_tagged_image(int next,int view);
-void idle_xvpic_load(int *entryp);
+gboolean idle_xvpic_load(gpointer data);
 gint pic_win_resized(GtkWidget *widget,GdkEventConfigure *event);
 void cb_scaling_double(void);
 void cb_xscaling_double(void);
@@ -2179,8 +2179,7 @@
 idle_xvpic_lastadjval=gtk_clist_get_vadjustment(GTK_CLIST(clist))->value;
 idle_xvpic_jumped=0;
 entry=0;
-tn_idle_tag=gtk_idle_add((GtkFunction)idle_xvpic_load,&entry);
-
+tn_idle_tag=gtk_idle_add(idle_xvpic_load, &entry);
 /* the "" is a crappy way to disable it, but it's hairy otherwise */
 gtk_statusbar_push(GTK_STATUSBAR(statusbar),tn_id,
                    tn_msgs?"Reading thumbnails...":"");
@@ -2605,7 +2604,7 @@
 }
 
 
-void idle_xvpic_load(int *entryp)
+gint idle_xvpic_load(gpointer data)
 {
 static char buf[1024];
 struct clist_data_tag *datptr;
@@ -2616,12 +2615,13 @@
 static unsigned char xvpic_data[80*60];		/* max thumbnail size */
 float adjval;
 static int prev_scanpos=0;	/* if jumped, saved pos in top-to-bot scan */
+int *entryp = data;
 
 idle_xvpic_called=1;
 
 /* don't do it if it would be a bad time */
 if(idle_xvpic_blocked)
-  return;
+  return TRUE;
 
 /* freeze/thaw actually *cause* flickering for this, rather than
  * preventing it (!), so I've not used those here.
@@ -2729,6 +2729,8 @@
     *entryp=-1;
     }
   }
+  
+  return TRUE;
 }