I am working on an iOS app using 5.1 iPhone SDK. The app has 2 view controllers and a tab view controller. I am allocating a UIImageView from a library which is being linked to the app. The code to allocate the UIIMageView is being called from a function which is invoked after the app is initialised and launched. I use the code below to add the UIImageView.
UIWindow *window = [[UIApplication sharedApplication] keyWindow];
UIImageView *imgView = [[UIImageView alloc] initWithFrame:[window bounds]];
[window addSubview:imgView];
[window bringSubviewToFront:imgView];
The problem is that the imageView is not showing up when the app is run. I can’t move the code out of the library or the function from where it is being called.
Appreciate any pointers.
1 Answer