Fix bug 4976.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25481 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Richard Heck 2008-07-07 16:48:36 +00:00
parent 12c72ac7fb
commit 89695eb813
2 changed files with 4 additions and 9 deletions

View File

@ -38,8 +38,6 @@ InsetFlex::InsetFlex(Buffer const & buf, string const & layoutName)
{
// again, because now the name is initialized
setLayout(buf.params().documentClassPtr());
packages_ = getLayout().requires();
preamble_ = getLayout().preamble();
}
@ -117,9 +115,10 @@ void InsetFlex::textString(odocstream & os) const
void InsetFlex::validate(LaTeXFeatures & features) const
{
if (!preamble_.empty())
features.addPreambleSnippet(preamble_);
features.require(packages_);
string const preamble = getLayout().preamble();
if (!preamble.empty())
features.addPreambleSnippet(preamble);
features.require(getLayout().requires());
}
} // namespace lyx

View File

@ -58,10 +58,6 @@ private:
///
std::string name_;
///
std::set<std::string> packages_;
///
std::string preamble_;
};