summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorRachit Gupta <rachitgupta1792@gmail.com>2014-06-30 15:28:05 +0530
committerJan Holesovsky <kendy@collabora.com>2014-08-14 19:43:29 +0200
commit49b08326e3ac2a805373f255b3b0fd2c6fa165fa (patch)
treec69a338596fc044f7f8463d7ef3c1ade6a134d5b /cui
parent4017908018a0ccc771247f09c47798dd20644db3 (diff)
Changed application of personas through extensions procedure.
The PersonasEntry template in the registry now stores the setting as splitted values rather than ';' separated terms. The corresponding ';' separated setting is prepared and stored. Change-Id: I154d519c475a48763a75b5c35ad20f170c1d7996
Diffstat (limited to 'cui')
-rw-r--r--cui/source/options/personalization.cxx25
1 files changed, 19 insertions, 6 deletions
diff --git a/cui/source/options/personalization.cxx b/cui/source/options/personalization.cxx
index 4c9781cbe53c..c2fe00c2dbf7 100644
--- a/cui/source/options/personalization.cxx
+++ b/cui/source/options/personalization.cxx
@@ -375,8 +375,8 @@ void SvxPersonalizationTabPage::LoadDefaultImages()
for( ; nIndex < nLength; nIndex++ )
{
Reference< XPropertySet > xPropertySet( officecfg::Office::Common::Misc::PersonasList::get()->getByName( installedPersonas[nIndex] ), UNO_QUERY_THROW );
+ OUString aPersonaName, aPreviewFile, aHeaderFile, aFooterFile, aTextColor, aAccentColor, aPersonaSettings;
Any aValue = xPropertySet->getPropertyValue( "PersonaPreview" );
- OUString aPreviewFile;
aValue >>= aPreviewFile;
INetURLObject aURLObj( aPreviewFile );
aFilter.ImportGraphic( aGraphic, aURLObj );
@@ -384,11 +384,24 @@ void SvxPersonalizationTabPage::LoadDefaultImages()
m_vExtensionPersonas[nCount]->Show();
m_vExtensionPersonas[nCount++]->SetModeImage( Image( aBmp ) );
- aValue = xPropertySet->getPropertyValue( "PersonaSettings" );
- OUString sPersonaSettings;
- aValue >>= sPersonaSettings;
- rtl::Bootstrap::expandMacros( sPersonaSettings );
- m_vExtensionPersonaSettings.push_back( sPersonaSettings );
+ aValue = xPropertySet->getPropertyValue( "PersonaName" );
+ aValue >>= aPersonaName;
+
+ aValue = xPropertySet->getPropertyValue( "PersonaHeader" );
+ aValue >>= aHeaderFile;
+
+ aValue = xPropertySet->getPropertyValue( "PersonaFooter" );
+ aValue >>= aFooterFile;
+
+ aValue = xPropertySet->getPropertyValue( "PersonaTextColor" );
+ aValue >>= aTextColor;
+
+ aValue = xPropertySet->getPropertyValue( "PersonaAccentColor" );
+ aValue >>= aAccentColor;
+
+ aPersonaSettings = aHeaderFile + ";" + aFooterFile + ";" + aTextColor + ";" + aAccentColor;
+ rtl::Bootstrap::expandMacros( aPersonaSettings );
+ m_vExtensionPersonaSettings.push_back( aPersonaSettings );
}
}