]> git.lyx.org Git - features.git/commitdiff
Fixed problem with deleting last row in a tabular.
authorJürgen Vigna <jug@sad.it>
Mon, 13 Aug 2001 08:14:09 +0000 (08:14 +0000)
committerJürgen Vigna <jug@sad.it>
Mon, 13 Aug 2001 08:14:09 +0000 (08:14 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2493 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/ChangeLog
src/insets/insettabular.C

index 85217b5a9d9eb09ba08a7fdc64f3e78c13eb39a5..a19f05650e9a722aca5c1362e6f4501ea55f130a 100644 (file)
@@ -1,3 +1,8 @@
+2001-08-13  Juergen Vigna  <jug@sad.it>
+
+       * insettabular.C (tabularFeatures): fixed fix where deleting the
+       last row didn't get the right actcell!
+
 2001-08-11  Dekel Tsur  <dekelts@tau.ac.il>
 
        * insettext.C (localDispatch): Change language only when the inset 
index 67cee87f16e91a8d46580dbf151e132db1a89d66..62ab9682b9d335e9061455fcab1bbc6263f45bd7 100644 (file)
@@ -1692,7 +1692,7 @@ void InsetTabular::tabularFeatures(BufferView * bv,
                for(int i = sel_row_start; i <= sel_row_end; ++i) {
                        tabular->DeleteRow(sel_row_start);
                }
-               if ((sel_row_start) > tabular->rows())
+               if (sel_row_start >= tabular->rows())
                        --sel_row_start;
                actcell = tabular->GetCellNumber(sel_row_start, column);
                clearSelection();
@@ -1703,7 +1703,7 @@ void InsetTabular::tabularFeatures(BufferView * bv,
                for(int i = sel_col_start; i <= sel_col_end; ++i) {
                        tabular->DeleteColumn(sel_col_start);
                }
-               if ((sel_col_start+1) > tabular->columns())
+               if (sel_col_start >= tabular->columns())
                        --sel_col_start;
                actcell = tabular->GetCellNumber(row, sel_col_start);
                clearSelection();