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

Unified Diff: remoting/host/verify_config_window_win.cc

Issue 810133003: replace NULL->nullptr in src/remoting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « remoting/host/username.cc ('k') | remoting/host/video_frame_recorder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/verify_config_window_win.cc
diff --git a/remoting/host/verify_config_window_win.cc b/remoting/host/verify_config_window_win.cc
index d6793cc0067327fe3069d5003a6af2d8ba9be66d..ff00a95a5ded58a0c43fe62b560c6017efcf4859 100644
--- a/remoting/host/verify_config_window_win.cc
+++ b/remoting/host/verify_config_window_win.cc
@@ -36,7 +36,7 @@ void VerifyConfigWindowWin::OnClose() {
LRESULT VerifyConfigWindowWin::OnInitDialog(HWND wparam, LPARAM lparam) {
// Set the small window icon.
if (icon_.LoadIcon(IDD, ::GetSystemMetrics(SM_CXSMICON),
- ::GetSystemMetrics(SM_CYSMICON)) != NULL) {
+ ::GetSystemMetrics(SM_CYSMICON)) != nullptr) {
SetIcon(icon_, FALSE);
}
@@ -64,24 +64,24 @@ void VerifyConfigWindowWin::CenterWindow() {
// Center against the owner window unless it is minimized or invisible.
HWND owner = ::GetWindow(m_hWnd, GW_OWNER);
- if (owner != NULL) {
+ if (owner != nullptr) {
DWORD style = ::GetWindowLong(owner, GWL_STYLE);
if ((style & WS_MINIMIZE) != 0 || (style & WS_VISIBLE) == 0) {
- owner = NULL;
+ owner = nullptr;
}
}
// Make sure that the window will not end up split by a monitor's boundary.
RECT area_rect;
- if (!::SystemParametersInfo(SPI_GETWORKAREA, NULL, &area_rect, NULL)) {
+ if (!::SystemParametersInfo(SPI_GETWORKAREA, 0, &area_rect, 0)) {
return;
}
// On a multi-monitor system use the monitor where the owner window is shown.
RECT owner_rect = area_rect;
- if (owner != NULL && ::GetWindowRect(owner, &owner_rect)) {
+ if (owner != nullptr && ::GetWindowRect(owner, &owner_rect)) {
HMONITOR monitor = ::MonitorFromRect(&owner_rect, MONITOR_DEFAULTTONEAREST);
- if (monitor != NULL) {
+ if (monitor != nullptr) {
MONITORINFO monitor_info = {0};
monitor_info.cbSize = sizeof(monitor_info);
if (::GetMonitorInfo(monitor, &monitor_info)) {
@@ -100,7 +100,8 @@ void VerifyConfigWindowWin::CenterWindow() {
y = std::max(y, area_rect.top);
y = std::min(y, area_rect.bottom - width);
- SetWindowPos(NULL, x, y, -1, -1, SWP_NOSIZE | SWP_NOZORDER | SWP_NOACTIVATE);
+ SetWindowPos(nullptr, x, y, -1, -1,
+ SWP_NOSIZE | SWP_NOZORDER | SWP_NOACTIVATE);
}
bool VerifyConfigWindowWin::VerifyHostSecretHash() {
@@ -110,7 +111,7 @@ bool VerifyConfigWindowWin::VerifyHostSecretHash() {
int pin_length = pin_edit.GetWindowTextLength();
scoped_ptr<base::char16[]> pin(new base::char16[pin_length + 1]);
- // Get the PIN making sure it is NULL terminated even if an error occurs.
+ // Get the PIN making sure it is nullptr terminated even if an error occurs.
int result = pin_edit.GetWindowText(pin.get(), pin_length + 1);
pin[std::min(result, pin_length)] = 0;
« no previous file with comments | « remoting/host/username.cc ('k') | remoting/host/video_frame_recorder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698