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

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

Issue 1402353011: Expose a function to get the path to a DLL. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: grt comment #17 (pass StringPiece16 by value) Created 5 years, 1 month 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/client_util.cc ('k') | chrome/app/main_dll_loader_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 // This file defines utility functions that can report details about the 5 // This file defines a class to load the main DLL of a Chrome process.
6 // host operating environment.
7 6
8 #ifndef CHROME_APP_CLIENT_UTIL_H_ 7 #ifndef CHROME_APP_MAIN_DLL_LOADER_WIN_H_
9 #define CHROME_APP_CLIENT_UTIL_H_ 8 #define CHROME_APP_MAIN_DLL_LOADER_WIN_H_
10 9
11 #include <windows.h> 10 #include <windows.h> // NOLINT
12 11
13 #include <string> 12 #include <string>
13
14 #include "base/files/file_path.h"
14 #include "base/strings/string16.h" 15 #include "base/strings/string16.h"
15 16
16 namespace sandbox {
17 struct SandboxInterfaceInfo;
18 }
19
20 // Returns the version in the current module's version resource or the empty
21 // string if none found.
22 base::string16 GetCurrentModuleVersion();
23
24 // Implements the common aspects of loading the main dll for both chrome and 17 // Implements the common aspects of loading the main dll for both chrome and
25 // chromium scenarios, which are in charge of implementing two abstract 18 // chromium scenarios, which are in charge of implementing two abstract
26 // methods: GetRegistryPath() and OnBeforeLaunch(). 19 // methods: GetRegistryPath() and OnBeforeLaunch().
27 class MainDllLoader { 20 class MainDllLoader {
28 public: 21 public:
29 MainDllLoader(); 22 MainDllLoader();
30 virtual ~MainDllLoader(); 23 virtual ~MainDllLoader();
31 24
32 // Loads and calls the entry point of chrome.dll. |instance| is the exe 25 // Loads and calls the entry point of chrome.dll. |instance| is the exe
33 // instance retrieved from wWinMain. 26 // instance retrieved from wWinMain.
(...skipping 28 matching lines...) Expand all
62 private: 55 private:
63 HMODULE dll_; 56 HMODULE dll_;
64 std::string process_type_; 57 std::string process_type_;
65 const bool metro_mode_; 58 const bool metro_mode_;
66 }; 59 };
67 60
68 // Factory for the MainDllLoader. Caller owns the pointer and should call 61 // Factory for the MainDllLoader. Caller owns the pointer and should call
69 // delete to free it. 62 // delete to free it.
70 MainDllLoader* MakeMainDllLoader(); 63 MainDllLoader* MakeMainDllLoader();
71 64
72 #endif // CHROME_APP_CLIENT_UTIL_H_ 65 #endif // CHROME_APP_MAIN_DLL_LOADER_WIN_H_
OLDNEW
« no previous file with comments | « chrome/app/client_util.cc ('k') | chrome/app/main_dll_loader_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698