[xiph-commits] r12468 - trunk/sushivision

xiphmont at svn.xiph.org xiphmont at svn.xiph.org
Wed Feb 14 00:53:02 PST 2007


Author: xiphmont
Date: 2007-02-14 00:53:01 -0800 (Wed, 14 Feb 2007)
New Revision: 12468

Modified:
   trunk/sushivision/slice.c
   trunk/sushivision/slider.c
Log:
Correct a bug where the clicked-on slice was grabbing focus instead of
the slice of the clicked-on thumb (thumbs are not always inside their
own slices)



Modified: trunk/sushivision/slice.c
===================================================================
--- trunk/sushivision/slice.c	2007-02-14 08:26:58 UTC (rev 12467)
+++ trunk/sushivision/slice.c	2007-02-14 08:53:01 UTC (rev 12468)
@@ -81,7 +81,6 @@
   if(event->button == 1)
     slider_button_press(s->slider,s->slicenum,event->x,event->y);
 
-  gtk_widget_grab_focus(GTK_WIDGET(s));
   return TRUE;
 }
 

Modified: trunk/sushivision/slider.c
===================================================================
--- trunk/sushivision/slider.c	2007-02-14 08:26:58 UTC (rev 12467)
+++ trunk/sushivision/slider.c	2007-02-14 08:53:01 UTC (rev 12468)
@@ -656,9 +656,13 @@
     if(sl->thumb_state){
       sl->thumb_grab=1;
       sl->thumb_focus=1;
+      gtk_widget_grab_focus(GTK_WIDGET(sl));
 
       if(sl->callback)sl->callback(sl->callback_data,0);
       slider_motion(s,slicenum,x,y);
+    }else{
+      sl->thumb_grab=0;
+      sl->thumb_focus=0;
     }
   }
   slider_draw(s);



More information about the commits mailing list