Resolve errors?

This Took me at least 10 minutes to figure this out. The following implementation was used and referenced using any code I saw in this file. Also this wasn’t tested.
This commit is contained in:
arichornlover 2024-03-13 18:52:51 -05:00 committed by GitHub
parent fe6c0accbf
commit 0eddeb1d1b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -292,7 +292,10 @@ UIColor* raisedColor = [UIColor colorWithRed:0.035 green:0.035 blue:0.035 alpha:
%hook UIApplication
- (void)applicationDidFinishLaunching:(UIApplication *)application {
if (@available(iOS 14.0, *)) {
self.window.backgroundColor = [UIColor blackColor];
NSArray<UIWindow *> *windows = application.windows;
if (windows.count > 0) {
windows[0].backgroundColor = [UIColor blackColor];
}
}
%orig;
}
@ -585,7 +588,10 @@ UIColor *customHexColor;
%hook UIApplication
- (void)applicationDidFinishLaunching:(UIApplication *)application {
if (@available(iOS 14.0, *)) {
self.window.backgroundColor = customHexColor;
NSArray<UIWindow *> *windows = application.windows;
if (windows.count > 0) {
windows[0].backgroundColor = customHexColor;
}
}
%orig;
}