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

Side by Side Diff: chrome_frame/test/net/test_automation_provider.cc

Issue 10918279: Provide mutable members of UrlRequestContext via pure-virtual interface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: const-ify HUAS getters Created 8 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 | 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 "chrome_frame/test/net/test_automation_provider.h" 5 #include "chrome_frame/test/net/test_automation_provider.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_version_info.h" 8 #include "base/file_version_info.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "chrome/common/automation_messages.h" 10 #include "chrome/common/automation_messages.h"
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 if (g_provider_instance_ && request->GetUserData(NULL) == NULL && 86 if (g_provider_instance_ && request->GetUserData(NULL) == NULL &&
87 g_provider_instance_->tab_handle_ != -1) { 87 g_provider_instance_->tab_handle_ != -1) {
88 // We generate our own request id which is also what 88 // We generate our own request id which is also what
89 // ResourceDispatcherHost does (well, the id is actually generated by 89 // ResourceDispatcherHost does (well, the id is actually generated by
90 // ResourceDispatcher). Since these requests are divided into with 90 // ResourceDispatcher). Since these requests are divided into with
91 // and without userdata, we're OK. However, just to make debugging 91 // and without userdata, we're OK. However, just to make debugging
92 // a little easier, we have a significantly higher start value. 92 // a little easier, we have a significantly higher start value.
93 static int new_id = 0x00100000; 93 static int new_id = 0x00100000;
94 URLRequestAutomationJob* job = new URLRequestAutomationJob( 94 URLRequestAutomationJob* job = new URLRequestAutomationJob(
95 request, network_delegate, 95 request, network_delegate,
96 request->context()->http_user_agent_settings(),
96 g_provider_instance_->tab_handle_, new_id++, 97 g_provider_instance_->tab_handle_, new_id++,
97 g_provider_instance_->automation_resource_message_filter_, false); 98 g_provider_instance_->automation_resource_message_filter_, false);
98 return job; 99 return job;
99 } 100 }
100 } 101 }
101 102
102 return NULL; 103 return NULL;
103 } 104 }
104 105
105 std::string TestAutomationProvider::GetProtocolVersion() { 106 std::string TestAutomationProvider::GetProtocolVersion() {
(...skipping 20 matching lines...) Expand all
126 127
127 // static 128 // static
128 TestAutomationProvider* TestAutomationProvider::NewAutomationProvider( 129 TestAutomationProvider* TestAutomationProvider::NewAutomationProvider(
129 Profile* p, const std::string& channel, 130 Profile* p, const std::string& channel,
130 TestAutomationProviderDelegate* delegate) { 131 TestAutomationProviderDelegate* delegate) {
131 TestAutomationProvider* automation = new TestAutomationProvider(p, delegate); 132 TestAutomationProvider* automation = new TestAutomationProvider(p, delegate);
132 automation->InitializeChannel(channel); 133 automation->InitializeChannel(channel);
133 automation->SetExpectedTabCount(1); 134 automation->SetExpectedTabCount(1);
134 return automation; 135 return automation;
135 } 136 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698