[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    proko2: kdepim/kresources/kolab/shared
From:       Bo Thorsen <bo () sonofthor ! dk>
Date:       2004-07-15 14:51:44
Message-ID: 20040715145144.37BD6C21 () office ! kde ! org
[Download RAW message or body]

CVS commit by thorsen: 

Control the tagname instead of hardcoding it


  M +3 -3      kolabbase.cpp   1.1.2.9
  M +2 -1      kolabbase.h   1.1.2.7


--- kdepim/kresources/kolab/shared/kolabbase.cpp  #1.1.2.8:1.1.2.9
@@ -203,8 +203,8 @@ bool KolabBase::loadEmailAttribute( QDom
 }
 
-void KolabBase::saveEmailAttribute( QDomElement& element,
-                                    const Email& email ) const
+void KolabBase::saveEmailAttribute( QDomElement& element, const Email& email,
+                                    const QString& tagName ) const
 {
-  QDomElement e = element.ownerDocument().createElement( "email" );
+  QDomElement e = element.ownerDocument().createElement( tagName );
   element.appendChild( e );
   writeString( e, "display-name", email.displayName );

--- kdepim/kresources/kolab/shared/kolabbase.h  #1.1.2.6:1.1.2.7
@@ -127,5 +127,6 @@ protected:
   bool loadEmailAttribute( QDomElement& element, Email& email );
 
-  void saveEmailAttribute( QDomElement& element, const Email& email ) const;
+  void saveEmailAttribute( QDomElement& element, const Email& email,
+                           const QString& tagName = "email" ) const;
 
   // Load the attributes of this class


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic