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

List:       kde-commits
Subject:    kdenonbeta/kdom/core
From:       Rob Buis <rwlbuis () xs4all ! nl>
Date:       2005-12-12 22:00:59
Message-ID: 1134424859.145501.30300.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 488026 by buis:

- fixes for 64-bit system and sourcedir != builddir by Vincent Ricard.
- adding convenience method setAttribute that ignores exception.



 M  +3 -3      DocumentImpl.cpp  
 M  +6 -0      ElementImpl.cpp  
 M  +1 -0      ElementImpl.h  
 M  +7 -5      Makefile.am  


--- trunk/kdenonbeta/kdom/core/DocumentImpl.cpp #488025:488026
@@ -689,7 +689,7 @@
         m_elementsById.insert(qId, element);
         //m_accessKeyDictValid = false;
     } else {
-        int idCount = (int)m_idCount.find(qId);
+        intptr_t idCount = (intptr_t)m_idCount.find(qId);
         m_idCount.insert(qId, (char *)(idCount + 1));
     }
 }
@@ -702,7 +702,7 @@
         m_elementsById.remove(qId);
         //m_accessKeyDictValid = false;
     } else {
-        int idCount = (int)m_idCount.find(qId);        
+        intptr_t idCount = (intptr_t)m_idCount.find(qId);        
         assert(idCount > 0);
         if (idCount == 1) 
             m_idCount.remove(qId);
@@ -727,7 +727,7 @@
     if (element)
         return element;
         
-    if (int idCount = (int)m_idCount.find(qId)) {
+    if (intptr_t idCount = (intptr_t)m_idCount.find(qId)) {
         for (NodeImpl *n = traverseNextNode(); n != 0; n = n->traverseNextNode()) {
             if (!isElementNode(n))
                 continue;
--- trunk/kdenonbeta/kdom/core/ElementImpl.cpp #488025:488026
@@ -148,6 +148,12 @@
     return attrs->getAttributeItem(QualifiedName(nullAtom, localName, \
namespaceURI));  }
 
+void ElementImpl::setAttribute(const QualifiedName& name, DOMStringImpl *value)
+{
+    int exceptioncode = 0;
+	setAttribute(name, value, exceptioncode);
+}
+
 void ElementImpl::setAttribute(const QualifiedName& name, DOMStringImpl *value, int \
&exceptioncode)  {
     //if (inDocument())
--- trunk/kdenonbeta/kdom/core/ElementImpl.h #488025:488026
@@ -77,6 +77,7 @@
         bool hasAttribute(const QualifiedName &name) const;
         bool hasAttribute(DOMStringImpl *name) const { int dummy; return \
                hasAttributeNS(0, name, dummy); }
         bool hasAttributeNS(DOMStringImpl *namespaceURI, DOMStringImpl *localName, \
int &exceptioncode) const; +        void setAttribute(const QualifiedName& name, \
                DOMStringImpl* value);
         void setAttribute(const QualifiedName& name, DOMStringImpl* value, int \
&exceptioncode);  
         virtual NamedAttrMapImpl *attributes() const;
--- trunk/kdenonbeta/kdom/core/Makefile.am #488025:488026
@@ -8,12 +8,14 @@
 	 -I$(top_srcdir)/kdom/xpath -I$(top_srcdir)/kdom/cache \
 	 $(all_includes)
 
-XLinkNames.cpp:
-	../scripts/make_names.pl --attrs xlinkattrs.in --namespace XLink --cppNamespace \
KDOM --namespaceURI http://www.w3.org/1999/xlink  +CLEANFILES = \
$(top_srcdir)/kdom/core/XLinkNames.cpp $(top_srcdir)/kdom/core/XMLNames.cpp  
-XMLNames.cpp:
-	../scripts/make_names.pl --attrs xmlattrs.in --namespace XML --cppNamespace KDOM \
--namespaceURI http://www.w3.org/XML/1998/namespace \
+$(top_srcdir)/kdom/core/XLinkNames.cpp: +	$(top_srcdir)/kdom/scripts/make_names.pl \
--attrs $(top_srcdir)/kdom/core/xlinkattrs.in --namespace XLink --cppNamespace KDOM \
--namespaceURI http://www.w3.org/1999/xlink --outputDir $(top_srcdir)/kdom/core  
+$(top_srcdir)/kdom/core/XMLNames.cpp:
+	$(top_srcdir)/kdom/scripts/make_names.pl --attrs \
$(top_srcdir)/kdom/core/xmlattrs.in --namespace XML --cppNamespace KDOM \
--namespaceURI http://www.w3.org/XML/1998/namespace --outputDir \
$(top_srcdir)/kdom/core +
 noinst_LTLIBRARIES = libkdomimpl.la
 libkdomimpl_la_SOURCES = QualifiedName.cpp NodeImpl.cpp NodeListImpl.cpp \
TagNodeListImpl.cpp NamedNodeMapImpl.cpp \  NamedAttrMapImpl.cpp ElementImpl.cpp \
AttrImpl.cpp DocumentImpl.cpp \ @@ -36,4 +38,4 @@
 			DOMImplementationImpl.h DOMStringImpl.h \
 			DOMStringListImpl.h DOMConfigurationImpl.h DOMUserDataImpl.h \
 			DOMLocatorImpl.h DOMErrorImpl.h TypeInfoImpl.h CDFInterface.h \
-			DOMErrorHandlerImpl.h DOMObjectImpl.h SharedPtr.h 
+			DOMErrorHandlerImpl.h DOMObjectImpl.h SharedPtr.h


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

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