diff options
-rw-r--r-- | my-evolution/ChangeLog | 6 | ||||
-rw-r--r-- | my-evolution/e-summary-preferences.c | 10 |
2 files changed, 16 insertions, 0 deletions
diff --git a/my-evolution/ChangeLog b/my-evolution/ChangeLog index 0f7af6e894..e02bbbd53b 100644 --- a/my-evolution/ChangeLog +++ b/my-evolution/ChangeLog @@ -1,3 +1,9 @@ +2001-08-17 Iain Holmes <iain@ximian.com> + + * e-summary-preferences.c (weather_all_select_row_cb): Unselect the + row if it isn't a leaf node. + (weather_add_clicked_cb): Return if location == NULL. + 2001-08-15 Iain Holmes <iain@ximian.com> * e-summary.c (e_summary_draw): Use the US format for dates (Yeeech) diff --git a/my-evolution/e-summary-preferences.c b/my-evolution/e-summary-preferences.c index 5cd7099d36..da4f6176f4 100644 --- a/my-evolution/e-summary-preferences.c +++ b/my-evolution/e-summary-preferences.c @@ -917,6 +917,14 @@ weather_all_select_row_cb (GtkCTree *ctree, int column, PropertyData *pd) { + ESummaryWeatherLocation *location; + + location = gtk_ctree_node_get_row_data (GTK_CTREE (pd->weather->all), row); + if (location == NULL) { + gtk_ctree_unselect (ctree, row); + return; + } + gtk_widget_set_sensitive (pd->weather->add, TRUE); pd->weather->selected_node = row; } @@ -965,6 +973,8 @@ weather_add_clicked_cb (GtkButton *button, location = gtk_ctree_node_get_row_data (GTK_CTREE (pd->weather->all), pd->weather->selected_node); + g_return_if_fail (location != NULL); + for (p = pd->summary->preferences->stations; p; p = p->next) { if (strcmp (location->code, p->data) == 0) { return; /* Already have it */ |