获取LaunchImage图片名字

CGSize windowSize = [UIScreen mainScreen].bounds.size;

    NSArray *launchImagesDict = [[[NSBundle mainBundle] infoDictionary] valueForKey:@"UILaunchImages"];

    NSString *imgName = @"";

    for (NSDictionary *imgDic in launchImagesDict) {

        CGSize imgSize = CGSizeFromString([NSString stringWithFormat:@"%@",[imgDic objectForKey:@"UILaunchImageSize"]]);

        if (CGSizeEqualToSize(windowSize, imgSize)) {

            imgName = [imgDic objectForKey:@"UILaunchImageName"];

            break;

        }

    }

你可能感兴趣的:(iOS开发)