2022-09-29 Fred Gleason <fredg@paravelsystems.com>

* Fixed a bug in the i18n system that would throw warnings when
	attempting to load the (non-existent) English translation.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason 2022-09-29 14:27:30 -04:00
parent af4fec015f
commit e19c613dba
2 changed files with 9 additions and 4 deletions

View File

@ -23419,3 +23419,6 @@
* Fixed a regression in rdairplay(1) that caused a segfault when
selecting a cart in the 'Select Cart' dialog if the Cue output
assignment was disabled.
2022-09-29 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in the i18n system that would throw warnings when
attempting to load the (non-existent) English translation.

View File

@ -31,11 +31,13 @@ RDTranslator::RDTranslator(const QString &cmdname,QObject *parent)
d_command_name=cmdname;
QString loc=RDApplication::locale().left(2)+".qm";
if(loc.left(2)!="en") { // There are no English translations
LoadTranslation("qt_"+loc,"/usr/share/qt5/translations");
LoadTranslation("librd_"+loc,"/usr/share/rivendell");
LoadTranslation("rdhpi_"+loc,"/usr/share/rivendell");
LoadTranslation(d_command_name+"_"+loc,"/usr/share/rivendell");
}
}
bool RDTranslator::LoadTranslation(const QString &filename,