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

Side by Side Diff: blimp/engine/app/blimp_content_main_delegate.cc

Issue 2572563006: [Blimp] Refactor Blimp test engine with embedded test server and URL rewriting (Closed)
Patch Set: nit change Created 3 years, 11 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 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 "blimp/engine/app/blimp_content_main_delegate.h" 5 #include "blimp/engine/app/blimp_content_main_delegate.h"
6 6
7 #include "base/base_switches.h" 7 #include "base/base_switches.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/files/file.h" 9 #include "base/files/file.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 } 71 }
72 72
73 void BlimpContentMainDelegate::InitializeResourceBundle() { 73 void BlimpContentMainDelegate::InitializeResourceBundle() {
74 base::FilePath pak_file; 74 base::FilePath pak_file;
75 bool pak_file_valid = PathService::Get(base::DIR_MODULE, &pak_file); 75 bool pak_file_valid = PathService::Get(base::DIR_MODULE, &pak_file);
76 CHECK(pak_file_valid); 76 CHECK(pak_file_valid);
77 pak_file = pak_file.Append(FILE_PATH_LITERAL("blimp_engine.pak")); 77 pak_file = pak_file.Append(FILE_PATH_LITERAL("blimp_engine.pak"));
78 ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_file); 78 ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_file);
79 } 79 }
80 80
81 void BlimpContentMainDelegate::SetContentBrowserClientForTesting(
82 std::unique_ptr<BlimpContentBrowserClient> browser_client_ptr) {
83 browser_client_ = std::move(browser_client_ptr);
84 }
85
81 content::ContentBrowserClient* 86 content::ContentBrowserClient*
82 BlimpContentMainDelegate::CreateContentBrowserClient() { 87 BlimpContentMainDelegate::CreateContentBrowserClient() {
83 DCHECK(!browser_client_); 88 DCHECK(!browser_client_);
84 browser_client_.reset(new BlimpContentBrowserClient); 89 browser_client_.reset(new BlimpContentBrowserClient);
85 return browser_client_.get(); 90 return browser_client_.get();
86 } 91 }
87 92
88 content::ContentRendererClient* 93 content::ContentRendererClient*
89 BlimpContentMainDelegate::CreateContentRendererClient() { 94 BlimpContentMainDelegate::CreateContentRendererClient() {
90 DCHECK(!renderer_client_); 95 DCHECK(!renderer_client_);
91 renderer_client_.reset(new BlimpContentRendererClient); 96 renderer_client_.reset(new BlimpContentRendererClient);
92 return renderer_client_.get(); 97 return renderer_client_.get();
93 } 98 }
94 99
95 } // namespace engine 100 } // namespace engine
96 } // namespace blimp 101 } // namespace blimp
OLDNEW
« no previous file with comments | « blimp/engine/app/blimp_content_main_delegate.h ('k') | blimp/engine/testing/app/blimp_url_rewriter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698