fix bug with ever-growing bst files list (from herbert)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4783 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2002-07-25 12:07:26 +00:00
parent a33189175a
commit 1bcef000fb
2 changed files with 11 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2002-07-25 Herbert Voss <voss@perce.de>
* FormBibtex.C (update): clear browser first
2002-07-25 Juergen Vigna <jug@sad.it>
* XWorkArea.C (work_area_handler): set y_old and x_old to some

View File

@ -120,8 +120,13 @@ ButtonPolicy::SMInput FormBibtex::input(FL_OBJECT * ob, long)
fl_get_browser_line(dialog_->browser_styles, selection);
fl_set_input(dialog_->input_style,
ChangeExtension(out_name, string()).c_str());
} else if (ob == dialog_->button_rescan)
} else if (ob == dialog_->button_rescan) {
fl_clear_browser(dialog_->browser_styles);
controller().rescanBibStyles();
string const str =
controller().getBibStyles();
fl_add_browser_line(dialog_->browser_styles, str.c_str());
}
// with an empty database nothing makes sense ...
if (!compare(fl_get_input(dialog_->input_database), "")) {
@ -152,6 +157,7 @@ void FormBibtex::update()
fl_set_button(dialog_->check_bibtotoc,0);
fl_set_input(dialog_->input_style, bibstyle.c_str());
}
fl_clear_browser(dialog_->browser_styles);
string const str =
controller().getBibStyles();
fl_add_browser_line(dialog_->browser_styles, str.c_str());