Log Viewer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

32 lines
1005 B

#include "MainWindow.h"
#include "ui_MainWindow.h"
/*************************************************************************************************/
MainWindow::MainWindow(QWidget* parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
{
ui->setupUi(this);
prepareTableView();
}
/*************************************************************************************************/
MainWindow::~MainWindow()
{
delete ui;
}
/*************************************************************************************************/
void MainWindow::setTable(QAbstractTableModel* model)
{
ui->tableView->setModel(model);
}
/*************************************************************************************************/
void MainWindow::prepareTableView()
{
ui->tableView->verticalHeader()->setVisible(false);
ui->tableView->horizontalHeader()->setSectionResizeMode(
QHeaderView::ResizeMode::Stretch);
ui->tableView->horizontalHeader()->setSectionsMovable(true);
}