[packagechooser] Add configuration setting for selection mode

- Add a *mode* key to the configuration file
 - Change some names around to be more consistent (not user-visible)
This commit is contained in:
Adriaan de Groot 2019-08-03 15:45:00 +02:00
parent fb3204262c
commit 76077743af
4 changed files with 29 additions and 11 deletions

View file

@ -150,6 +150,16 @@ void
PackageChooserViewStep::setConfigurationMap( const QVariantMap& configurationMap )
{
// TODO: use the configurationMap
QString mode = CalamaresUtils::getString( configurationMap, "mode" );
bool ok = false;
if ( !mode.isEmpty() )
{
m_mode = roleNames().find( mode, ok );
}
if ( !ok )
{
m_mode = PackageChooserMode::Required;
}
if ( !m_model )
{