Update of /cvsroot/mahogany/M/src/classes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13704/src/classes
Modified Files:
MFolder.cpp Profile.cpp
Log Message:
removed ConfigSource parameter from Profile::writeEntty(); added Profile:: and
MFolder::SetConfigSourceForWriting()
Index: MFolder.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/classes/MFolder.cpp,v
retrieving revision 1.106
retrieving revision 1.107
diff -b -u -2 -r1.106 -r1.107
--- MFolder.cpp 4 Jul 2005 13:59:58 -0000 1.106
+++ MFolder.cpp 7 Jul 2005 18:48:44 -0000 1.107
@@ -198,4 +198,5 @@
virtual void SetFlags(int flags) { m_flags = flags; }
+ virtual void SetConfigSourceForWriting(ConfigSource * /* config */) { }
virtual Profile *GetProfile() const
{
@@ -319,4 +320,9 @@
virtual void SetFlags(int flags);
+ virtual void SetConfigSourceForWriting(ConfigSource *config)
+ {
+ m_profile->SetConfigSourceForWriting(config);
+ }
+
virtual Profile *GetProfile() const
{
Index: Profile.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/classes/Profile.cpp,v
retrieving revision 1.166
retrieving revision 1.167
diff -b -u -2 -r1.166 -r1.167
--- Profile.cpp 6 Jul 2005 22:05:04 -0000 1.166
+++ Profile.cpp 7 Jul 2005 18:48:44 -0000 1.167
@@ -4,5 +4,5 @@
// Purpose: implementation of Profile &c
// Author: Karsten Ballüder
-// Modified by: Vadim Zeitlin at 26.08.03 to use ConfigSource
+// Modified by: Vadim Zeitlin at 26.08.03 to use AllConfigSources
// Created: 1998
// CVS-ID: $Id$
@@ -125,14 +125,7 @@
int flags = Lookup_All) const;
- virtual bool writeEntry(const String& key,
- const String& value,
- ConfigSource *config = NULL);
- virtual bool writeEntry(const String & key,
- long value,
- ConfigSource *config = NULL);
- virtual bool writeEntryIfNeeded(const String& key,
- long value,
- long defvalue,
- ConfigSource *config = NULL);
+ virtual bool writeEntry(const String& key, const String& value);
+ virtual bool writeEntry(const String & key, long value);
+ virtual bool writeEntryIfNeeded(const String& key, long value, long def);
//@}
@@ -223,5 +216,5 @@
/// common part of all writeEntry() overloads
- bool DoWriteEntry(const LookupData& data, ConfigSource *config);
+ bool DoWriteEntry(const LookupData& data);
@@ -933,5 +926,5 @@
bool
-ProfileImpl::DoWriteEntry(const LookupData& data, ConfigSource *config)
+ProfileImpl::DoWriteEntry(const LookupData& data)
{
PCHECK();
@@ -949,30 +942,25 @@
}
- return gs_allConfigSources->Write(path, data, config);
+ return gs_allConfigSources->Write(path, data, GetConfigSourceForWriting());
}
bool
-ProfileImpl::writeEntry(const String& key,
- const String& value,
- ConfigSource *config)
+ProfileImpl::writeEntry(const String& key, const String& value)
{
LookupData ld(key, value);
- return DoWriteEntry(ld, config);
+ return DoWriteEntry(ld);
}
bool
-ProfileImpl::writeEntry(const String& key, long value, ConfigSource *config)
+ProfileImpl::writeEntry(const String& key, long value)
{
LookupData ld(key, value);
- return DoWriteEntry(ld, config);
+ return DoWriteEntry(ld);
}
bool
-ProfileImpl::writeEntryIfNeeded(const String& key,
- long value,
- long defvalue,
- ConfigSource *config)
+ProfileImpl::writeEntryIfNeeded(const String& key, long value, long defvalue)
{
if ( readEntry(key, defvalue) == value )
@@ -982,5 +970,5 @@
}
- return writeEntry(key, value, config);
+ return writeEntry(key, value);
}
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Mahogany-cvsupdates mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates