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

Unified Diff: remoting/host/continue_window_win.cc

Issue 1852143002: win: Remove GetModuleFromAddress, deduplicate __ImageBase code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 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 side-by-side diff with in-line comments
Download patch
Index: remoting/host/continue_window_win.cc
diff --git a/remoting/host/continue_window_win.cc b/remoting/host/continue_window_win.cc
index 548d9280fce26bdce39604dc587eb089614dd3d1..d0ac25607b4727f2e629ef871798414fe4a1ae71 100644
--- a/remoting/host/continue_window_win.cc
+++ b/remoting/host/continue_window_win.cc
@@ -10,9 +10,9 @@
#include "base/location.h"
#include "base/logging.h"
#include "base/macros.h"
-#include "base/process/memory.h"
#include "base/single_thread_task_runner.h"
#include "base/strings/utf_string_conversions.h"
+#include "base/win/current_module.h"
#include "remoting/host/continue_window.h"
#include "remoting/host/win/core_resource.h"
@@ -55,9 +55,8 @@ void ContinueWindowWin::ShowUi() {
DCHECK(CalledOnValidThread());
DCHECK(!hwnd_);
- HMODULE instance = base::GetModuleFromAddress(&DialogProc);
- hwnd_ = CreateDialogParam(instance, MAKEINTRESOURCE(IDD_CONTINUE), nullptr,
- (DLGPROC)DialogProc, (LPARAM)this);
+ hwnd_ = CreateDialogParam(CURRENT_MODULE(), MAKEINTRESOURCE(IDD_CONTINUE),
+ nullptr, (DLGPROC)DialogProc, (LPARAM) this);
joedow 2016/04/04 15:37:01 Why the extra space for 'this' and not in front of
Nico 2016/04/04 15:43:07 Excellent question. clang-format put it there, but
if (!hwnd_) {
LOG(ERROR) << "Unable to create Disconnect dialog for remoting.";
return;

Powered by Google App Engine
This is Rietveld 408576698