diff options
author | darin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-15 17:21:10 +0000 |
---|---|---|
committer | darin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-15 17:21:10 +0000 |
commit | daa8c58ee49795d292312bbf217999c93693919c (patch) | |
tree | 561a327f148d74b0522871f15103e25a27b841f5 /chrome/browser/tab_contents | |
parent | 0b97342d07fd3ef047432b52809d31d10432ee85 (diff) | |
download | chromium_src-daa8c58ee49795d292312bbf217999c93693919c.zip chromium_src-daa8c58ee49795d292312bbf217999c93693919c.tar.gz chromium_src-daa8c58ee49795d292312bbf217999c93693919c.tar.bz2 |
Extract form related classes from the guts of WebFrameImpl.
Instead of having WebFrameImpl generate SearchableFormData, PasswordForm, and AutofillForm classes, allow the embedder (RenderView) to do so.
This is done to help minimize the dependencies WebFrameImpl has on other code, which will make it easier to move WebFrame and WebDataSource into the WebKit API.
Most significant change: Now, RenderView always sets a NavigationState on WebDataSource instances. We used to only do so for browser initiated navigations. This is done so that we can store things like SearchableFormData and friends on the NavigationState.
To facilitate this change, it was necessary to add a way through the WebKit API to refer to a HTMLFormElement. This CL introduces WebForm, which is like a RefPtr<HTMLFormElement>, so you can just copy a WebForm around by value and the right thing happens.
Some of the other changes are about moving more things into the webkit_glue namespace. On hindsight, I probably should have done that as a separate CL.
BUG=10041
TEST=none
R=brettw
Review URL: http://codereview.chromium.org/126083
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18395 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_contents')
-rw-r--r-- | chrome/browser/tab_contents/tab_contents.cc | 2 | ||||
-rw-r--r-- | chrome/browser/tab_contents/tab_contents.h | 8 |
2 files changed, 7 insertions, 3 deletions
diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc index 06ffba6..0ccd724 100644 --- a/chrome/browser/tab_contents/tab_contents.cc +++ b/chrome/browser/tab_contents/tab_contents.cc @@ -1960,7 +1960,7 @@ void TabContents::PasswordFormsSeen( } void TabContents::AutofillFormSubmitted( - const AutofillForm& form) { + const webkit_glue::AutofillForm& form) { GetAutofillManager()->AutofillFormSubmitted(form); } diff --git a/chrome/browser/tab_contents/tab_contents.h b/chrome/browser/tab_contents/tab_contents.h index c496b51..d57f221 100644 --- a/chrome/browser/tab_contents/tab_contents.h +++ b/chrome/browser/tab_contents/tab_contents.h @@ -48,20 +48,24 @@ namespace gfx { class Rect; class Size; } + namespace views { class WindowDelegate; } + namespace base { class WaitableEvent; } + namespace webkit_glue { +class AutofillForm; struct WebApplicationInfo; } + namespace IPC { class Message; } -class AutofillForm; class AutofillManager; class BlockedPopupContainer; class DOMUI; @@ -801,7 +805,7 @@ class TabContents : public PageNavigator, const std::string& json_arguments, IPC::Message* reply_msg); virtual void PasswordFormsSeen(const std::vector<PasswordForm>& forms); - virtual void AutofillFormSubmitted(const AutofillForm& form); + virtual void AutofillFormSubmitted(const webkit_glue::AutofillForm& form); virtual void GetAutofillSuggestions(const std::wstring& field_name, const std::wstring& user_text, int64 node_id, int request_id); virtual void RemoveAutofillEntry(const std::wstring& field_name, |