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

Unified Diff: chrome/renderer/autofill/form_cache.h

Issue 12434004: Move remaining Autofill code to //components/autofill. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix long lines Created 7 years, 9 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
« no previous file with comments | « chrome/renderer/autofill/form_autofill_util.cc ('k') | chrome/renderer/autofill/form_cache.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/autofill/form_cache.h
diff --git a/chrome/renderer/autofill/form_cache.h b/chrome/renderer/autofill/form_cache.h
deleted file mode 100644
index b235d21480a53dc45ce54a2c6869103b10df41ae..0000000000000000000000000000000000000000
--- a/chrome/renderer/autofill/form_cache.h
+++ /dev/null
@@ -1,74 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_RENDERER_AUTOFILL_FORM_CACHE_H_
-#define CHROME_RENDERER_AUTOFILL_FORM_CACHE_H_
-
-#include <map>
-#include <set>
-#include <vector>
-
-#include "base/string16.h"
-
-struct FormData;
-struct FormDataPredictions;
-
-namespace WebKit {
-class WebDocument;
-class WebFormElement;
-class WebFrame;
-class WebInputElement;
-class WebSelectElement;
-}
-
-namespace autofill {
-
-// Manages the forms in a RenderView.
-class FormCache {
- public:
- FormCache();
- ~FormCache();
-
- // Scans the DOM in |frame| extracting and storing forms.
- // Returns a vector of the extracted forms.
- void ExtractForms(const WebKit::WebFrame& frame,
- std::vector<FormData>* forms);
-
- // Scans the DOM in |frame| extracting and storing forms.
- // Returns a vector of the extracted forms and vector of associated web
- // form elements.
- void ExtractFormsAndFormElements(
- const WebKit::WebFrame& frame,
- std::vector<FormData>* forms,
- std::vector<WebKit::WebFormElement>* web_form_elements);
-
- // Resets the forms for the specified |frame|.
- void ResetFrame(const WebKit::WebFrame& frame);
-
- // Clears the values of all input elements in the form that contains
- // |element|. Returns false if the form is not found.
- bool ClearFormWithElement(const WebKit::WebInputElement& element);
-
- // For each field in the |form|, sets the field's placeholder text to the
- // field's overall predicted type. Also sets the title to include the field's
- // heuristic type, server type, and signature; as well as the form's signature
- // and the experiment id for the server predictions.
- bool ShowPredictions(const FormDataPredictions& form);
-
- private:
- // The cached web frames.
- std::set<WebKit::WebDocument> web_documents_;
-
- // The cached initial values for <select> elements.
- std::map<const WebKit::WebSelectElement, string16> initial_select_values_;
-
- // The cached initial values for checkable <input> elements.
- std::map<const WebKit::WebInputElement, bool> initial_checked_state_;
-
- DISALLOW_COPY_AND_ASSIGN(FormCache);
-};
-
-} // namespace autofill
-
-#endif // CHROME_RENDERER_AUTOFILL_FORM_CACHE_H_
« no previous file with comments | « chrome/renderer/autofill/form_autofill_util.cc ('k') | chrome/renderer/autofill/form_cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698