Posts

Showing posts from March, 2015

Easy to change status bar text color in Phonegap iOS App

Image
For iOS App : Change Status Bar text color  Step 1 :-                  Change View controller-based status bar appearance Setting in info.plist file.         if you want to change text color add NO.                                        UIViewControllerBasedStatusBarAppearance  to  NO                                else set Yes                                       UIViewControllerBasedStatusBarAppearance  to  YES  Step 2 :- Apply code in javascript and Objective c Change Main view Controller back ground color and apply status bar style based on requirement . Create .m & .h file for native plugin.  DemoStatusBar .h    #import <Foundation/Foundation.h>  #import <Cordova/CDV.h>  #import <CORDOVA/CDVPlugin.h> @interface  DemoStatusBar : CDVPlugin    -( void )setStatusBarColor:( CDVInvokedUrlCommand *)command;    -( UIColor *)colorWithHexString:( NSString *)hex; @end DemoStatusBar .m #import "

Easy to change status bar text color in iOS 7

Image
Change Status Bar text color in iOS 7  Step 1 :-                  Change View controller-based status bar appearance Setting in info.plist file.         if you want to change text color add NO.                                        UIViewControllerBasedStatusBarAppearance  to  NO                                   else set Yes                                       UIViewControllerBasedStatusBarAppearance  to YES  Step 2 :-                   Add bellow code based on your event. like : you want on    ViewDidLoad   OR Any Event . For white :  [[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleLightContent];    For Black :   [[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleDefault];