Skip to content

Commit

Permalink
Fixed compile error.
Browse files Browse the repository at this point in the history
  • Loading branch information
weisJ committed May 10, 2020
1 parent e7316de commit 9d43326
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion macos/src/main/objcpp/DarkMode.mm
Original file line number Diff line number Diff line change
Expand Up @@ -171,13 +171,15 @@ BOOL isDarkModeMojave() {
if ([name containsString:@"jetbrains"]) {
CFStringRef bundleName = (__bridge CFStringRef)name;

Boolean = false;
Boolean exists = false;
CFPreferencesGetAppBooleanValue(NSRequiresAquaSystemAppearance, bundleName, &exists);
isPatched = exists ? YES : NO;

CFPreferencesSetAppValue(NSRequiresAquaSystemAppearance, kCFBooleanFalse, bundleName);
CFPreferencesAppSynchronize(bundleName);
}
} else {
isPatched = false;
}
JNF_COCOA_EXIT(env);
}
Expand Down

0 comments on commit 9d43326

Please sign in to comment.