[Libreoffice-commits] core.git: cui/source
Efe Gürkan YALAMAN
efeyalaman at gmail.com
Tue Oct 29 12:54:39 CET 2013
cui/source/options/optaboutconfig.cxx | 18 ++++++++----------
1 file changed, 8 insertions(+), 10 deletions(-)
New commits:
commit f87f5c829e612d333ddff892752693b2835cec19
Author: Efe Gürkan YALAMAN <efeyalaman at gmail.com>
Date: Mon Oct 28 01:33:41 2013 +0200
fdo#70049 Expert Config page cannot save boolean
This patch fixes unsaveable booleans. Also fix the problem occurs when there is
multiple changes on page. Page was commiting only last added one, now
commits all.
Change-Id: Id1a15634e95d5ca9d54e7a90fa1bbbaf874e3f08
Reviewed-on: https://gerrit.libreoffice.org/6457
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/cui/source/options/optaboutconfig.cxx b/cui/source/options/optaboutconfig.cxx
index 753edb2..21b96c4b 100644
--- a/cui/source/options/optaboutconfig.cxx
+++ b/cui/source/options/optaboutconfig.cxx
@@ -191,20 +191,18 @@ sal_Bool CuiAboutConfigTabPage::FillItemSet( SfxItemSet& )
sal_Bool bModified = sal_False;
Reference< XNameAccess > xUpdateAccess = getConfigAccess( "/", sal_True );
- for( size_t nInd = 0; nInd < m_vectorOfModified.size(); ++nInd )
+ std::vector< boost::shared_ptr< Prop_Impl > >::iterator pIter;
+ for( pIter = m_vectorOfModified.begin() ; pIter != m_vectorOfModified.end(); ++pIter )
{
- boost::shared_ptr< Prop_Impl > aNamedValue = m_vectorOfModified[ nInd ];
-
- xUpdateAccess = getConfigAccess( aNamedValue->Name , sal_True );
+ xUpdateAccess = getConfigAccess( (*pIter)->Name , sal_True );
Reference< XNameReplace > xNameReplace( xUpdateAccess, UNO_QUERY_THROW );
- xNameReplace->replaceByName( aNamedValue->Property, aNamedValue->Value );
+ xNameReplace->replaceByName( (*pIter)->Property, (*pIter)->Value );
bModified = sal_True;
- }
- Reference< util::XChangesBatch > xChangesBatch( xUpdateAccess, UNO_QUERY_THROW );
-
- xChangesBatch->commitChanges();
+ Reference< util::XChangesBatch > xChangesBatch( xUpdateAccess, UNO_QUERY_THROW );
+ xChangesBatch->commitChanges();
+ }
return bModified;
}
@@ -638,10 +636,10 @@ IMPL_LINK_NOARG( CuiAboutConfigTabPage, StandardHdl_Impl )
throw uno::Exception();
- AddToModifiedVector( pProperty );
sDialogValue = sNewValue;
}
}
+ AddToModifiedVector( pProperty );
//update listbox value.
m_pPrefBox->SetEntryText( sDialogValue, pEntry, 3 );
More information about the Libreoffice-commits
mailing list