aboutsummaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index dac4379..cc302bb 100644
--- a/src/main.c
+++ b/src/main.c
@@ -50,7 +50,7 @@ static gint main_method_window_response(GtkWidget *method_window, gint response,
case 2 : ctx->psmode = PEAKSEARCH_LSQ; break;
case 3 : ctx->psmode = PEAKSEARCH_ZAEFFERER; break;
case 4 : ctx->psmode = PEAKSEARCH_STAT; break;
- default: abort();
+ default: ctx->psmode = PEAKSEARCH_NONE; break; /* This happens when reading from a cache file */
}
gtk_widget_destroy(method_window);
@@ -133,7 +133,9 @@ void main_method_dialog_open(ControlContext *ctx) {
gtk_table_attach_defaults(GTK_TABLE(table), ctx->combo_peaksearch, 2, 3, 2, 3);
if ( ctx->inputfiletype == INPUT_CACHE ) {
+ gtk_combo_box_append_text(GTK_COMBO_BOX(ctx->combo_peaksearch), "Get from cache file");
gtk_widget_set_sensitive(GTK_WIDGET(ctx->combo_peaksearch), FALSE);
+ gtk_combo_box_set_active(GTK_COMBO_BOX(ctx->combo_peaksearch), 5);
}
gtk_box_pack_start(GTK_BOX(vbox), GTK_WIDGET(table), TRUE, TRUE, 5);