From 027d1f2751ae1973c9989cb2e7c6eb7eddf05896 Mon Sep 17 00:00:00 2001 From: John Ralls Date: Wed, 20 May 2020 16:50:38 -0700 Subject: [PATCH] Recalculate type-ahead search when deleting. --- gnucash/register/register-gnome/combocell-gnome.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gnucash/register/register-gnome/combocell-gnome.c b/gnucash/register/register-gnome/combocell-gnome.c index 036440f183..bf8a6bb401 100644 --- a/gnucash/register/register-gnome/combocell-gnome.c +++ b/gnucash/register/register-gnome/combocell-gnome.c @@ -620,18 +620,19 @@ gnc_combo_cell_modify_verify (BasicCell* _cell, return; } - // If we were deleting or inserting in the middle, just accept. - if (change == NULL || *cursor_position < _cell->value_chars) - { - gnc_basic_cell_set_value_internal (_cell, newval); - return; - } - /* If item_list is using temp then we're already partly matched by * type-ahead and a quickfill_match won't work. */ if (!gnc_item_list_using_temp (box->item_list)) + { + // If we were deleting or inserting in the middle, just accept. + if (change == NULL || *cursor_position < _cell->value_chars) + { + gnc_basic_cell_set_value_internal (_cell, newval); + return; + } match_str = quickfill_match (box->qf, newval); + } if (match_str != NULL) {