Skip to content
Snippets Groups Projects
Commit 724f67b3 authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

Open File: Make it open in project directory if one is set.

Reviewed-by: dt
Task-number: QTCREATORBUG-2947
parent 6510a749
No related branches found
No related tags found
No related merge requests found
...@@ -779,6 +779,8 @@ QStringList FileManager::getOpenFileNames(const QString &filters, ...@@ -779,6 +779,8 @@ QStringList FileManager::getOpenFileNames(const QString &filters,
if (path.isEmpty()) { if (path.isEmpty()) {
if (!d->m_currentFile.isEmpty()) if (!d->m_currentFile.isEmpty())
path = QFileInfo(d->m_currentFile).absoluteFilePath(); path = QFileInfo(d->m_currentFile).absoluteFilePath();
if (path.isEmpty() && useProjectsDirectory())
path = projectsDirectory();
} }
const QStringList files = QFileDialog::getOpenFileNames(d->m_mainWindow, const QStringList files = QFileDialog::getOpenFileNames(d->m_mainWindow,
tr("Open File"), tr("Open File"),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment