]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_atom.C
several smallish changes/bugfixes/left overs from Porto
[lyx.git] / src / mathed / math_atom.C
index 76fc538851833e1c95f916cb8cad07cb1c37b77b..a8e2815a0f146acfd65d18ebd5f2e069f4dfafcb 100644 (file)
@@ -34,20 +34,26 @@ MathAtom::MathAtom(MathInset * p)
 {}
 
 
-MathAtom::MathAtom(MathAtom const & p)
-       : nucleus_(p.nucleus_ ? p.nucleus_->clone() : 0)
+MathAtom::MathAtom(MathAtom const & at)
+       : nucleus_(at.nucleus_ ? at.nucleus_->clone() : 0)
 {}
 
 
-void MathAtom::operator=(MathAtom const & p)
+void MathAtom::operator=(MathAtom const & at)
 {
-       if (&p == this)
+       if (&at == this)
                return;
-       MathAtom tmp(p);
+       MathAtom tmp(at);
        std::swap(tmp.nucleus_, nucleus_);
 }
 
 
+void MathAtom::operator=(MathInset * p)
+{
+       reset(p);
+}
+
+
 MathAtom::~MathAtom()
 {
        delete nucleus_;