refactor: replace remaining NULL
with nullptr
(#40053)
refactor: use nullptr everywhere
This commit is contained in:
parent
9d0e6d09f0
commit
04b2ba84cd
34 changed files with 98 additions and 93 deletions
|
@ -63,7 +63,7 @@ void App::SetActivationPolicy(gin_helper::ErrorThrower thrower,
|
|||
bool App::IsRunningUnderARM64Translation() const {
|
||||
int proc_translated = 0;
|
||||
size_t size = sizeof(proc_translated);
|
||||
if (sysctlbyname("sysctl.proc_translated", &proc_translated, &size, NULL,
|
||||
if (sysctlbyname("sysctl.proc_translated", &proc_translated, &size, nullptr,
|
||||
0) == -1) {
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -132,7 +132,7 @@ struct Converter<electron::ElectronMenuModel*> {
|
|||
static bool FromV8(v8::Isolate* isolate,
|
||||
v8::Local<v8::Value> val,
|
||||
electron::ElectronMenuModel** out) {
|
||||
// null would be transferred to NULL.
|
||||
// null would be transferred to nullptr.
|
||||
if (val->IsNull()) {
|
||||
*out = nullptr;
|
||||
return true;
|
||||
|
|
|
@ -27,8 +27,8 @@ void PowerMonitor::InitPlatformSpecificMonitors() {
|
|||
WNDCLASSEX window_class;
|
||||
base::win::InitializeWindowClass(
|
||||
kPowerMonitorWindowClass,
|
||||
&base::win::WrappedWindowProc<PowerMonitor::WndProcStatic>, 0, 0, 0, NULL,
|
||||
NULL, NULL, NULL, NULL, &window_class);
|
||||
&base::win::WrappedWindowProc<PowerMonitor::WndProcStatic>, 0, 0, 0,
|
||||
nullptr, nullptr, nullptr, nullptr, nullptr, &window_class);
|
||||
instance_ = window_class.hInstance;
|
||||
atom_ = RegisterClassEx(&window_class);
|
||||
|
||||
|
|
|
@ -171,7 +171,7 @@ void SystemPreferences::InitializeWindow() {
|
|||
base::win::InitializeWindowClass(
|
||||
kSystemPreferencesWindowClass,
|
||||
&base::win::WrappedWindowProc<SystemPreferences::WndProcStatic>, 0, 0, 0,
|
||||
NULL, NULL, NULL, NULL, NULL, &window_class);
|
||||
nullptr, nullptr, nullptr, nullptr, nullptr, &window_class);
|
||||
instance_ = window_class.hInstance;
|
||||
atom_ = RegisterClassEx(&window_class);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue