Some cosmetics after r32157.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32159 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2009-11-22 21:45:51 +00:00
parent 3870c6ae40
commit 92c8561674
4 changed files with 12 additions and 11 deletions

View File

@ -2163,9 +2163,9 @@ bool notifyCursorLeavesOrEnters(Cursor const & old, Cursor & cur)
// notify everything on top of the common part in old cursor,
// but stop if the inset claims the cursor to be invalid now
for (size_type j = i; j < old.depth(); ++j) {
Cursor insetPos = old;
insetPos.cutOff(j);
if (old[j].inset().notifyCursorLeaves(insetPos, cur))
Cursor inset_pos = old;
inset_pos.cutOff(j);
if (old[j].inset().notifyCursorLeaves(inset_pos, cur))
return true;
}

View File

@ -457,11 +457,11 @@ void InsetMathHull::initUnicodeMath() const
}
void InsetMathHull::addPreview(DocIterator const & insetPos,
void InsetMathHull::addPreview(DocIterator const & inset_pos,
graphics::PreviewLoader & /*ploader*/) const
{
if (RenderPreview::status() == LyXRC::PREVIEW_ON) {
reloadPreview(insetPos);
reloadPreview(inset_pos);
}
}

View File

@ -132,7 +132,7 @@ public:
///
//bool insetAllowed(InsetCode code) const;
///
void addPreview(DocIterator const & insetPos,
void addPreview(DocIterator const & inset_pos,
graphics::PreviewLoader &) const;
/// Recreate the preview if preview is enabled.
void reloadPreview(DocIterator const & pos) const;

View File

@ -631,9 +631,10 @@ bool MathMacroTemplate::notifyCursorLeaves(Cursor const & old, Cursor & cur)
void MathMacroTemplate::removeArguments(Cursor & cur,
DocIterator const & /*insetPos*/, int from, int to)
DocIterator const & /*inset_pos*/, int from, int to)
{
for (DocIterator it = doc_iterator_begin(&buffer(), this); it; it.forwardChar()) {
DocIterator it = doc_iterator_begin(&buffer(), this);
for (; it; it.forwardChar()) {
if (!it.nextInset())
continue;
if (it.nextInset()->lyxCode() != MATH_MACROARG_CODE)
@ -716,15 +717,15 @@ void MathMacroTemplate::insertMissingArguments(int maxArg)
void MathMacroTemplate::changeArity(Cursor & cur,
DocIterator const & insetPos, int newNumArg)
DocIterator const & inset_pos, int newNumArg)
{
// remove parameter which do not appear anymore in the definition
for (int i = numargs_; i > newNumArg; --i)
removeParameter(cur, insetPos, numargs_ - 1, false);
removeParameter(cur, inset_pos, numargs_ - 1, false);
// add missing parameter
for (int i = numargs_; i < newNumArg; ++i)
insertParameter(cur, insetPos, numargs_, false, false);
insertParameter(cur, inset_pos, numargs_, false, false);
}