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

Side by Side Diff: chrome/browser/web_resource/resource_request_allowed_notifier_test_util.cc

Issue 739173002: Remove dependencies of ResourceRequestAllowedNotifier on chrome/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and cleanup Created 6 years, 1 month 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
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "chrome/browser/web_resource/resource_request_allowed_notifier_test_uti l.h" 5 #include "chrome/browser/web_resource/resource_request_allowed_notifier_test_uti l.h"
6 6
7 TestRequestAllowedNotifier::TestRequestAllowedNotifier() 7 TestRequestAllowedNotifier::TestRequestAllowedNotifier(PrefService* local_state)
8 : override_requests_allowed_(false), 8 : ResourceRequestAllowedNotifier(local_state),
9 override_requests_allowed_(false),
9 requests_allowed_(true) { 10 requests_allowed_(true) {
10 } 11 }
11 12
12 TestRequestAllowedNotifier::~TestRequestAllowedNotifier() { 13 TestRequestAllowedNotifier::~TestRequestAllowedNotifier() {
13 } 14 }
14 15
15 void TestRequestAllowedNotifier::InitWithEulaAcceptNotifier( 16 void TestRequestAllowedNotifier::InitWithEulaAcceptNotifier(
16 Observer* observer, 17 Observer* observer,
17 scoped_ptr<EulaAcceptedNotifier> eula_notifier) { 18 scoped_ptr<EulaAcceptedNotifier> eula_notifier) {
18 test_eula_notifier_.swap(eula_notifier); 19 test_eula_notifier_.swap(eula_notifier);
(...skipping 18 matching lines...) Expand all
37 ResourceRequestAllowedNotifier::State 38 ResourceRequestAllowedNotifier::State
38 TestRequestAllowedNotifier::GetResourceRequestsAllowedState() { 39 TestRequestAllowedNotifier::GetResourceRequestsAllowedState() {
39 if (override_requests_allowed_) 40 if (override_requests_allowed_)
40 return requests_allowed_ ? ALLOWED : DISALLOWED_NETWORK_DOWN; 41 return requests_allowed_ ? ALLOWED : DISALLOWED_NETWORK_DOWN;
41 return ResourceRequestAllowedNotifier::GetResourceRequestsAllowedState(); 42 return ResourceRequestAllowedNotifier::GetResourceRequestsAllowedState();
42 } 43 }
43 44
44 EulaAcceptedNotifier* TestRequestAllowedNotifier::CreateEulaNotifier() { 45 EulaAcceptedNotifier* TestRequestAllowedNotifier::CreateEulaNotifier() {
45 return test_eula_notifier_.release(); 46 return test_eula_notifier_.release();
46 } 47 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698