1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 09:32:12 +01:00

Fixed redundant code warning

Closes #2077
This commit is contained in:
David Rosca 2016-09-18 12:13:44 +02:00
parent 91fa5cd835
commit ad299bfe28

View File

@ -147,7 +147,7 @@ void DownloadManager::timerEvent(QTimerEvent* e)
}
for (int i = 0; i < ui->list->count(); i++) {
DownloadItem* downItem = qobject_cast<DownloadItem*>(ui->list->itemWidget(ui->list->item(i)));
if (!downItem || (downItem && downItem->isCancelled()) || !downItem->isDownloading()) {
if (!downItem || downItem->isCancelled() || !downItem->isDownloading()) {
continue;
}
progresses.append(downItem->progress());
@ -288,7 +288,7 @@ void DownloadManager::downloadFinished(bool success)
bool downloadingAllFilesFinished = true;
for (int i = 0; i < ui->list->count(); i++) {
DownloadItem* downItem = qobject_cast<DownloadItem*>(ui->list->itemWidget(ui->list->item(i)));
if (!downItem || (downItem && downItem->isCancelled()) || !downItem->isDownloading()) {
if (!downItem || downItem->isCancelled() || !downItem->isDownloading()) {
continue;
}
downloadingAllFilesFinished = false;