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

Side by Side Diff: content/browser/renderer_host/test_render_view_host.cc

Issue 19705013: [password autofill] Remove references to PasswordForm from RenderViewImpl (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | « content/browser/renderer_host/render_view_host_impl.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "content/browser/renderer_host/test_render_view_host.h" 5 #include "content/browser/renderer_host/test_render_view_host.h"
6 6
7 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" 7 #include "content/browser/dom_storage/dom_storage_context_wrapper.h"
8 #include "content/browser/dom_storage/session_storage_namespace_impl.h" 8 #include "content/browser/dom_storage/session_storage_namespace_impl.h"
9 #include "content/browser/renderer_host/test_backing_store.h" 9 #include "content/browser/renderer_host/test_backing_store.h"
10 #include "content/browser/site_instance_impl.h" 10 #include "content/browser/site_instance_impl.h"
11 #include "content/common/dom_storage/dom_storage_types.h" 11 #include "content/common/dom_storage/dom_storage_types.h"
12 #include "content/common/view_messages.h" 12 #include "content/common/view_messages.h"
13 #include "content/public/browser/browser_context.h" 13 #include "content/public/browser/browser_context.h"
14 #include "content/public/browser/navigation_controller.h" 14 #include "content/public/browser/navigation_controller.h"
15 #include "content/public/browser/storage_partition.h" 15 #include "content/public/browser/storage_partition.h"
16 #include "content/public/common/content_client.h" 16 #include "content/public/common/content_client.h"
17 #include "content/public/common/page_state.h" 17 #include "content/public/common/page_state.h"
18 #include "content/public/common/password_form.h"
19 #include "content/test/test_web_contents.h" 18 #include "content/test/test_web_contents.h"
20 #include "media/base/video_frame.h" 19 #include "media/base/video_frame.h"
21 #include "ui/gfx/rect.h" 20 #include "ui/gfx/rect.h"
22 #include "webkit/common/webpreferences.h" 21 #include "webkit/common/webpreferences.h"
23 22
24 namespace content { 23 namespace content {
25 24
26 namespace { 25 namespace {
27 26
28 const int64 kFrameId = 13UL; 27 const int64 kFrameId = 13UL;
29 28
30 } // namespace 29 } // namespace
31 30
32 31
33 void InitNavigateParams(ViewHostMsg_FrameNavigate_Params* params, 32 void InitNavigateParams(ViewHostMsg_FrameNavigate_Params* params,
34 int page_id, 33 int page_id,
35 const GURL& url, 34 const GURL& url,
36 PageTransition transition) { 35 PageTransition transition) {
37 params->page_id = page_id; 36 params->page_id = page_id;
38 params->url = url; 37 params->url = url;
39 params->referrer = Referrer(); 38 params->referrer = Referrer();
40 params->transition = transition; 39 params->transition = transition;
41 params->redirects = std::vector<GURL>(); 40 params->redirects = std::vector<GURL>();
42 params->should_update_history = false; 41 params->should_update_history = false;
43 params->searchable_form_url = GURL(); 42 params->searchable_form_url = GURL();
44 params->searchable_form_encoding = std::string(); 43 params->searchable_form_encoding = std::string();
45 params->password_form = PasswordForm();
46 params->security_info = std::string(); 44 params->security_info = std::string();
47 params->gesture = NavigationGestureUser; 45 params->gesture = NavigationGestureUser;
48 params->was_within_same_page = false; 46 params->was_within_same_page = false;
49 params->is_post = false; 47 params->is_post = false;
50 params->page_state = PageState::CreateFromURL(url); 48 params->page_state = PageState::CreateFromURL(url);
51 } 49 }
52 50
53 TestRenderWidgetHostView::TestRenderWidgetHostView(RenderWidgetHost* rwh) 51 TestRenderWidgetHostView::TestRenderWidgetHostView(RenderWidgetHost* rwh)
54 : rwh_(RenderWidgetHostImpl::From(rwh)), 52 : rwh_(RenderWidgetHostImpl::From(rwh)),
55 is_showing_(false), 53 is_showing_(false),
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 ViewHostMsg_FrameNavigate_Params params; 324 ViewHostMsg_FrameNavigate_Params params;
327 params.page_id = page_id; 325 params.page_id = page_id;
328 params.frame_id = kFrameId; 326 params.frame_id = kFrameId;
329 params.url = url; 327 params.url = url;
330 params.referrer = Referrer(); 328 params.referrer = Referrer();
331 params.transition = transition; 329 params.transition = transition;
332 params.redirects = std::vector<GURL>(); 330 params.redirects = std::vector<GURL>();
333 params.should_update_history = true; 331 params.should_update_history = true;
334 params.searchable_form_url = GURL(); 332 params.searchable_form_url = GURL();
335 params.searchable_form_encoding = std::string(); 333 params.searchable_form_encoding = std::string();
336 params.password_form = PasswordForm();
337 params.security_info = std::string(); 334 params.security_info = std::string();
338 params.gesture = NavigationGestureUser; 335 params.gesture = NavigationGestureUser;
339 params.contents_mime_type = contents_mime_type_; 336 params.contents_mime_type = contents_mime_type_;
340 params.is_post = false; 337 params.is_post = false;
341 params.was_within_same_page = false; 338 params.was_within_same_page = false;
342 params.http_status_code = response_code; 339 params.http_status_code = response_code;
343 params.socket_address.set_host("2001:db8::1"); 340 params.socket_address.set_host("2001:db8::1");
344 params.socket_address.set_port(80); 341 params.socket_address.set_port(80);
345 params.was_fetched_via_proxy = simulate_fetch_via_proxy_; 342 params.was_fetched_via_proxy = simulate_fetch_via_proxy_;
346 params.history_list_was_cleared = simulate_history_list_was_cleared_; 343 params.history_list_was_cleared = simulate_history_list_was_cleared_;
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 416
420 TestRenderViewHost* RenderViewHostImplTestHarness::active_test_rvh() { 417 TestRenderViewHost* RenderViewHostImplTestHarness::active_test_rvh() {
421 return static_cast<TestRenderViewHost*>(active_rvh()); 418 return static_cast<TestRenderViewHost*>(active_rvh());
422 } 419 }
423 420
424 TestWebContents* RenderViewHostImplTestHarness::contents() { 421 TestWebContents* RenderViewHostImplTestHarness::contents() {
425 return static_cast<TestWebContents*>(web_contents()); 422 return static_cast<TestWebContents*>(web_contents());
426 } 423 }
427 424
428 } // namespace content 425 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_view_host_impl.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698