forked from qt-creator/qt-creator
Timeline: Emit heightChanged() when empty changes
The height of a model is 0 if the model is empty. Thus, when clearing we have to emit heightChanged(). Change-Id: I6f05c2a32cff648d6aa8e623e17aebe9ae4fcb5c Task-number: QTCREATORBUG-14507 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
This commit is contained in:
@@ -586,8 +586,10 @@ void TimelineModel::clear()
|
|||||||
d->endTimes.clear();
|
d->endTimes.clear();
|
||||||
if (hadRowHeights)
|
if (hadRowHeights)
|
||||||
emit expandedRowHeightChanged(-1, -1);
|
emit expandedRowHeightChanged(-1, -1);
|
||||||
if (!wasEmpty)
|
if (!wasEmpty) {
|
||||||
emit emptyChanged();
|
emit emptyChanged();
|
||||||
|
emit heightChanged();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int TimelineModel::nextItemBySelectionId(int selectionId, qint64 time, int currentItem) const
|
int TimelineModel::nextItemBySelectionId(int selectionId, qint64 time, int currentItem) const
|
||||||
|
Reference in New Issue
Block a user