diff --git a/src/frontends/xforms/ChangeLog b/src/frontends/xforms/ChangeLog index 19e2f9ab32..91f207901a 100644 --- a/src/frontends/xforms/ChangeLog +++ b/src/frontends/xforms/ChangeLog @@ -1,3 +1,8 @@ +2001-07-29 Asger Alstrup Nielsen + + * FormToc.C (updateType): Fix problem with TOC that couldn't be + updated because the type list was not updated. + 2001-07-26 Angus Leeming * forms/form_aboutlyx.fd: made a bit bigger to get the Copyright & diff --git a/src/frontends/xforms/FormToc.C b/src/frontends/xforms/FormToc.C index 8691bfa3b2..b9d0a11745 100644 --- a/src/frontends/xforms/FormToc.C +++ b/src/frontends/xforms/FormToc.C @@ -71,6 +71,13 @@ ButtonPolicy::SMInput FormToc::input(FL_OBJECT *, long) void FormToc::updateType() { + // Update the choice list from scratch + fl_clear_choice(dialog_->choice_toc_type); + string const choice = + " " + getStringFromVector(controller().getTypes(), " | ") + " "; + fl_addto_choice(dialog_->choice_toc_type, choice.c_str()); + + // And select the correct one string const type = toc::getType(controller().params().getCmdName()); fl_set_choice(dialog_->choice_toc_type, 1);