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

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

Issue 1269813002: Add a NavigationThrottle to the public content/ interface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@navigation-api
Patch Set: Addressed comments Created 5 years, 3 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
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "content/test/test_navigation_handle.h"
6
7 namespace content {
8 TestNavigationHandle::~TestNavigationHandle() {}
9
10 // static
11 TestNavigationHandle* TestNavigationHandle::Create(
12 const GURL& url,
13 const bool is_main_frame,
14 NavigatorDelegate* delegate) {
15 return new TestNavigationHandle(url, is_main_frame, delegate);
16 }
17
18 NavigationThrottle::ThrottleCheckResult
19 TestNavigationHandle::SimulateWillStartRequest(
20 bool is_post,
21 const Referrer& sanitized_referrer,
22 bool has_user_gesture,
23 ui::PageTransition transition,
24 bool is_external_protocol) {
25 return WillStartRequest(is_post, sanitized_referrer, has_user_gesture,
26 transition, is_external_protocol);
27 }
28
29 NavigationThrottle::ThrottleCheckResult
30 TestNavigationHandle::SimulateWillRedirectRequest(
31 const GURL& new_url,
32 bool new_method_is_post,
33 const GURL& new_referrer_url,
34 bool new_is_external_protocol) {
35 return WillRedirectRequest(new_url, new_method_is_post, new_referrer_url,
36 new_is_external_protocol);
37 }
38
39 TestNavigationHandle::TestNavigationHandle(const GURL& url,
40 const bool is_main_frame,
41 NavigatorDelegate* delegate)
42 : NavigationHandleImpl(url, is_main_frame, delegate) {}
43 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698