Diff of /trunk/src/area_edit.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 321 by harbaum, Thu Dec 17 16:54:18 2009 UTC revision 322 by harbaum, Mon Dec 21 16:13:51 2009 UTC
# Line 95  static gboolean current_tab_is(context_t Line 95  static gboolean current_tab_is(context_t
95      gtk_notebook_get_nth_page(GTK_NOTEBOOK(nb), page_num);      gtk_notebook_get_nth_page(GTK_NOTEBOOK(nb), page_num);
96    const char *name =    const char *name =
97      gtk_notebook_get_tab_label_text(GTK_NOTEBOOK(nb), w);      gtk_notebook_get_tab_label_text(GTK_NOTEBOOK(nb), w);
98    
99    return(strcasecmp(name, _(str)) == 0);    return(strcasecmp(name, _(str)) == 0);
100  }  }
101    
# Line 212  static void map_update(context_t *contex Line 212  static void map_update(context_t *contex
212    
213    /* map is first tab (page 0) */    /* map is first tab (page 0) */
214    if(!forced && !current_tab_is(context, -1, TAB_LABEL_MAP)) {    if(!forced && !current_tab_is(context, -1, TAB_LABEL_MAP)) {
215        printf("schedule map redraw\n");
216      context->map.needs_redraw = TRUE;      context->map.needs_redraw = TRUE;
217      return;      return;
218    }    }
219    
220      printf("do map redraw\n");
221    
222    /* check if the position is invalid */    /* check if the position is invalid */
223    if(isnan(context->min.lat) || isnan(context->min.lon) ||    if(isnan(context->min.lat) || isnan(context->min.lon) ||
# Line 760  gboolean area_edit(area_edit_t *area) { Line 763  gboolean area_edit(area_edit_t *area) {
763                                context.notebook);                                context.notebook);
764    
765  #ifdef ENABLE_OSM_GPS_MAP  #ifdef ENABLE_OSM_GPS_MAP
766    g_signal_connect(G_OBJECT(context.notebook), "switch-page",    g_signal_connect(G_OBJECT(notebook_get_gtk_notebook(context.notebook)),
767                     G_CALLBACK(on_page_switch), &context);                     "switch-page", G_CALLBACK(on_page_switch), &context);
768  #endif  #endif
769    
770    gtk_widget_show_all(context.dialog);    gtk_widget_show_all(context.dialog);

Legend:
Removed from v.321  
changed lines
  Added in v.322