ProjectExplorer: Make more use of available convenience functions

Change-Id: I53089c5e2138b1c9943d0dbff3857a2dff8ea233
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2019-11-20 15:32:42 +01:00
parent c9fe463fee
commit 7dec498323
2 changed files with 2 additions and 4 deletions

View File

@@ -178,11 +178,9 @@ void AutotoolsBuildSystem::updateCppCodeModel()
QtSupport::CppKitInfo kitInfo(kit()); QtSupport::CppKitInfo kitInfo(kit());
QTC_ASSERT(kitInfo.isValid(), return ); QTC_ASSERT(kitInfo.isValid(), return );
const Utils::FilePath projectFilePath = project()->projectFilePath();
RawProjectPart rpp; RawProjectPart rpp;
rpp.setDisplayName(project()->displayName()); rpp.setDisplayName(project()->displayName());
rpp.setProjectFileLocation(projectFilePath.toString()); rpp.setProjectFileLocation(projectFilePath().toString());
rpp.setQtVersion(kitInfo.projectPartQtVersion); rpp.setQtVersion(kitInfo.projectPartQtVersion);
const QStringList cflags = m_makefileParserThread->cflags(); const QStringList cflags = m_makefileParserThread->cflags();
QStringList cxxflags = m_makefileParserThread->cxxflags(); QStringList cxxflags = m_makefileParserThread->cxxflags();

View File

@@ -118,7 +118,7 @@ NimbleBuildSystem::NimbleBuildSystem(Target *target)
m_directoryWatcher.addFile(projectFilePath().toString(), FileSystemWatcher::WatchModifiedDate); m_directoryWatcher.addFile(projectFilePath().toString(), FileSystemWatcher::WatchModifiedDate);
connect(&m_directoryWatcher, &FileSystemWatcher::fileChanged, this, [this](const QString &path) { connect(&m_directoryWatcher, &FileSystemWatcher::fileChanged, this, [this](const QString &path) {
if (path == project()->projectFilePath().toString()) { if (path == projectFilePath().toString()) {
updateProject(); updateProject();
} }
}); });