Moved code from TablesPage into seperate PropetiesPage component
Clears up the TablePage and makes rhe propertypage reusable.
This commit is contained in:
parent
b8cfb223be
commit
38ae5f50e4
8 changed files with 73 additions and 36 deletions
25
pglab/PropertiesPage.cpp
Normal file
25
pglab/PropertiesPage.cpp
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
#include "PropertiesPage.h"
|
||||
#include "PgLabItemDelegate.h"
|
||||
#include "PropertyProxyModel.h"
|
||||
#include "ResultTableModelUtil.h"
|
||||
#include "SqlCodePreview.h"
|
||||
#include <QTableView>
|
||||
|
||||
PropertiesPage::PropertiesPage(QWidget *parent) : QSplitter(parent)
|
||||
{
|
||||
m_tableView = new QTableView(this);
|
||||
// m_definitionView = new SqlCodePreview(this);
|
||||
addWidget(m_tableView);
|
||||
// addWidget(m_definitionView);
|
||||
|
||||
SetTableViewDefault(m_tableView);
|
||||
|
||||
m_propertyProxyModel = new PropertyProxyModel(this);
|
||||
m_tableView->setModel(m_propertyProxyModel);
|
||||
|
||||
auto item_delegate = new PgLabItemDelegate(this);
|
||||
m_tableView->setItemDelegate(item_delegate);
|
||||
}
|
||||
|
||||
|
||||
//property_model->setSourceModel(m_tablesModel);
|
||||
Loading…
Add table
Add a link
Reference in a new issue