start of trial to add sidebar style options

use a new style section in branding.desc, doesn't build as is
This commit is contained in:
demmm 2015-03-19 11:26:22 -04:00 committed by Teo Mrnjavac
parent c7f46136fc
commit 56afa45812
4 changed files with 39 additions and 3 deletions

View file

@ -62,6 +62,13 @@ QStringList Branding::s_imageEntryStrings =
"productIcon"
};
QStringList Branding::s_styleEntryStrings =
{
"sidebarBackground",
"sidebarText",
"sidebarTextSelect"
};
Branding::Branding( const QString& brandingFilePath,
QObject* parent )
@ -146,6 +153,15 @@ Branding::Branding( const QString& brandingFilePath,
}
else
bail( "Syntax error in slideshow sequence." );
if ( !doc[ "style" ].IsMap() )
bail( "Syntax error in style map." );
QVariantMap style =
CalamaresUtils::yamlMapToVariant( doc[ "style" ] ).toMap();
m_style.clear();
for ( auto it = style.constBegin(); it != style.constEnd(); ++it )
m_style.insert( it.key(), it.value().toString() );
}
catch ( YAML::Exception& e )