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

Side by Side Diff: components/autofill/content/renderer/form_autofill_util.h

Issue 704133006: Cleanup: Remove FormWithElementIsAutofilled(). It's not used. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_ 5 #ifndef COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_
6 #define COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_ 6 #define COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 void PreviewForm(const FormData& form, 144 void PreviewForm(const FormData& form,
145 const blink::WebFormControlElement& element); 145 const blink::WebFormControlElement& element);
146 146
147 // Clears the placeholder values and the auto-filled background for any fields 147 // Clears the placeholder values and the auto-filled background for any fields
148 // in the form containing |node| that have been previewed. Resets the 148 // in the form containing |node| that have been previewed. Resets the
149 // autofilled state of |node| to |was_autofilled|. Returns false if the form is 149 // autofilled state of |node| to |was_autofilled|. Returns false if the form is
150 // not found. 150 // not found.
151 bool ClearPreviewedFormWithElement(const blink::WebFormControlElement& element, 151 bool ClearPreviewedFormWithElement(const blink::WebFormControlElement& element,
152 bool was_autofilled); 152 bool was_autofilled);
153 153
154 // Returns true if |form| has any auto-filled fields.
155 bool FormWithElementIsAutofilled(const blink::WebInputElement& element);
156
157 // Checks if the webpage is empty. 154 // Checks if the webpage is empty.
158 // This kind of webpage is considered as empty: 155 // This kind of webpage is considered as empty:
159 // <html> 156 // <html>
160 // <head> 157 // <head>
161 // <head/> 158 // <head/>
162 // <body> 159 // <body>
163 // <body/> 160 // <body/>
164 // <html/> 161 // <html/>
165 // Meta, script and title tags don't influence the emptiness of a webpage. 162 // Meta, script and title tags don't influence the emptiness of a webpage.
166 bool IsWebpageEmpty(const blink::WebFrame* frame); 163 bool IsWebpageEmpty(const blink::WebFrame* frame);
167 164
168 // This function checks whether the children of |element| 165 // This function checks whether the children of |element|
169 // are of the type <script>, <meta>, or <title>. 166 // are of the type <script>, <meta>, or <title>.
170 bool IsWebElementEmpty(const blink::WebElement& element); 167 bool IsWebElementEmpty(const blink::WebElement& element);
171 168
172 // Return a gfx::RectF that is the bounding box for |element| scaled by |scale|. 169 // Return a gfx::RectF that is the bounding box for |element| scaled by |scale|.
173 gfx::RectF GetScaledBoundingBox(float scale, 170 gfx::RectF GetScaledBoundingBox(float scale,
174 blink::WebFormControlElement* element); 171 blink::WebFormControlElement* element);
175 172
176 } // namespace autofill 173 } // namespace autofill
177 174
178 #endif // COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_ 175 #endif // COMPONENTS_AUTOFILL_CONTENT_RENDERER_FORM_AUTOFILL_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/renderer/autofill/form_autofill_browsertest.cc ('k') | components/autofill/content/renderer/form_autofill_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698