2024-05-27 Fred Gleason <fredg@paravelsystems.com>

* Fixed a regression in the 'RDHPIPlayStream::play()' method that
	the 'play_length' setting to be ignored.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2024-05-27 11:35:11 -04:00
parent db81e5d464
commit d422d12a5b
2 changed files with 7 additions and 6 deletions

View File

@@ -496,8 +496,7 @@ bool RDHPIPlayStream::play()
}
#endif
}
bool restart_timer=false;
if(!is_paused) {
if(!is_paused) {
memset(pdata,0,fragment_size);
left_to_write=getDataLength()-seekWave(0,SEEK_CUR);
if(left_to_write<fragment_size) {
@@ -530,8 +529,8 @@ bool RDHPIPlayStream::play()
emit played();
emit stateChanged(card_number,stream_number,(int)stream_state);
}
}
if((!playing)&(is_paused|repositioned)) {
}
if((!playing)&&(is_paused|repositioned)) {
LogHpi(HPI_OutStreamStart(NULL,hpi_stream),__LINE__);
clock->start(FRAGMENT_TIME);
playing=true;
@@ -543,9 +542,8 @@ bool RDHPIPlayStream::play()
emit played();
emit stateChanged(card_number,stream_number,(int)stream_state);
}
restart_timer=true;
}
if((play_length>0)&&restart_timer) {
if(play_length>0) {
play_timer->start(play_length);
start_time=QTime::currentTime();
}