Save/restore geometry of LogQSO window over program invocations.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3240 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Joe Taylor 2013-04-28 20:23:14 +00:00
parent ac60453076
commit 15b52e7061
2 changed files with 4 additions and 4 deletions

View File

@ -179,7 +179,6 @@ MainWindow::MainWindow(QSharedMemory *shdmem, QWidget *parent) :
m_bRigOpen=false;
m_secBandChanged=0;
m_bMultipleOK=false;
m_bLogGeom=false;
decodeBusy(false);
ui->xThermo->setFillBrush(Qt::green);
@ -411,6 +410,8 @@ void MainWindow::writeSettings()
settings.setValue("MultipleOK",m_bMultipleOK);
settings.setValue("DTRoff",m_bDTRoff);
settings.setValue("pttData",m_pttData);
settings.setValue("LogQSOgeom",m_logQSOgeom);
settings.endGroup();
}
@ -525,6 +526,7 @@ void MainWindow::readSettings()
ui->actionAllow_multiple_instances->setChecked(m_bMultipleOK);
m_bDTRoff=settings.value("DTRoff",false).toBool();
m_pttData=settings.value("pttData",false).toBool();
m_logQSOgeom=settings.value("LogQSOgeom",QRect(500,400,424,283)).toRect();
if(!ui->actionLinrad->isChecked() && !ui->actionCuteSDR->isChecked() &&
!ui->actionAFMHot->isChecked() && !ui->actionBlue->isChecked()) {
@ -2215,14 +2217,13 @@ void MainWindow::on_logQSOButton_clicked() //Log QSO button
m_qsoStart,m_qsoStop,m_dialFreq,m_myCall,m_myGrid,
m_noSuffix,m_toRTTY,m_dBtoComments);
connect(logDlg, SIGNAL(acceptQSO(bool)),this,SLOT(acceptQSO2(bool)));
if(m_bLogGeom) logDlg->setGeometry(m_logQSOgeom);
if(m_logQSOgeom != QRect(500,400,424,283)) logDlg->setGeometry(m_logQSOgeom);
logDlg->show();
}
void MainWindow::acceptQSO2(bool accepted)
{
m_logQSOgeom=logDlg->geometry();
m_bLogGeom=true;
QString date=dateTimeQSO.toString("yyyyMMdd");
QFile f("wsjtx.log");
if(!f.open(QIODevice::Text | QIODevice::Append)) {

View File

@ -253,7 +253,6 @@ private:
bool m_bMultipleOK;
bool m_bDTRoff;
bool m_pttData;
bool m_bLogGeom;
char m_decoded[80];