[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-10851-g50815da

arv at chromium.org arv at chromium.org
Wed Dec 22 18:15:52 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit f8bc35798c8a4597f275a29a1542d9b7baa1d228
Author: arv at chromium.org <arv at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 9 03:55:39 2010 +0000

    2010-12-08  Erik Arvidsson  <arv at chromium.org>
    
            Reviewed by Darin Adler.
    
            Replace getAttribute().isNull() with fastHasAttribute()
            https://bugs.webkit.org/show_bug.cgi?id=50719
    
            Covered by existing tests.
    
            * dom/SelectElement.cpp:
            (WebCore::SelectElement::reset):
            * html/HTMLAppletElement.cpp:
            (WebCore::HTMLAppletElement::rendererIsNeeded):
            * html/HTMLCollection.cpp:
            (WebCore::HTMLCollection::itemAfter):
            * html/HTMLFormControlElement.cpp:
            (WebCore::HTMLFormControlElement::formNoValidate):
            * html/HTMLFormElement.cpp:
            (WebCore::HTMLFormElement::noValidate):
            * html/HTMLInputElement.cpp:
            (WebCore::HTMLInputElement::defaultChecked):
            (WebCore::HTMLInputElement::multiple):
            (WebCore::HTMLInputElement::webkitdirectory):
            * html/HTMLOptionElement.cpp:
            (WebCore::HTMLOptionElement::defaultSelected):
            * html/HTMLScriptElement.cpp:
            (WebCore::HTMLScriptElement::asyncAttributeValue):
            (WebCore::HTMLScriptElement::deferAttributeValue):
            * rendering/RenderFileUploadControl.cpp:
            (WebCore::RenderFileUploadControl::allowsMultipleFiles):
            (WebCore::RenderFileUploadControl::allowsDirectoryUpload):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73589 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 569a91a..63a6f17 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,35 @@
+2010-12-08  Erik Arvidsson  <arv at chromium.org>
+
+        Reviewed by Darin Adler.
+
+        Replace getAttribute().isNull() with fastHasAttribute()
+        https://bugs.webkit.org/show_bug.cgi?id=50719
+
+        Covered by existing tests.
+
+        * dom/SelectElement.cpp:
+        (WebCore::SelectElement::reset):
+        * html/HTMLAppletElement.cpp:
+        (WebCore::HTMLAppletElement::rendererIsNeeded):
+        * html/HTMLCollection.cpp:
+        (WebCore::HTMLCollection::itemAfter):
+        * html/HTMLFormControlElement.cpp:
+        (WebCore::HTMLFormControlElement::formNoValidate):
+        * html/HTMLFormElement.cpp:
+        (WebCore::HTMLFormElement::noValidate):
+        * html/HTMLInputElement.cpp:
+        (WebCore::HTMLInputElement::defaultChecked):
+        (WebCore::HTMLInputElement::multiple):
+        (WebCore::HTMLInputElement::webkitdirectory):
+        * html/HTMLOptionElement.cpp:
+        (WebCore::HTMLOptionElement::defaultSelected):
+        * html/HTMLScriptElement.cpp:
+        (WebCore::HTMLScriptElement::asyncAttributeValue):
+        (WebCore::HTMLScriptElement::deferAttributeValue):
+        * rendering/RenderFileUploadControl.cpp:
+        (WebCore::RenderFileUploadControl::allowsMultipleFiles):
+        (WebCore::RenderFileUploadControl::allowsDirectoryUpload):
+
 2010-12-08  Nicolas Dufresne  <nicolas.dufresne at collabora.co.uk>
 
         Reviewed by Martin Robinson.
diff --git a/WebCore/dom/SelectElement.cpp b/WebCore/dom/SelectElement.cpp
index d236c96..99e0c29 100644
--- a/WebCore/dom/SelectElement.cpp
+++ b/WebCore/dom/SelectElement.cpp
@@ -493,7 +493,7 @@ void SelectElement::reset(SelectElementData& data, Element* element)
         if (!optionElement)
             continue;
 
-        if (!items[i]->getAttribute(HTMLNames::selectedAttr).isNull()) {
+        if (items[i]->fastHasAttribute(HTMLNames::selectedAttr)) {
             if (selectedOption && !data.multiple())
                 selectedOption->setSelectedState(false);
             optionElement->setSelectedState(true);
diff --git a/WebCore/html/HTMLAppletElement.cpp b/WebCore/html/HTMLAppletElement.cpp
index d6b7c5a..9d06f92 100644
--- a/WebCore/html/HTMLAppletElement.cpp
+++ b/WebCore/html/HTMLAppletElement.cpp
@@ -101,7 +101,7 @@ void HTMLAppletElement::removedFromDocument()
 
 bool HTMLAppletElement::rendererIsNeeded(RenderStyle* style)
 {
-    if (getAttribute(codeAttr).isNull())
+    if (!fastHasAttribute(codeAttr))
         return false;
 
     return HTMLPlugInElement::rendererIsNeeded(style);
diff --git a/WebCore/html/HTMLCollection.cpp b/WebCore/html/HTMLCollection.cpp
index 7513be2..87e1d8b 100644
--- a/WebCore/html/HTMLCollection.cpp
+++ b/WebCore/html/HTMLCollection.cpp
@@ -181,11 +181,11 @@ Element* HTMLCollection::itemAfter(Element* previous) const
                     return e;
                 break;
             case DocLinks: // all <a> and <area> elements with a value for href
-                if ((e->hasLocalName(aTag) || e->hasLocalName(areaTag)) && (!e->getAttribute(hrefAttr).isNull()))
+                if ((e->hasLocalName(aTag) || e->hasLocalName(areaTag)) && e->fastHasAttribute(hrefAttr))
                     return e;
                 break;
             case DocAnchors: // all <a> elements with a value for name
-                if (e->hasLocalName(aTag) && !e->getAttribute(nameAttr).isNull())
+                if (e->hasLocalName(aTag) && e->fastHasAttribute(nameAttr))
                     return e;
                 break;
             case DocAll:
diff --git a/WebCore/html/HTMLFormControlElement.cpp b/WebCore/html/HTMLFormControlElement.cpp
index 7015fa2..8556c1e 100644
--- a/WebCore/html/HTMLFormControlElement.cpp
+++ b/WebCore/html/HTMLFormControlElement.cpp
@@ -86,7 +86,7 @@ void HTMLFormControlElement::detach()
 
 bool HTMLFormControlElement::formNoValidate() const
 {
-    return !getAttribute(formnovalidateAttr).isNull();
+    return fastHasAttribute(formnovalidateAttr);
 }
 
 void HTMLFormControlElement::parseMappedAttribute(Attribute* attr)
diff --git a/WebCore/html/HTMLFormElement.cpp b/WebCore/html/HTMLFormElement.cpp
index 79d622f..52669b5 100644
--- a/WebCore/html/HTMLFormElement.cpp
+++ b/WebCore/html/HTMLFormElement.cpp
@@ -530,7 +530,7 @@ String HTMLFormElement::name() const
 
 bool HTMLFormElement::noValidate() const
 {
-    return !getAttribute(novalidateAttr).isNull();
+    return fastHasAttribute(novalidateAttr);
 }
 
 // FIXME: This function should be removed because it does not do the same thing as the
diff --git a/WebCore/html/HTMLInputElement.cpp b/WebCore/html/HTMLInputElement.cpp
index f1f32ee..76f8665 100644
--- a/WebCore/html/HTMLInputElement.cpp
+++ b/WebCore/html/HTMLInputElement.cpp
@@ -1439,7 +1439,7 @@ void HTMLInputElement::setDefaultValue(const String &value)
 
 bool HTMLInputElement::defaultChecked() const
 {
-    return !getAttribute(checkedAttr).isNull();
+    return fastHasAttribute(checkedAttr);
 }
 
 void HTMLInputElement::setDefaultName(const AtomicString& name)
@@ -1472,13 +1472,13 @@ void HTMLInputElement::setMaxLength(int maxLength, ExceptionCode& ec)
 
 bool HTMLInputElement::multiple() const
 {
-    return !getAttribute(multipleAttr).isNull();
+    return fastHasAttribute(multipleAttr);
 }
 
 #if ENABLE(DIRECTORY_UPLOAD)
 bool HTMLInputElement::webkitdirectory() const
 {
-    return !getAttribute(webkitdirectoryAttr).isNull();
+    return fastHasAttribute(webkitdirectoryAttr);
 }
 #endif
 
diff --git a/WebCore/html/HTMLOptionElement.cpp b/WebCore/html/HTMLOptionElement.cpp
index 67c3567..e8f624c 100644
--- a/WebCore/html/HTMLOptionElement.cpp
+++ b/WebCore/html/HTMLOptionElement.cpp
@@ -205,7 +205,7 @@ HTMLSelectElement* HTMLOptionElement::ownerSelectElement() const
 
 bool HTMLOptionElement::defaultSelected() const
 {
-    return !getAttribute(selectedAttr).isNull();
+    return fastHasAttribute(selectedAttr);
 }
 
 void HTMLOptionElement::setDefaultSelected(bool b)
diff --git a/WebCore/html/HTMLScriptElement.cpp b/WebCore/html/HTMLScriptElement.cpp
index e229bb8..603b2a8 100644
--- a/WebCore/html/HTMLScriptElement.cpp
+++ b/WebCore/html/HTMLScriptElement.cpp
@@ -152,12 +152,12 @@ String HTMLScriptElement::eventAttributeValue() const
 
 bool HTMLScriptElement::asyncAttributeValue() const
 {
-    return !getAttribute(asyncAttr).isNull();
+    return fastHasAttribute(asyncAttr);
 }
 
 bool HTMLScriptElement::deferAttributeValue() const
 {
-    return !getAttribute(deferAttr).isNull();
+    return fastHasAttribute(deferAttr);
 }
 
 void HTMLScriptElement::dispatchLoadEvent()
diff --git a/WebCore/rendering/RenderFileUploadControl.cpp b/WebCore/rendering/RenderFileUploadControl.cpp
index 82bd1fa..3c10f43 100644
--- a/WebCore/rendering/RenderFileUploadControl.cpp
+++ b/WebCore/rendering/RenderFileUploadControl.cpp
@@ -100,14 +100,14 @@ bool RenderFileUploadControl::allowsMultipleFiles()
 #endif
 
     HTMLInputElement* input = static_cast<HTMLInputElement*>(node());
-    return !input->getAttribute(multipleAttr).isNull();
+    return input->fastHasAttribute(multipleAttr);
 }
 
 #if ENABLE(DIRECTORY_UPLOAD)
 bool RenderFileUploadControl::allowsDirectoryUpload()
 {
     HTMLInputElement* input = static_cast<HTMLInputElement*>(node());
-    return !input->getAttribute(webkitdirectoryAttr).isNull();
+    return input->fastHasAttribute(webkitdirectoryAttr);
 }
 #endif
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list