Replace post-increment with pre-increment

And post-decrement with pre-decrement.
This commit is contained in:
Chocobo1 2018-05-31 01:06:28 +08:00 committed by sledgehammer999
parent bdac8f8db8
commit be5ad63e21
No known key found for this signature in database
GPG key ID: 6E4A2D025B7CC9A2
16 changed files with 58 additions and 58 deletions

View file

@ -260,7 +260,7 @@ TransferListWidget::TransferListWidget(QWidget *parent, MainWindow *mainWindow)
//Ensure that at least one column is visible at all times
bool atLeastOne = false;
for (unsigned int i = 0; i<TorrentModel::NB_COLUMNS; i++) {
for (unsigned int i = 0; i < TorrentModel::NB_COLUMNS; ++i) {
if (!isColumnHidden(i)) {
atLeastOne = true;
break;
@ -272,7 +272,7 @@ TransferListWidget::TransferListWidget(QWidget *parent, MainWindow *mainWindow)
//When adding/removing columns between versions some may
//end up being size 0 when the new version is launched with
//a conf file from the previous version.
for (unsigned int i = 0; i<TorrentModel::NB_COLUMNS; i++)
for (unsigned int i = 0; i < TorrentModel::NB_COLUMNS; ++i)
if ((columnWidth(i) <= 0) && (!isColumnHidden(i)))
resizeColumnToContents(i);
@ -713,9 +713,9 @@ void TransferListWidget::displayDLHoSMenu(const QPoint&)
actions.append(myAct);
}
int visibleCols = 0;
for (unsigned int i = 0; i<TorrentModel::NB_COLUMNS; i++) {
for (unsigned int i = 0; i < TorrentModel::NB_COLUMNS; ++i) {
if (!isColumnHidden(i))
visibleCols++;
++visibleCols;
if (visibleCols > 1)
break;