From f1fac55c2023bb0b99a5111167d98565badf48c5 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Thu, 25 Feb 2021 17:06:05 +0100 Subject: GUI: Factorise force_{peaks,refls}_on This should help avoid them getting out of sync. Again. --- src/gui_peaksearch.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/gui_peaksearch.c') diff --git a/src/gui_peaksearch.c b/src/gui_peaksearch.c index fa63d8fa..37972e72 100644 --- a/src/gui_peaksearch.c +++ b/src/gui_peaksearch.c @@ -448,12 +448,7 @@ gint peaksearch_sig(GtkWidget *widget, struct crystfelproject *proj) if ( proj->peak_params != NULL ) return FALSE; - proj->show_peaks = 1; - crystfel_image_view_set_show_peaks(CRYSTFEL_IMAGE_VIEW(proj->imageview), - proj->show_peaks); - - w = gtk_ui_manager_get_widget(proj->ui, "/ui/mainwindow/view/peaks"); - gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(w), 1); + force_peaks_on(proj); /* Take a copy of the original parameters, for reverting */ proj->original_params = proj->peak_search_params; -- cgit v1.2.3