Python: Fix detecting python ls for reopened files

Change-Id: Icc601fa43c7b1432d0bf12fae2f65e0c914262ac
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
David Schulz
2022-08-08 13:05:47 +02:00
parent 892448753c
commit 9fe3aa6612

View File

@@ -120,13 +120,13 @@ public:
if (python.exists())
PyLSConfigureAssistant::openDocumentWithPython(python, this);
});
connect(this, &PythonDocument::openFinishedSuccessfully,
this, &PythonDocument::checkForPyls);
}
void setFilePath(const Utils::FilePath &filePath) override
void checkForPyls()
{
TextEditor::TextDocument::setFilePath(filePath);
const Utils::FilePath &python = detectPython(filePath);
const Utils::FilePath &python = detectPython(filePath());
if (!python.exists())
return;