| OLD | NEW |
| 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 #undef LOG | 5 #undef LOG |
| 6 | 6 |
| 7 #include "webkit/tools/test_shell/test_shell.h" | 7 #include "webkit/tools/test_shell/test_shell.h" |
| 8 | 8 |
| 9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 FilePath path; | 87 FilePath path; |
| 88 PathService::Get(base::DIR_EXE, &path); | 88 PathService::Get(base::DIR_EXE, &path); |
| 89 path = path.AppendASCII("resources"); | 89 path = path.AppendASCII("resources"); |
| 90 path = path.AppendASCII("inspector"); | 90 path = path.AppendASCII("inspector"); |
| 91 path = path.AppendASCII(request->url().path().substr(1)); | 91 path = path.AppendASCII(request->url().path().substr(1)); |
| 92 return new URLRequestTestShellFileJob(request, path); | 92 return new URLRequestTestShellFileJob(request, path); |
| 93 } | 93 } |
| 94 | 94 |
| 95 private: | 95 private: |
| 96 URLRequestTestShellFileJob(net::URLRequest* request, const FilePath& path) | 96 URLRequestTestShellFileJob(net::URLRequest* request, const FilePath& path) |
| 97 : net::URLRequestFileJob(request, path) { | 97 : net::URLRequestFileJob(request, |
| 98 path, |
| 99 request->context()->network_delegate()) { |
| 98 } | 100 } |
| 99 virtual ~URLRequestTestShellFileJob() { } | 101 virtual ~URLRequestTestShellFileJob() { } |
| 100 | 102 |
| 101 DISALLOW_COPY_AND_ASSIGN(URLRequestTestShellFileJob); | 103 DISALLOW_COPY_AND_ASSIGN(URLRequestTestShellFileJob); |
| 102 }; | 104 }; |
| 103 | 105 |
| 104 | 106 |
| 105 } // namespace | 107 } // namespace |
| 106 | 108 |
| 107 // Initialize static member variable | 109 // Initialize static member variable |
| (...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 611 return device_orientation_client_mock_.get(); | 613 return device_orientation_client_mock_.get(); |
| 612 } | 614 } |
| 613 | 615 |
| 614 WebKit::WebGeolocationClientMock* TestShell::geolocation_client_mock() { | 616 WebKit::WebGeolocationClientMock* TestShell::geolocation_client_mock() { |
| 615 if (!geolocation_client_mock_.get()) { | 617 if (!geolocation_client_mock_.get()) { |
| 616 geolocation_client_mock_.reset( | 618 geolocation_client_mock_.reset( |
| 617 WebKit::WebGeolocationClientMock::create()); | 619 WebKit::WebGeolocationClientMock::create()); |
| 618 } | 620 } |
| 619 return geolocation_client_mock_.get(); | 621 return geolocation_client_mock_.get(); |
| 620 } | 622 } |
| OLD | NEW |