I’m trying to add a UIImageView programmatically using this code, as I always do:
UIImageView *theImageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@“theImage"]];
[theImageView setFrame:CGRectMake(0.0f, 0.0f, 320.0f, 225.0f)];
I’ve added “theImage.png” and “theImage@2x.png” as I always do, but the simulator and my iPhone4 are not able to show the @2x image file. They always show the standard one. Image files are OK (not corrupted) and they’re on the bundle root.
I’m running Xcode 4.2 and iOS5 SDK.
Any ideas?
Strange and Odd thing. Reinstalled Xcode and now it works. Maybe the compiler was corrupted.