From: André Pönitz Date: Wed, 25 Jul 2001 09:32:38 +0000 (+0000) Subject: tiny cleanup X-Git-Tag: 1.6.10~21006 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=e152ea21dc4ecd20b204079a8cd5e9cf5d9f4818;p=features.git tiny cleanup git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2336 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/mathed/formulabase.C b/src/mathed/formulabase.C index 946541d850..baed9845a6 100644 --- a/src/mathed/formulabase.C +++ b/src/mathed/formulabase.C @@ -664,6 +664,7 @@ InsetFormulaBase::localDispatch(BufferView * bv, kb_action action, } case LFUN_PROTECTEDSPACE: + //lyxerr << " called LFUN_PROTECTEDSPACE\n"; bv->lockedInsetStoreUndo(Undo::INSERT); mathcursor->insert(new MathSpaceInset(1)); updateLocal(bv, true); diff --git a/src/mathed/math_cursor.C b/src/mathed/math_cursor.C index ecbe5c645f..bba13ac2e4 100644 --- a/src/mathed/math_cursor.C +++ b/src/mathed/math_cursor.C @@ -233,7 +233,7 @@ bool MathCursor::openable(MathInset * p, bool sel, bool useupdown) const return false; if (sel) { - // we can't move into everything during selection + // we can't move into anything new during selection if (Cursor_.size() == Anchor_.size()) return false; if (p != Anchor_[Cursor_.size()].par_) @@ -503,7 +503,7 @@ bool MathCursor::Up(bool sel) if (selection) { int x = xarray().pos2x(cursor().pos_); - if (cursor().par_->idxUp(cursor().idx_, cursor().pos_)) { + if (cursor().idxDown()) { cursor().pos_ = xarray().x2pos(x); return true; } @@ -518,7 +518,6 @@ bool MathCursor::Up(bool sel) int idx, pos; if (p->idxFirstUp(idx, pos)) { push(p, true); - cursor().par_ = p; cursor().idx_ = idx; cursor().pos_ = pos; dump("Up 3"); @@ -532,7 +531,6 @@ bool MathCursor::Up(bool sel) if (p->idxLastUp(idx, pos)) { plainLeft(); push(p, false); - cursor().par_ = p; cursor().idx_ = idx; cursor().pos_ = pos; dump("Up 4"); @@ -595,7 +593,7 @@ bool MathCursor::Down(bool sel) } int x = xarray().pos2x(cursor().pos_); - if (cursor().par_->idxDown(cursor().idx_, cursor().pos_)) { + if (cursor().idxDown()) { cursor().pos_ = xarray().x2pos(x); return true; }