hum... with the patch this time

Abdelrazak Younes a écrit :
I am going to commit this soon unless I hear objection.

Abdel.

Log:
* text3.C:void LyXText::dispatch(LCursor & cur, FuncRequest & cmd)
  For LFUN_PARAGRAPH_MOVE_DOWN and LFUN_PARAGRAPH_MOVE_UP call:
    void updateLabels(Buffer const & buf,
        ParIterator & from, ParIterator & to)
  instead of:
    void updateLabels(Buffer const & buf,
        ParIterator & iter)



Index: text3.C
===================================================================
--- text3.C     (revision 13773)
+++ text3.C     (working copy)
@@ -327,11 +327,12 @@
                recUndo(pit, pit + 1);
                finishUndo();
                std::swap(pars_[pit], pars_[pit + 1]);
+
+               ParIterator begin(cur);
                ++cur.pit();
+               ParIterator end(cur); ++end;
+               updateLabels(cur.buffer(), begin, end);
 
-               ParIterator parit(cur);
-               updateLabels(cur.buffer(), parit);
-
                needsUpdate = true;
                break;
        }
@@ -341,11 +342,12 @@
                recUndo(pit - 1, pit);
                finishUndo();
                std::swap(pars_[pit], pars_[pit - 1]);
+
+               ParIterator end(cur); ++end;
                --cur.pit();
+               ParIterator begin(cur);
+               updateLabels(cur.buffer(), begin, end);
 
-               ParIterator parit(cur);
-               updateLabels(cur.buffer(), parit);
-
                needsUpdate = true;
                break;
        }

Reply via email to