开发者

Fixed background image, that doesn't move when new views are loaded

开发者 https://www.devze.com 2023-01-12 00:46 出处:网络
I have an iPhone app with a navigation controller. Views slide in from the right. I want a background picture that is fixed, so that it doesn\'t开发者_如何学编程 slide with the views pushed on the nav

I have an iPhone app with a navigation controller. Views slide in from the right. I want a background picture that is fixed, so that it doesn't开发者_如何学编程 slide with the views pushed on the nav controller. Is that possible? Thanks!


You should be able to, for example, add a UIImageView with your background image as a subview of your app's UIWindow, underneath the UINavigationController's view. Then set the background color of each UIViewController to [UIColor clearColor], and the static background image should show through.

0

精彩评论

暂无评论...
验证码 换一张
取 消