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

Side by Side Diff: services/navigation/content_client/main_delegate.cc

Issue 1981623002: Add a basic browser to mash that uses the navigation service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 7 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "services/navigation/content_client/main_delegate.h" 5 #include "services/navigation/content_client/main_delegate.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "content/public/common/content_switches.h" 10 #include "content/public/common/content_switches.h"
(...skipping 11 matching lines...) Expand all
22 *base::CommandLine::ForCurrentProcess(); 22 *base::CommandLine::ForCurrentProcess();
23 std::string process_type = 23 std::string process_type =
24 command_line.GetSwitchValueASCII(switches::kProcessType); 24 command_line.GetSwitchValueASCII(switches::kProcessType);
25 25
26 content::SetContentClient(&content_client_); 26 content::SetContentClient(&content_client_);
27 27
28 return false; 28 return false;
29 } 29 }
30 30
31 void MainDelegate::PreSandboxStartup() { 31 void MainDelegate::PreSandboxStartup() {
32 base::FilePath path;
33 PathService::Get(base::DIR_MODULE, &path);
34 base::FilePath pak_path = path.Append(FILE_PATH_LITERAL("navigation.pak"));
35 ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_path);
32 ui::InitializeInputMethodForTesting(); 36 ui::InitializeInputMethodForTesting();
33 } 37 }
34 38
35 content::ContentBrowserClient* MainDelegate::CreateContentBrowserClient() { 39 content::ContentBrowserClient* MainDelegate::CreateContentBrowserClient() {
36 browser_client_.reset(new ContentBrowserClient); 40 browser_client_.reset(new ContentBrowserClient);
37 return browser_client_.get(); 41 return browser_client_.get();
38 } 42 }
39 43
40 } // namespace navigation 44 } // namespace navigation
OLDNEW
« no previous file with comments | « services/navigation/content_client/browser_main_parts.cc ('k') | services/navigation/manifest.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698