Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(531)

Unified Diff: Source/core/dom/LiveNodeList.h

Issue 229213002: Make HTMLCollection / NodeList backward traversal consistent with forward one (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/dom/LiveNodeList.h
diff --git a/Source/core/dom/LiveNodeList.h b/Source/core/dom/LiveNodeList.h
index 67c61e488e368460f42fbb1a1ad298a2dec87864..bdc6e64e650328080aa1907ba2df083bc873f23a 100644
--- a/Source/core/dom/LiveNodeList.h
+++ b/Source/core/dom/LiveNodeList.h
@@ -50,9 +50,10 @@ public:
// Collection IndexCache API.
bool canTraverseBackward() const { return true; }
- Element* itemBefore(const Element* previousItem) const;
Element* traverseToFirstElement() const;
+ Element* traverseToLastElement() const;
Element* traverseForwardToOffset(unsigned offset, Element& currentNode, unsigned& currentOffset) const;
+ Element* traverseBackwardToOffset(unsigned offset, Element& currentNode, unsigned& currentOffset) const;
private:
virtual Node* virtualOwnerNode() const OVERRIDE FINAL;

Powered by Google App Engine
This is Rietveld 408576698