Skip to content

Commit

Permalink
Fix UI not following system language when available
Browse files Browse the repository at this point in the history
  • Loading branch information
nirvn committed Oct 30, 2024
1 parent 73bf646 commit 22c0c39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,9 @@ int main( int argc, char **argv )
qtTranslatorLoaded = qtTranslator.load( QStringLiteral( "qt_%1" ).arg( customLanguage ), QStringLiteral( ":/i18n/" ), "_" );
}
if ( !qfieldTranslatorLoaded || qfieldTranslator.isEmpty() )
( void ) qfieldTranslator.load( QLocale(), "qfield", "_", ":/i18n/" );
( void ) qfieldTranslator.load( QLocale( QLocale::system().name() ), "qfield", "_", ":/i18n/" );
if ( !qtTranslatorLoaded || qtTranslator.isEmpty() )
( void ) qtTranslator.load( QLocale(), "qt", "_", ":/i18n/" );
( void ) qtTranslator.load( QLocale( QLocale::system().name() ), "qt", "_", ":/i18n/" );

dummyApp->installTranslator( &qtTranslator );
dummyApp->installTranslator( &qfieldTranslator );
Expand Down

0 comments on commit 22c0c39

Please sign in to comment.