Reorder a couple of statements.

This commit is contained in:
eelke 2017-02-10 21:01:09 +01:00
parent 8ea0cd8285
commit 254cc82116

View file

@ -41,12 +41,13 @@ QueryTab::QueryTab(MainWindow *win, QWidget *parent) :
font.setFixedPitch(true);
font.setPointSize(10);
ui->queryEdit->setFont(font);
highlighter = new SqlSyntaxHighlighter(ui->queryEdit->document());
OpenDatabase* open_database = m_win->getDatabase();
m_typeDelegate.setTypeSelectionModel(open_database->typeSelectionModel());
auto cat = open_database->catalogue();
highlighter = new SqlSyntaxHighlighter(ui->queryEdit->document());
highlighter->setTypes(cat->types());
ui->paramTableView->setModel(&m_paramList);
@ -62,6 +63,7 @@ QueryTab::~QueryTab()
{
m_dbConnection.closeConnection();
m_dbConnection.setStateCallback(nullptr);
// delete m_pgTypes;
delete ui;
}