diff options
Diffstat (limited to 'SmartDeviceLink/SDLLockScreenViewController.m')
-rw-r--r-- | SmartDeviceLink/SDLLockScreenViewController.m | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/SmartDeviceLink/SDLLockScreenViewController.m b/SmartDeviceLink/SDLLockScreenViewController.m index 73659eaf6..c69b059bb 100644 --- a/SmartDeviceLink/SDLLockScreenViewController.m +++ b/SmartDeviceLink/SDLLockScreenViewController.m @@ -164,19 +164,7 @@ NS_ASSUME_NONNULL_BEGIN } + (UIImage *)sdl_imageWithName:(NSString *)name { - UIImage* image = nil; - if (SDL_SYSTEM_VERSION_LESS_THAN(@"8.0")) { - NSString *bundlePath = [[NSBundle sdlBundle] bundlePath]; - NSInteger deviceScale = [[UIScreen mainScreen] scale]; - // We assume we are only dealing with PNGs. - NSString *fileName = [NSString stringWithFormat:@"%@%li.png", name, (long)deviceScale]; - NSString *fullPath = [NSString stringWithFormat:@"%@/%@", bundlePath, fileName]; - NSData *imageData = [NSData dataWithContentsOfFile:fullPath]; - image = [UIImage imageWithData:imageData]; - } else { - image = [UIImage imageNamed:name inBundle:[NSBundle sdlBundle] compatibleWithTraitCollection:nil]; - } - + UIImage* image = [UIImage imageNamed:name inBundle:[NSBundle sdlBundle] compatibleWithTraitCollection:nil]; return [image imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate]; } |