mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-03 08:28:25 +00:00
Avoid crash when using inset-select-all in tabular
When changing cell idx, it is important to set the pit to a reasonable value.
This commit is contained in:
parent
f97c11f4e9
commit
a69e01d0b4
@ -1904,10 +1904,12 @@ void BufferView::dispatch(FuncRequest const & cmd, DispatchResult & dr)
|
|||||||
// At least one complete cell is selected and inset is a table.
|
// At least one complete cell is selected and inset is a table.
|
||||||
// Select all cells
|
// Select all cells
|
||||||
cur.idx() = 0;
|
cur.idx() = 0;
|
||||||
|
cur.pit() = 0;
|
||||||
cur.pos() = 0;
|
cur.pos() = 0;
|
||||||
cur.resetAnchor();
|
cur.resetAnchor();
|
||||||
cur.selection(true);
|
cur.selection(true);
|
||||||
cur.idx() = cur.lastidx();
|
cur.idx() = cur.lastidx();
|
||||||
|
cur.pit() = cur.lastpit();
|
||||||
cur.pos() = cur.lastpos();
|
cur.pos() = cur.lastpos();
|
||||||
} else {
|
} else {
|
||||||
// select current cell
|
// select current cell
|
||||||
|
Loading…
Reference in New Issue
Block a user