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

Side by Side Diff: content/test/test_render_view_host.cc

Issue 88503002: Have the unload event execute in background on cross-site navigations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Keeping the old rvh alive for up to 1s Created 7 years 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
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/test/test_render_view_host.h" 5 #include "content/test/test_render_view_host.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" 8 #include "content/browser/dom_storage/dom_storage_context_wrapper.h"
9 #include "content/browser/dom_storage/session_storage_namespace_impl.h" 9 #include "content/browser/dom_storage/session_storage_namespace_impl.h"
10 #include "content/browser/site_instance_impl.h" 10 #include "content/browser/site_instance_impl.h"
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 void TestRenderViewHost::SendShouldCloseACK(bool proceed) { 361 void TestRenderViewHost::SendShouldCloseACK(bool proceed) {
362 base::TimeTicks now = base::TimeTicks::Now(); 362 base::TimeTicks now = base::TimeTicks::Now();
363 OnShouldCloseACK(proceed, now, now); 363 OnShouldCloseACK(proceed, now, now);
364 } 364 }
365 365
366 void TestRenderViewHost::SetContentsMimeType(const std::string& mime_type) { 366 void TestRenderViewHost::SetContentsMimeType(const std::string& mime_type) {
367 contents_mime_type_ = mime_type; 367 contents_mime_type_ = mime_type;
368 } 368 }
369 369
370 void TestRenderViewHost::SimulateSwapOutACK() { 370 void TestRenderViewHost::SimulateSwapOutACK() {
371 OnSwappedOut(false); 371 OnSwappedOut(false, false);
372 } 372 }
373 373
374 void TestRenderViewHost::SimulateWasHidden() { 374 void TestRenderViewHost::SimulateWasHidden() {
375 WasHidden(); 375 WasHidden();
376 } 376 }
377 377
378 void TestRenderViewHost::SimulateWasShown() { 378 void TestRenderViewHost::SimulateWasShown() {
379 WasShown(); 379 WasShown();
380 } 380 }
381 381
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
425 425
426 TestRenderViewHost* RenderViewHostImplTestHarness::active_test_rvh() { 426 TestRenderViewHost* RenderViewHostImplTestHarness::active_test_rvh() {
427 return static_cast<TestRenderViewHost*>(active_rvh()); 427 return static_cast<TestRenderViewHost*>(active_rvh());
428 } 428 }
429 429
430 TestWebContents* RenderViewHostImplTestHarness::contents() { 430 TestWebContents* RenderViewHostImplTestHarness::contents() {
431 return static_cast<TestWebContents*>(web_contents()); 431 return static_cast<TestWebContents*>(web_contents());
432 } 432 }
433 433
434 } // namespace content 434 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698