2021-06-21 Fred Gleason <fredg@paravelsystems.com>

* Added 'RDMainWindow' to rdlogmanager(1).

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2021-06-21 11:08:40 -04:00
parent d0fc2313f0
commit 179a5c4696
3 changed files with 18 additions and 5 deletions

View File

@@ -39,7 +39,7 @@ QString *clock_filter;
bool skip_db_check=false;
MainWidget::MainWidget(RDConfig *c,QWidget *parent)
: RDWidget(c,parent)
: RDMainWindow("rdlogmanager",c)
{
QString err_msg;
@@ -146,6 +146,8 @@ MainWidget::MainWidget(RDConfig *c,QWidget *parent)
log_close_button->setText(tr("Close"));
log_close_button->setDefault(true);
connect(log_close_button,SIGNAL(clicked()),this,SLOT(quitMainWidget()));
loadSettings(true);
}
@@ -161,6 +163,12 @@ QSizePolicy MainWidget::sizePolicy() const
}
void MainWidget::closeEvent(QCloseEvent *e)
{
quitMainWidget();
}
void MainWidget::userData()
{
//
@@ -219,6 +227,7 @@ void MainWidget::reportsData()
void MainWidget::quitMainWidget()
{
saveSettings();
exit(RDApplication::ExitOk);
}
@@ -261,8 +270,6 @@ int gui_main(int argc,char *argv[])
RDConfig *config=new RDConfig();
config->load();
MainWidget *w=new MainWidget(config);
w->setGeometry(QRect(QPoint(w->geometry().x(),w->geometry().y()),
w->sizeHint()));
w->show();
return a.exec();
}