Don't attempt to navigate to a component that doesn't exist
Check for the size of our component list before trying to access it. BUG: 516107 FIXED-IN: 26.04
This commit is contained in:
@@ -571,6 +571,9 @@ void ChatBarMessageContentModel::handleBlockTransition(bool up)
|
|||||||
setFocusRow(insertRow);
|
setFocusRow(insertRow);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (atEdge) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const auto nextRow = currentRow + (up ? -1 : 1);
|
const auto nextRow = currentRow + (up ? -1 : 1);
|
||||||
const auto nextNotText = m_components[nextRow].type != MessageComponentType::Text;
|
const auto nextNotText = m_components[nextRow].type != MessageComponentType::Text;
|
||||||
|
|||||||
Reference in New Issue
Block a user