Moved instantiation of PSK_Reporter object to MainWindow constructor

initialisation list to avoid a null pointer issue in restoring the
settings on startup.



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3557 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Bill Somerville 2013-08-16 23:24:48 +00:00
parent 76ead6b071
commit bf90f2042a

View File

@ -51,7 +51,8 @@ MainWindow::MainWindow(QSettings * settings, QSharedMemory *shdmem, QString *the
m_audioInputDevice (QAudioDeviceInfo::defaultInputDevice ()), // start with default
m_modulator (TX_SAMPLE_RATE, NTMAX / 2),
m_audioOutputDevice (QAudioDeviceInfo::defaultOutputDevice ()), // start with default
m_soundOutput (&m_modulator)
m_soundOutput (&m_modulator),
psk_Reporter (new PSKReporter (this))
{
ui->setupUi(this);
@ -394,7 +395,6 @@ MainWindow::MainWindow(QSettings * settings, QSharedMemory *shdmem, QString *the
ui->decodedTextLabel->setText(t);
ui->decodedTextLabel2->setText(t);
psk_Reporter = new PSK_Reporter(this);
psk_Reporter->setLocalStation(m_myCall,m_myGrid, m_antDescription[m_band], "WSJT-X r" + rev.mid(6,4) );
on_actionEnable_DXCC_entity_triggered(m_displayDXCCEntity); // sets text window proportions and (re)inits the logbook