[Webkit-unassigned] [Bug 68610] Microdata: Basic implementation of document.getItems() method

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Oct 11 12:05:39 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=68610


Ryosuke Niwa <rniwa at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #110347|review?                     |review-
               Flag|                            |




--- Comment #13 from Ryosuke Niwa <rniwa at webkit.org>  2011-10-11 12:05:38 PST ---
(From update of attachment 110347)
View in context: https://bugs.webkit.org/attachment.cgi?id=110347&action=review

> Source/WebCore/dom/MicroDataItemList.cpp:58
> +    if (m_typeNames.contains("undefined") || !m_typeNames.size())

Are you trying to detect a case where the script didn't pass type? I don't think comparing it to the string 'undefined' is the right approach.

> Source/WebCore/dom/MicroDataItemList.h:49
> +    virtual bool nodeMatches(Element*) const;

Please use OVERRIDE macro.

> Source/WebCore/dom/NodeRareData.h:68
> +#if ENABLE(MICRODATA)
> +    typedef HashMap<String, MicroDataItemList*> MicroDataItemListCache;
> +    MicroDataItemListCache m_microDataItemListCache;
> +#endif

You also need to modify NodeListsNodeData::isEmpty.

> Source/WebCore/html/HTMLElement.cpp:201
> +#if ENABLE(MICRODATA)
> +    } else if (attr->name() == itemtypeAttr) {
> +        itemTypeAttributeChanged();
> +#endif

Please modify invalidateCachesThatDependOnAttributes instead. m_classNodeListCache is a good one to mimic. r- because of this.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list