#include <kitemviews/kitemlistview.h>
-#include <KDebug>
+#include <QDebug>
#include <KGlobalSettings>
#include <QGraphicsWidget>
}
Q_ASSERT(propertyAnim);
- connect(propertyAnim, SIGNAL(finished()), this, SLOT(slotFinished()));
+ connect(propertyAnim, &QPropertyAnimation::finished, this, &KItemListViewAnimation::slotFinished);
m_animation[type].insert(widget, propertyAnim);
propertyAnim->start();
{
QPropertyAnimation* finishedAnim = qobject_cast<QPropertyAnimation*>(sender());
for (int type = 0; type < AnimationTypeCount; ++type) {
- QHashIterator<QGraphicsWidget*, QPropertyAnimation*> it(m_animation[type]);
+ QMutableHashIterator<QGraphicsWidget*, QPropertyAnimation*> it(m_animation[type]);
while (it.hasNext()) {
it.next();
QPropertyAnimation* propertyAnim = it.value();
if (propertyAnim == finishedAnim) {
QGraphicsWidget* widget = it.key();
- m_animation[type].remove(widget);
+ it.remove();
finishedAnim->deleteLater();
emit finished(widget, static_cast<AnimationType>(type));
Q_ASSERT(false);
}
-#include "kitemlistviewanimation.moc"