I have a compiler error and I just can't work out what is wrong. I am new to this so stuggling to decipher the error.
In my .h I have...
@interface LongViewController : UIViewController {
IBOutlet UIImageView *loadImageInto;
IBOutlet UIImageView *loadedInto;
}
-(void)fadeIt:(UIImageView*)imgNamed;
And in my .m...
-(void)fadeIt:(UIImageView*)imgNamed
{
if(longSize1.alpha == 0.0){
loadImageInto = longSize1;
loadedInto = longSize2;
}
if(longSize2.alpha == 0.0){
loadImageInto = longSize2;
loadedInto = longSize1;
}
loadImageInto.image = [UIImage imageNamed:imgNamed];
}
The warning I am getting is on the last line and is:
warning passing argument 1 of 'imageNamed' from distinct objective-c type
I think it is saying that the type is wrong but I can't seem to sort it out. It is probably saying that the code is running fine and the images are loaded as expected.
Any help would be much appreciated!