From 254cc821161cf51db49b29b7130883fe389a2612 Mon Sep 17 00:00:00 2001 From: eelke Date: Fri, 10 Feb 2017 21:01:09 +0100 Subject: [PATCH] Reorder a couple of statements. --- querytab.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/querytab.cpp b/querytab.cpp index 7f998d3..719bd93 100644 --- a/querytab.cpp +++ b/querytab.cpp @@ -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; }