From b7888903ea660b3252eeed26c43ac1fce2b72352 Mon Sep 17 00:00:00 2001 From: asl Date: Wed, 9 Nov 2005 13:58:19 +0000 Subject: [PATCH] PAL9883 - invalid values in saved user preferences file --- src/Qtx/QtxResourceEdit.cxx | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/Qtx/QtxResourceEdit.cxx b/src/Qtx/QtxResourceEdit.cxx index d64edee3a..dd6b3c0c7 100644 --- a/src/Qtx/QtxResourceEdit.cxx +++ b/src/Qtx/QtxResourceEdit.cxx @@ -190,14 +190,24 @@ void QtxResourceEdit::childItems( QPtrList& lst ) const void QtxResourceEdit::resourceValues( QMap& map ) const { + QString sect, name; for ( ItemMap::ConstIterator it = myItems.begin(); it != myItems.end(); ++it ) - map.insert( it.key(), it.data()->resourceValue() ); + { + it.data()->resource( sect, name ); + if( myResMgr->hasValue( sect, name ) ) + map.insert( it.key(), it.data()->resourceValue() ); + } } void QtxResourceEdit::resourceValues( QMap& map ) const { + QString sect, name; for ( ItemMap::ConstIterator it = myItems.begin(); it != myItems.end(); ++it ) - map.insert( it.data(), it.data()->resourceValue() ); + { + it.data()->resource( sect, name ); + if( myResMgr->hasValue( sect, name ) ) + map.insert( it.data(), it.data()->resourceValue() ); + } } void QtxResourceEdit::setResourceValues( QMap& map ) const -- 2.39.2