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

Side by Side Diff: public/web/WebNode.h

Issue 1345423002: Introduce WebNode::querySelectorAll. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/web/WebNodeTest.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 16 matching lines...) Expand all
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #ifndef WebNode_h 31 #ifndef WebNode_h
32 #define WebNode_h 32 #define WebNode_h
33 33
34 #include "../platform/WebCommon.h" 34 #include "../platform/WebCommon.h"
35 #include "../platform/WebPrivatePtr.h" 35 #include "../platform/WebPrivatePtr.h"
36 #include "../platform/WebString.h" 36 #include "../platform/WebString.h"
37 #include "../platform/WebVector.h"
37 #include "WebExceptionCode.h" 38 #include "WebExceptionCode.h"
38 39
39 namespace blink { 40 namespace blink {
40 41
41 class Node; 42 class Node;
42 class WebAXObject; 43 class WebAXObject;
43 class WebDOMEvent; 44 class WebDOMEvent;
44 class WebDocument; 45 class WebDocument;
45 class WebElement; 46 class WebElement;
46 class WebElementCollection; 47 class WebElementCollection;
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 BLINK_EXPORT WebString createMarkup() const; 106 BLINK_EXPORT WebString createMarkup() const;
106 BLINK_EXPORT bool isLink() const; 107 BLINK_EXPORT bool isLink() const;
107 BLINK_EXPORT bool isTextNode() const; 108 BLINK_EXPORT bool isTextNode() const;
108 BLINK_EXPORT bool isFocusable() const; 109 BLINK_EXPORT bool isFocusable() const;
109 BLINK_EXPORT bool isContentEditable() const; 110 BLINK_EXPORT bool isContentEditable() const;
110 BLINK_EXPORT bool isElementNode() const; 111 BLINK_EXPORT bool isElementNode() const;
111 BLINK_EXPORT void dispatchEvent(const WebDOMEvent&); 112 BLINK_EXPORT void dispatchEvent(const WebDOMEvent&);
112 BLINK_EXPORT void simulateClick(); 113 BLINK_EXPORT void simulateClick();
113 // The argument should be lower-cased. 114 // The argument should be lower-cased.
114 BLINK_EXPORT WebElementCollection getElementsByHTMLTagName(const WebString&) const; 115 BLINK_EXPORT WebElementCollection getElementsByHTMLTagName(const WebString&) const;
115 BLINK_EXPORT WebElement querySelector(const WebString&, WebExceptionCode&) c onst; 116 BLINK_EXPORT WebElement querySelector(const WebString& selector, WebExceptio nCode&) const;
117 BLINK_EXPORT void querySelectorAll(const WebString& selector, WebExceptionCo de&, WebVector<WebElement>& results) const;
116 BLINK_EXPORT bool focused() const; 118 BLINK_EXPORT bool focused() const;
117 BLINK_EXPORT bool remove(); 119 BLINK_EXPORT bool remove();
118 120
119 // Returns true if the node has a non-empty bounding box in layout. 121 // Returns true if the node has a non-empty bounding box in layout.
120 // This does not 100% guarantee the user can see it, but is pretty close. 122 // This does not 100% guarantee the user can see it, but is pretty close.
121 // Note: This method only works properly after layout has occurred. 123 // Note: This method only works properly after layout has occurred.
122 BLINK_EXPORT bool hasNonEmptyBoundingBox() const; 124 BLINK_EXPORT bool hasNonEmptyBoundingBox() const;
123 125
124 BLINK_EXPORT bool containsIncludingShadowDOM(const WebNode&) const; 126 BLINK_EXPORT bool containsIncludingShadowDOM(const WebNode&) const;
125 BLINK_EXPORT WebPluginContainer* pluginContainer() const; 127 BLINK_EXPORT WebPluginContainer* pluginContainer() const;
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 } 176 }
175 177
176 inline bool operator<(const WebNode& a, const WebNode& b) 178 inline bool operator<(const WebNode& a, const WebNode& b)
177 { 179 {
178 return a.lessThan(b); 180 return a.lessThan(b);
179 } 181 }
180 182
181 } // namespace blink 183 } // namespace blink
182 184
183 #endif 185 #endif
OLDNEW
« no previous file with comments | « Source/web/WebNodeTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698