Posted By

mineschan on 01/29/11


Tagged


Versions (?)

Who likes this?

4 people have marked this snippet as a favorite

iure
athanhcong
cnathan
Rakesh


iPhone Objective-c - Custom UINavigationBar Background Image


 / Published in: Objective C
 

@drag the UINavigationBar to you Xib @and paste the code to your App Delegate.h

  1. @implementation UINavigationBar(Background)
  2.  
  3. -(void)drawRect:(CGRect)rect{
  4. UIImage *navBgImage = [UIImage imageNamed:@"nav_bg.jpg"];
  5. [navBgImage drawInRect:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
  6.  
  7. }
  8. @end

Report this snippet  

You need to login to post a comment.