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

Side by Side Diff: chrome/app/main_dll_loader_win.cc

Issue 2769023004: Cloud Print process type: service -> cloud-print-service (Closed)
Patch Set: . Created 3 years, 9 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 | « chrome/app/chrome_main_delegate.cc ('k') | chrome/common/chrome_paths_win.cc » ('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 (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/app/main_dll_loader_win.h" 5 #include "chrome/app/main_dll_loader_win.h"
6 6
7 #include <windows.h> // NOLINT 7 #include <windows.h> // NOLINT
8 #include <shlwapi.h> // NOLINT 8 #include <shlwapi.h> // NOLINT
9 #include <stddef.h> 9 #include <stddef.h>
10 #include <stdint.h> 10 #include <stdint.h>
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 62
63 void RecordDidRun(const base::FilePath& dll_path) { 63 void RecordDidRun(const base::FilePath& dll_path) {
64 GoogleUpdateSettings::UpdateDidRunState(true); 64 GoogleUpdateSettings::UpdateDidRunState(true);
65 } 65 }
66 66
67 void ClearDidRun(const base::FilePath& dll_path) { 67 void ClearDidRun(const base::FilePath& dll_path) {
68 GoogleUpdateSettings::UpdateDidRunState(false); 68 GoogleUpdateSettings::UpdateDidRunState(false);
69 } 69 }
70 70
71 bool ProcessTypeUsesMainDll(const std::string& process_type) { 71 bool ProcessTypeUsesMainDll(const std::string& process_type) {
72 return process_type.empty() || process_type == switches::kServiceProcess; 72 return process_type.empty() ||
73 process_type == switches::kCloudPrintServiceProcess;
73 } 74 }
74 75
75 // Indicates whether a file can be opened using the same flags that 76 // Indicates whether a file can be opened using the same flags that
76 // ::LoadLibrary() uses to open modules. 77 // ::LoadLibrary() uses to open modules.
77 bool ModuleCanBeRead(const base::FilePath& file_path) { 78 bool ModuleCanBeRead(const base::FilePath& file_path) {
78 return base::File(file_path, base::File::FLAG_OPEN | base::File::FLAG_READ) 79 return base::File(file_path, base::File::FLAG_OPEN | base::File::FLAG_READ)
79 .IsValid(); 80 .IsValid();
80 } 81 }
81 82
82 // Returns the full path to |module_name|. Both dev builds (where |module_name| 83 // Returns the full path to |module_name|. Both dev builds (where |module_name|
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 } 282 }
282 }; 283 };
283 284
284 MainDllLoader* MakeMainDllLoader() { 285 MainDllLoader* MakeMainDllLoader() {
285 #if defined(GOOGLE_CHROME_BUILD) 286 #if defined(GOOGLE_CHROME_BUILD)
286 return new ChromeDllLoader(); 287 return new ChromeDllLoader();
287 #else 288 #else
288 return new ChromiumDllLoader(); 289 return new ChromiumDllLoader();
289 #endif 290 #endif
290 } 291 }
OLDNEW
« no previous file with comments | « chrome/app/chrome_main_delegate.cc ('k') | chrome/common/chrome_paths_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698