[welcome] Some translation / label fixes
- the message had been arbitrarily changed; change it back - update (warning) message when there is progress in checking the model, so it doesn't stay at "unchecked" until you change language - minor clean-ups
This commit is contained in:
parent
243c4e6b02
commit
85a1eb95ee
@ -31,6 +31,8 @@ Config::Config( QObject* parent )
|
|||||||
initLanguages();
|
initLanguages();
|
||||||
|
|
||||||
CALAMARES_RETRANSLATE_SLOT( &Config::retranslate );
|
CALAMARES_RETRANSLATE_SLOT( &Config::retranslate );
|
||||||
|
// But also when the requirements model changes, update the messages
|
||||||
|
connect( requirementsModel(), &Calamares::RequirementsModel::progressMessageChanged, this, &Config::retranslate );
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -63,11 +65,11 @@ Config::retranslate()
|
|||||||
message = setup ? tr( "This computer does not satisfy some of the "
|
message = setup ? tr( "This computer does not satisfy some of the "
|
||||||
"recommended requirements for setting up %1.<br/>"
|
"recommended requirements for setting up %1.<br/>"
|
||||||
"Setup can continue, but some features "
|
"Setup can continue, but some features "
|
||||||
"might be reduced." )
|
"might be disabled." )
|
||||||
: tr( "This computer does not satisfy some of the "
|
: tr( "This computer does not satisfy some of the "
|
||||||
"recommended requirements for installing %1.<br/>"
|
"recommended requirements for installing %1.<br/>"
|
||||||
"Installation can continue, but some features "
|
"Installation can continue, but some features "
|
||||||
"might be reduced." );
|
"might be disabled." );
|
||||||
}
|
}
|
||||||
|
|
||||||
m_warningMessage = message.arg( Calamares::Branding::instance()->shortVersionedName() );
|
m_warningMessage = message.arg( Calamares::Branding::instance()->shortVersionedName() );
|
||||||
|
@ -127,7 +127,6 @@ ResultsListDialog::ResultsListDialog( const Calamares::RequirementsModel& model,
|
|||||||
connect( buttonBox, &QDialogButtonBox::clicked, this, &QDialog::close );
|
connect( buttonBox, &QDialogButtonBox::clicked, this, &QDialog::close );
|
||||||
|
|
||||||
CALAMARES_RETRANSLATE_SLOT( &ResultsListDialog::retranslate );
|
CALAMARES_RETRANSLATE_SLOT( &ResultsListDialog::retranslate );
|
||||||
retranslate(); // Do it now to fill in the texts
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ResultsListDialog::~ResultsListDialog() {}
|
ResultsListDialog::~ResultsListDialog() {}
|
||||||
@ -169,15 +168,15 @@ ResultsListWidget::ResultsListWidget( Config* config, QWidget* parent )
|
|||||||
spacerLayout->addSpacing( paddingSize );
|
spacerLayout->addSpacing( paddingSize );
|
||||||
CalamaresUtils::unmarginLayout( spacerLayout );
|
CalamaresUtils::unmarginLayout( spacerLayout );
|
||||||
|
|
||||||
auto* explanation = new QLabel;
|
auto* explanation = new QLabel( m_config->warningMessage() );
|
||||||
explanation->setWordWrap( true );
|
explanation->setWordWrap( true );
|
||||||
explanation->setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Preferred );
|
explanation->setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Preferred );
|
||||||
explanation->setOpenExternalLinks( false );
|
explanation->setOpenExternalLinks( false );
|
||||||
explanation->setObjectName( "resultsExplanation" );
|
explanation->setObjectName( "resultsExplanation" );
|
||||||
connect( explanation, &QLabel::linkActivated, this, &ResultsListWidget::linkClicked );
|
|
||||||
entriesLayout->addWidget( explanation );
|
entriesLayout->addWidget( explanation );
|
||||||
|
|
||||||
connect( config, &Config::warningMessageChanged, explanation, &QLabel::setText );
|
connect( config, &Config::warningMessageChanged, explanation, &QLabel::setText );
|
||||||
|
connect( explanation, &QLabel::linkActivated, this, &ResultsListWidget::linkClicked );
|
||||||
|
|
||||||
// Check that all are satisfied (gives warnings if not) and
|
// Check that all are satisfied (gives warnings if not) and
|
||||||
// all *mandatory* entries are satisfied (gives errors if not).
|
// all *mandatory* entries are satisfied (gives errors if not).
|
||||||
@ -226,7 +225,6 @@ ResultsListWidget::ResultsListWidget( Config* config, QWidget* parent )
|
|||||||
}
|
}
|
||||||
|
|
||||||
CALAMARES_RETRANSLATE_SLOT( &ResultsListWidget::retranslate );
|
CALAMARES_RETRANSLATE_SLOT( &ResultsListWidget::retranslate );
|
||||||
retranslate();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user