ios12 ios13上面logo不显示 看不到_entryBtn 入口
Created by: dedencLichKing
在
-
(nullable UIImage *)doraemon_imageNamed:(NSString *)name{ if(name && ![name isEqualToString:@""]){ NSBundle *bundle = [NSBundle bundleForClass:NSClassFromString(@"DoraemonManager")]; NSURL *url = [bundle URLForResource:@"DoraemonKit" withExtension:@"bundle"]; if(!url) return [UIImage new]; NSBundle *imageBundle = [NSBundle bundleWithURL:url];
NSString *imageName = nil; CGFloat scale = [UIScreen mainScreen].scale; if (ABS(scale-3) <= 0.001){ imageName = [NSString stringWithFormat:@"%@@3x",name]; }else if(ABS(scale-2) <= 0.001){ imageName = [NSString stringWithFormat:@"%@@2x",name]; }else{ imageName = name; } UIImage *image = [UIImage imageWithContentsOfFile:[imageBundle pathForResource:imageName ofType:@"png"]]; if (!image) { image = [UIImage imageWithContentsOfFile:[imageBundle pathForResource:name ofType:@"png"]]; if (!image) { image = [UIImage imageNamed:name]; } } return image;
}
return nil; }
无法获取图标 看不到入口