Remove syntax highlighting for tables when DB is closed

See issue #1800
This commit is contained in:
mgrojo
2019-03-23 12:50:55 +01:00
parent 77a9dd394d
commit 2d35206313

View File

@@ -922,8 +922,10 @@ bool MainWindow::fileClose()
ui->editLogUser->clear();
ui->editLogErrorLog->clear();
// Remove completion for identifiers
// Remove completion and highlighting for identifiers
SqlTextEdit::sqlLexer->setTableNames(SqlUiLexer::QualifiedTablesMap());
for(int i=0; i < ui->tabSqlAreas->count(); i++)
qobject_cast<SqlExecutionArea*>(ui->tabSqlAreas->widget(i))->getEditor()->reloadKeywords();
return true;
}