mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[poincare/matrix_layout] Do not delete on last line
This commit is contained in:
committed by
EmilieNumworks
parent
80858d7c82
commit
7ab5250db9
@@ -100,7 +100,7 @@ void MatrixLayoutNode::deleteBeforeCursor(LayoutCursor * cursor) {
|
||||
int indexOfPointedLayout = indexOfChild(pointedChild);
|
||||
if (columnAtChildIndex(indexOfPointedLayout) == 0) {
|
||||
int rowIndex = rowAtChildIndex(indexOfPointedLayout);
|
||||
if (isRowEmpty(rowIndex) && m_numberOfRows > 2) {
|
||||
if (rowIndex < m_numberOfRows - 1 && isRowEmpty(rowIndex) && m_numberOfRows > 2) {
|
||||
deleteRowAtIndex(rowIndex);
|
||||
assert(indexOfPointedLayout >= 0 && indexOfPointedLayout < m_numberOfColumns*m_numberOfRows);
|
||||
cursor->setLayoutNode(childAtIndex(indexOfPointedLayout));
|
||||
|
||||
Reference in New Issue
Block a user