diff --git a/lib/deep4.f90 b/lib/deep4.f90 index ad3b91641..05f6732d7 100644 --- a/lib/deep4.f90 +++ b/lib/deep4.f90 @@ -136,17 +136,13 @@ subroutine deep4(sym0,neme,flip,mycall,hiscall,hisgrid,decoded,qual) p1=p ip1=k endif -! write(78,3001) k,pp(k),testmsg(k) -!3001 format(i6,f10.3,2x,a22) endif enddo -! flush(78) do i=1,ntot - if(pp(i).gt.p2 .and. pp(i).ne.p1) p2=pp(i) + if(pp(i).gt.p2 .and. testmsg(i).ne.testmsg(ip1)) p2=pp(i) enddo -! qual=p1-max(1.15*p2,80.0) qual=p1-max(1.15*p2,70.0) ! ### DO NOT REMOVE ### @@ -155,14 +151,6 @@ subroutine deep4(sym0,neme,flip,mycall,hiscall,hisgrid,decoded,qual) rms,qual,ip1,testmsg(ip1) 1001 format(2f8.2,i8,2f8.2,i6,2x,a22) call flush(77) -! ### Works OK without it (in both Windows and Linux) if compiled -! ### without optimization. However, in Windows this is a colossal -! ### pain because of the way F2PY wants to run the compile step. - - -! write(71,3001) p1,p2,qual,testmsg(ip1) -!3001 format(3f10.3,2x,a22) -! call flush(71) if(qual.gt.1.0) then decoded=testmsg(ip1) @@ -177,8 +165,5 @@ subroutine deep4(sym0,neme,flip,mycall,hiscall,hisgrid,decoded,qual) decoded(i:i)=char(ichar(decoded(i:i))-32) enddo -! write(79,1001) p1,p2,ntot,rms,qual,ip1,testmsg(ip1) -! call flush(79) - return end subroutine deep4 diff --git a/mainwindow.cpp b/mainwindow.cpp index 96a942254..dbf21e7d2 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -812,6 +812,7 @@ MainWindow::MainWindow(QDir const& temp_directory, bool multiple, m_fCPUmskrtd=0.0; m_bFastDone=false; m_bAltV=false; + m_bNoMoreFiles=false; m_wait=0; ui->txrb1->setChecked(true); @@ -2018,7 +2019,7 @@ void MainWindow::on_actionOpen_next_in_directory_triggered() //Open Next read_wav_file (fname); if(m_loopall and (i==list.size()-2)) { m_loopall=false; - MessageBox::information_message(this, tr("No more files to open.")); + m_bNoMoreFiles=true; } return; } @@ -2408,6 +2409,10 @@ void MainWindow::readFromStdout() //readFromStdout if(!m_diskData) killFileTimer.start (3*1000*m_TRperiod/4); //Kill in 45 s decodeDone (); m_startAnother=m_loopall; + if(m_bNoMoreFiles) { + MessageBox::information_message(this, tr("No more files to open.")); + m_bNoMoreFiles=false; + } return; } else { if(m_mode=="JT4" or m_mode=="JT65" or m_mode=="QRA64") { diff --git a/mainwindow.h b/mainwindow.h index f426a4964..84f48dc82 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -420,6 +420,7 @@ private: bool m_bUseRef; bool m_bFastDone; bool m_bAltV; + bool m_bNoMoreFiles; float m_pctZap; int m_ihsym; int m_nzap;