summaryrefslogtreecommitdiff
path: root/src/plugins/projectexplorer/projectwelcomepage.cpp
diff options
context:
space:
mode:
authorTobias Hunger <tobias.hunger@theqtcompany.com>2016-04-13 15:52:14 +0200
committerTobias Hunger <tobias.hunger@theqtcompany.com>2016-04-15 09:40:53 +0000
commit95ac4edfd4276c73f0304651fe032d511a5a7c16 (patch)
treec1ebcef6ecff1292f9fa670111c39043b0f67837 /src/plugins/projectexplorer/projectwelcomepage.cpp
parent79da8a45860940f98333517c60ac388cc0b1af3a (diff)
downloadqt-creator-95ac4edfd4276c73f0304651fe032d511a5a7c16.tar.gz
Projectexplorer: Modernize codebase
Change-Id: I4793b58aa77bcd46af99f8b843c0f7439cdc9269 Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com> Reviewed-by: Vikas Pachdha <vikas.pachdha@theqtcompany.com>
Diffstat (limited to 'src/plugins/projectexplorer/projectwelcomepage.cpp')
-rw-r--r--src/plugins/projectexplorer/projectwelcomepage.cpp12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/plugins/projectexplorer/projectwelcomepage.cpp b/src/plugins/projectexplorer/projectwelcomepage.cpp
index 504ec3fbbc..f94d4debee 100644
--- a/src/plugins/projectexplorer/projectwelcomepage.cpp
+++ b/src/plugins/projectexplorer/projectwelcomepage.cpp
@@ -117,7 +117,7 @@ void SessionModel::resetSessions()
void SessionModel::cloneSession(const QString &session)
{
- SessionNameInputDialog newSessionInputDialog(SessionManager::sessions(), 0);
+ SessionNameInputDialog newSessionInputDialog(SessionManager::sessions(), nullptr);
newSessionInputDialog.setWindowTitle(tr("New session name"));
newSessionInputDialog.setValue(session + QLatin1String(" (2)"));
@@ -145,7 +145,7 @@ void SessionModel::deleteSession(const QString &session)
void SessionModel::renameSession(const QString &session)
{
- SessionNameInputDialog newSessionInputDialog(SessionManager::sessions(), 0);
+ SessionNameInputDialog newSessionInputDialog(SessionManager::sessions(), nullptr);
newSessionInputDialog.setWindowTitle(tr("New session name"));
newSessionInputDialog.setValue(session);
@@ -180,7 +180,6 @@ QVariant ProjectModel::data(const QModelIndex &index, int role) const
switch (role) {
case Qt::DisplayRole:
return data.second;
- break;
case FilePathRole:
return data.first;
case PrettyFilePathRole:
@@ -188,8 +187,6 @@ QVariant ProjectModel::data(const QModelIndex &index, int role) const
default:
return QVariant();
}
-
- return QVariant();
}
QHash<int, QByteArray> ProjectModel::roleNames() const
@@ -209,11 +206,6 @@ void ProjectModel::resetProjects()
///////////////////
-ProjectWelcomePage::ProjectWelcomePage() :
- m_sessionModel(0), m_projectModel(0)
-{
-}
-
void ProjectWelcomePage::facilitateQml(QQmlEngine *engine)
{
m_sessionModel = new SessionModel(this);