Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.15.2
-
None
Description
Steps to repoduceļ¼
- Create a qml project, and import QtQuick.Layouts 1.12 module
- Initialize an object StackLayout
- Set 'currentIndex' as -2 or any value less than -1
- Run the project , you will see project crashed.
I have debugged this with source code and found function 'rearrange' of class QQuickStackLayout contains following code which maybe better to change it like '<= -1'.
if (d->currentIndex == -1 || d->currentIndex >= m_cachedItemSizeHints.count()) return;