From 99de80e7224f2491fb7518e32f195ad6a912b624 Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 28 Nov 2014 11:19:20 +0100 Subject: replaced all uses of NULL with nullptr fixed a few placed where NULL was used as a number or boolean --- src/profilesdialog.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/profilesdialog.cpp') diff --git a/src/profilesdialog.cpp b/src/profilesdialog.cpp index 3fdad880..26891b3c 100644 --- a/src/profilesdialog.cpp +++ b/src/profilesdialog.cpp @@ -177,7 +177,7 @@ void ProfilesDialog::on_removeProfileButton_clicked() Profile::Ptr currentProfile = profilesList->currentItem()->data(Qt::UserRole).value(); QString profilePath; - if (currentProfile.get() == NULL) { + if (currentProfile.get() == nullptr) { profilePath = QDir::fromNativeSeparators(ToQString(GameInfo::instance().getProfilesDir())) + "/" + profilesList->currentItem()->text(); if (QMessageBox::question(this, tr("Profile broken"), tr("This profile you're about to delete seems to be broken or the path is invalid. " @@ -190,7 +190,7 @@ void ProfilesDialog::on_removeProfileButton_clicked() profilePath = currentProfile->getPath(); } QListWidgetItem* item = profilesList->takeItem(profilesList->currentRow()); - if (item != NULL) { + if (item != nullptr) { delete item; } if (!shellDelete(QStringList(profilePath))) { @@ -231,7 +231,7 @@ void ProfilesDialog::on_invalidationBox_stateChanged(int state) QListWidget *profilesList = findChild("profilesList"); QListWidgetItem *currentItem = profilesList->currentItem(); - if (currentItem == NULL) { + if (currentItem == nullptr) { return; } if (!ui->invalidationBox->isEnabled()) { @@ -263,7 +263,7 @@ void ProfilesDialog::on_profilesList_currentItemChanged(QListWidgetItem *current QPushButton *transferButton = findChild("transferButton"); QPushButton *renameButton = findChild("renameButton"); - if (current != NULL) { + if (current != nullptr) { if (!current->data(Qt::UserRole).isValid()) return; const Profile::Ptr currentProfile = current->data(Qt::UserRole).value(); -- cgit v1.3.1