[libcalamaresui] LocaleLabel doesn't need to inherit QObject

- Use static QObject::tr instead.
This commit is contained in:
Adriaan de Groot 2018-12-14 11:30:05 +01:00
parent 1f4ac45bb5
commit 3dda9ab860
2 changed files with 2 additions and 4 deletions

View File

@ -270,7 +270,7 @@ LocaleLabel::LocaleLabel( const QString& locale )
: m_locale( LocaleLabel::getLocale( locale ) )
, m_localeId( locale )
{
QString longFormat = tr( "%1 (%2)", "Language (Country)" );
QString longFormat = QObject::tr( "%1 (%2)", "Language (Country)" );
QString sortKey = QLocale::languageToString( m_locale.language() );
QString languageName = m_locale.nativeLanguageName();

View File

@ -134,10 +134,8 @@ constexpr int windowPreferredHeight = 520;
* translation system) into QLocales, and also into consistent
* human-readable text labels.
*/
class LocaleLabel : public QObject
class LocaleLabel
{
Q_OBJECT
public:
/** @brief Construct from a locale name.
*