From fb6df81fa9f224c94118fd79fea91ae15559c7e3 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Mon, 22 Aug 2016 16:17:38 +0900 Subject: Replaced QList<> with QVector<> where appropriate + minor code cleanup See https://marcmutz.wordpress.com/effective-qt/containers/ for the background and http://lists.qt-project.org/pipermail/development/2015-July/022283.html for the relevant flamewar in Qt dev mailing list. --- room.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'room.cpp') diff --git a/room.cpp b/room.cpp index 1513cbeb..768a0dac 100644 --- a/room.cpp +++ b/room.cpp @@ -482,11 +482,11 @@ void Room::processEphemeralEvent(Event* event) } if( event->type() == EventType::Receipt ) { - ReceiptEvent* receiptEvent = static_cast(event); + auto receiptEvent = static_cast(event); for( QString eventId: receiptEvent->events() ) { - QList receipts = receiptEvent->receiptsForEvent(eventId); - for( Receipt r: receipts ) + const auto receipts = receiptEvent->receiptsForEvent(eventId); + for( const Receipt r: receipts ) { d->lastReadEvent.insert(d->connection->user(r.userId), eventId); } -- cgit v1.2.3