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

Side by Side Diff: ash/mus/sysui_application.cc

Issue 1962503002: Add mojom module suffix in .mojom files for components/filesystem. (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
« no previous file with comments | « no previous file | components/filesystem/directory_impl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "ash/mus/sysui_application.h" 5 #include "ash/mus/sysui_application.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 void InitializeResourceBundle(::shell::Connector* connector) { 241 void InitializeResourceBundle(::shell::Connector* connector) {
242 if (ui::ResourceBundle::HasSharedInstance()) 242 if (ui::ResourceBundle::HasSharedInstance())
243 return; 243 return;
244 244
245 std::set<std::string> resource_paths; 245 std::set<std::string> resource_paths;
246 resource_paths.insert(kResourceFileStrings); 246 resource_paths.insert(kResourceFileStrings);
247 resource_paths.insert(kResourceFile100); 247 resource_paths.insert(kResourceFile100);
248 resource_paths.insert(kResourceFile200); 248 resource_paths.insert(kResourceFile200);
249 249
250 catalog::ResourceLoader loader; 250 catalog::ResourceLoader loader;
251 filesystem::DirectoryPtr directory; 251 filesystem::mojom::DirectoryPtr directory;
252 connector->ConnectToInterface("mojo:catalog", &directory); 252 connector->ConnectToInterface("mojo:catalog", &directory);
253 CHECK(loader.OpenFiles(std::move(directory), resource_paths)); 253 CHECK(loader.OpenFiles(std::move(directory), resource_paths));
254 254
255 // Load ash resources and en-US strings; not 'common' (Chrome) resources. 255 // Load ash resources and en-US strings; not 'common' (Chrome) resources.
256 // TODO(msw): Check ResourceBundle::IsScaleFactorSupported; load 300% etc. 256 // TODO(msw): Check ResourceBundle::IsScaleFactorSupported; load 300% etc.
257 ui::ResourceBundle::InitSharedInstanceWithPakFileRegion( 257 ui::ResourceBundle::InitSharedInstanceWithPakFileRegion(
258 loader.TakeFile(kResourceFileStrings), 258 loader.TakeFile(kResourceFileStrings),
259 base::MemoryMappedFile::Region::kWholeFile); 259 base::MemoryMappedFile::Region::kWholeFile);
260 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); 260 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
261 rb.AddDataPackFromFile(loader.TakeFile(kResourceFile100), 261 rb.AddDataPackFromFile(loader.TakeFile(kResourceFile100),
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 void SysUIApplication::Create( 324 void SysUIApplication::Create(
325 ::shell::Connection* connection, 325 ::shell::Connection* connection,
326 mojo::InterfaceRequest<mash::shelf::mojom::ShelfController> request) { 326 mojo::InterfaceRequest<mash::shelf::mojom::ShelfController> request) {
327 mash::shelf::mojom::ShelfController* shelf_controller = 327 mash::shelf::mojom::ShelfController* shelf_controller =
328 static_cast<ShelfDelegateMus*>(Shell::GetInstance()->GetShelfDelegate()); 328 static_cast<ShelfDelegateMus*>(Shell::GetInstance()->GetShelfDelegate());
329 shelf_controller_bindings_.AddBinding(shelf_controller, std::move(request)); 329 shelf_controller_bindings_.AddBinding(shelf_controller, std::move(request));
330 } 330 }
331 331
332 } // namespace sysui 332 } // namespace sysui
333 } // namespace ash 333 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | components/filesystem/directory_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698