fix glitch with current time marker
authorcompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Tue, 17 Aug 2004 17:30:31 +0000 (17:30 +0000)
committercompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Tue, 17 Aug 2004 17:30:31 +0000 (17:30 +0000)
git-svn-id: http://ltt.polymtl.ca/svn@802 04897980-b3bd-0310-b5e0-8ef037075253

ltt/branches/poly/lttv/modules/gui/controlflow/drawing.c
ltt/branches/poly/lttv/modules/gui/controlflow/eventhooks.c

index b09853d31f1e93a279971cc5514d1843900a00b7..f1ada9e77ba9856280c9b290169e2ad99a393be1 100644 (file)
@@ -468,7 +468,7 @@ void drawing_request_expose(EventsRequest *events_request,
 
   gtk_widget_queue_draw_area ( drawing->drawing_area,
                                x, 0,
-                               width, drawing->height);
+                               width, drawing->drawing_area->allocation.height);
  
 }
 
@@ -601,13 +601,15 @@ expose_event( GtkWidget *widget, GdkEventExpose *event, gpointer user_data )
 
   /* Erase the dotted lines left.. */
   if(widget->allocation.height > drawing->height)
+  {
     gdk_draw_rectangle (widget->window,
       drawing->drawing_area->style->black_gc,
       TRUE,
       event->area.x, drawing->height,
       event->area.width,  // do not overlap
       widget->allocation.height - drawing->height);
-
+g_critical("blah : %u, %u", widget->allocation.height, drawing->height);
+  }
 
   if(ltt_time_compare(time_window.start_time, current_time) <= 0 &&
            ltt_time_compare(window_end, current_time) >= 0)
@@ -637,10 +639,10 @@ expose_event( GtkWidget *widget, GdkEventExpose *event, gpointer user_data )
                         2);
     }
     
-    drawing_draw_line(NULL, widget->window,
+    gdk_draw_line(widget->window,
+                  drawing->dotted_gc,
                   cursor_x, 0,
-                  cursor_x, widget->allocation.height,
-                  drawing->dotted_gc);
+                  cursor_x, widget->allocation.height);
   }
   return FALSE;
 }
@@ -952,9 +954,7 @@ void drawing_clear(Drawing_t *drawing)
   gtk_widget_queue_resize_no_redraw(drawing->drawing_area);
   
   /* ask for the buffer to be redrawn */
-  gtk_widget_queue_draw_area ( drawing->drawing_area,
-                               0, 0,
-                               drawing->width, drawing->height);
+  gtk_widget_queue_draw ( drawing->drawing_area);
 }
 
 
index 5fd3fd11b6b252acd9306280b75d45f78ace5b8a..cdb7e14aad291e9b537c6b6b046dfa41146992bc 100644 (file)
@@ -2778,11 +2778,11 @@ gint update_time_window_hook(void *hook_data, void *call_data)
           drawing->damage_begin+SAFETY, 0,
           drawing->damage_end - drawing->damage_begin,  // do not overlap
           control_flow_data->drawing->height);
-
-      gtk_widget_queue_draw_area (drawing->drawing_area,
-                                0,0,
-                                control_flow_data->drawing->width,
-                                control_flow_data->drawing->height);
+      gtk_widget_queue_draw(drawing->drawing_area);
+      //gtk_widget_queue_draw_area (drawing->drawing_area,
+      //                          0,0,
+      //                          control_flow_data->drawing->width,
+      //                          control_flow_data->drawing->height);
 
       /* Get new data for the rest. */
       drawing_data_request(control_flow_data->drawing,
@@ -2831,10 +2831,11 @@ gint update_time_window_hook(void *hook_data, void *call_data)
           drawing->damage_end - drawing->damage_begin,  // do not overlap
           control_flow_data->drawing->height);
 
-        gtk_widget_queue_draw_area (drawing->drawing_area,
-                                0,0,
-                                control_flow_data->drawing->width,
-                                control_flow_data->drawing->height);
+        gtk_widget_queue_draw(drawing->drawing_area);
+        //gtk_widget_queue_draw_area (drawing->drawing_area,
+        //                        0,0,
+        //                        control_flow_data->drawing->width,
+        //                        control_flow_data->drawing->height);
 
 
         /* Get new data for the rest. */
@@ -2860,10 +2861,11 @@ gint update_time_window_hook(void *hook_data, void *call_data)
             control_flow_data->drawing->width+SAFETY, // do not overlap
             control_flow_data->drawing->height);
 
-          gtk_widget_queue_draw_area (drawing->drawing_area,
-                                0,0,
-                                control_flow_data->drawing->width,
-                                control_flow_data->drawing->height);
+          //gtk_widget_queue_draw_area (drawing->drawing_area,
+          //                      0,0,
+          //                      control_flow_data->drawing->width,
+          //                      control_flow_data->drawing->height);
+          gtk_widget_queue_draw(drawing->drawing_area);
 
           drawing->damage_begin = 0;
           drawing->damage_end = control_flow_data->drawing->width;
@@ -2888,10 +2890,11 @@ gint update_time_window_hook(void *hook_data, void *call_data)
           control_flow_data->drawing->width+SAFETY, // do not overlap
           control_flow_data->drawing->height);
 
-    gtk_widget_queue_draw_area (drawing->drawing_area,
-                                0,0,
-                                control_flow_data->drawing->width,
-                                control_flow_data->drawing->height);
+    //gtk_widget_queue_draw_area (drawing->drawing_area,
+    //                            0,0,
+    //                            control_flow_data->drawing->width,
+    //                            control_flow_data->drawing->height);
+    gtk_widget_queue_draw(drawing->drawing_area);
   
     drawing->damage_begin = 0;
     drawing->damage_end = control_flow_data->drawing->width;
@@ -2955,10 +2958,11 @@ gint redraw_notify(void *hook_data, void *call_data)
                          drawing->height);
   }
 
-  gtk_widget_queue_draw_area(drawing->drawing_area,
-                             0,0,
-                             drawing->width,
-                             drawing->height);
+  gtk_widget_queue_draw(drawing->drawing_area);
+  //gtk_widget_queue_draw_area(drawing->drawing_area,
+  //                           0,0,
+  //                           drawing->width,
+  //                           drawing->height);
   return FALSE;
 
 }
@@ -3060,11 +3064,8 @@ gint update_current_time_hook(void *hook_data, void *call_data)
     lttvwindow_report_time_window(control_flow_data->tab, new_time_window);
     
   }
-  //gtk_widget_queue_draw(control_flow_data->drawing->drawing_area);
-  gtk_widget_queue_draw_area(drawing->drawing_area,
-                             0,0,
-                             drawing->width,
-                             drawing->height);
+  gtk_widget_queue_draw(control_flow_data->drawing->drawing_area);
+                             
   
   return 0;
 }
This page took 0.027552 seconds and 4 git commands to generate.