]> git.lyx.org Git - features.git/blobdiff - src/mathed/MathMacro.cpp
Remove unneccessary uses of dynamic_cast from the code.
[features.git] / src / mathed / MathMacro.cpp
index 6a232716dce29bbd1a8cce64d9e7a257f406c2ee..da398683b029062d5eb66e79c58a5f3803de1c71 100644 (file)
@@ -164,7 +164,7 @@ bool MathMacro::editMode(BufferView const * bv) const {
                        // look if there is no other macro in edit mode above
                        ++i;
                        for (; i != cur.depth(); ++i) {
-                               MathMacro const * macro = dynamic_cast<MathMacro const *>(&cur[i].inset());
+                               MathMacro const * macro = cur[i].asInsetMath()->asMacro();
                                if (macro && macro->displayMode() == DISPLAY_NORMAL)
                                        return false;
                        }