Only restore the last applied style on initialization.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33852 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Richard Heck 2010-03-24 14:34:05 +00:00
parent 559da350f0
commit a02114dcea

View File

@ -248,12 +248,6 @@ void GuiCitation::updateStyle()
vector<CiteStyle>::const_iterator cit =
std::find(styles.begin(), styles.end(), cs.style);
// restore the latest natbib style
if (style_ >= 0 && style_ < citationStyleCO->count())
citationStyleCO->setCurrentIndex(style_);
else
citationStyleCO->setCurrentIndex(0);
if (cit != styles.end()) {
int const i = int(cit - styles.begin());
citationStyleCO->setCurrentIndex(i);
@ -531,6 +525,11 @@ void GuiCitation::init()
fillFields(bi);
fillEntries(bi);
updateControls(bi);
// restore the last used natbib style
if (style_ >= 0 && style_ < citationStyleCO->count())
citationStyleCO->setCurrentIndex(style_);
else
citationStyleCO->setCurrentIndex(0);
}