mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
code that's not there cannot be wrong...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4908 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
c567e8312a
commit
15d40ab329
@ -48,22 +48,7 @@ void MathAtom::operator=(MathAtom const & at)
|
||||
}
|
||||
|
||||
|
||||
void MathAtom::operator=(MathInset * p)
|
||||
{
|
||||
reset(p);
|
||||
}
|
||||
|
||||
|
||||
MathAtom::~MathAtom()
|
||||
{
|
||||
delete nucleus_;
|
||||
}
|
||||
|
||||
|
||||
void MathAtom::reset(MathInset * p)
|
||||
{
|
||||
if (p == nucleus_)
|
||||
return;
|
||||
delete nucleus_;
|
||||
nucleus_ = p;
|
||||
}
|
||||
|
@ -45,10 +45,6 @@ public:
|
||||
~MathAtom();
|
||||
/// assignment invokes nucleus_->clone()
|
||||
void operator=(MathAtom const &);
|
||||
/// change inset under the hood
|
||||
void operator=(MathInset * p);
|
||||
/// change inset under the hood
|
||||
void reset(MathInset * p);
|
||||
/// access to the inset (checked with gprof)
|
||||
MathInset const * nucleus() const { return nucleus_; }
|
||||
MathInset * nucleus() { return nucleus_; }
|
||||
|
@ -506,7 +506,7 @@ bool Parser::parse(MathAtom & at)
|
||||
parse(ar, false, MathInset::UNDECIDED_MODE);
|
||||
if (ar.size() != 1 || ar.front()->getType() == "none") {
|
||||
lyxerr << "unusual contents found: " << ar << endl;
|
||||
at.reset(new MathParInset);
|
||||
at = MathAtom(new MathParInset);
|
||||
if (at->nargs() > 0)
|
||||
at->cell(0) = ar;
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user