"useSplashScreen" is deprecated: deprecated in Cordova 2.5, receiving this warning in Xcode

I installed Cordova 2.5 and tried Hello World on a project in Xcode and received this warning. Are there any ideas how to resolve this warning. Thanks

+4
source share
4 answers

You can comment on the line in AppDelegate.m (line 68 according to 2.5.0)

self.viewController.useSplashScreen = YES; 

This should remove the warning about the next build.

+4
source

The splash screen control is now split into the Splashscreen plugin:

http://docs.phonegap.com/en/2.5.0/cordova_splashscreen_splashscreen.md.html#Splashscreen

(Here is a complete example of its use on this page)

+2
source

To solve this problem, you only need to comment out the line in AppDelegate.m, save the file and run the application again.

This has been left unattended for backward compatibility.

The template has already been added with the plugin enabled, you can check it in the plugins section of the config.xml file.

You can view more information about http://docs.phonegap.com/en/2.5.0/cordova_splashscreen_splashscreen.md.html#Splashscreen , as rmc47 pointed out.

+1
source

Although you can comment on this line of code in the AppDelegate.m project file (which I usually do not recommend), you can also simply suppress the warning using the following #pragma directives:

 #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wdeprecated-declarations" - (BOOL)application:(UIApplication*)application didFinishLaunchingWithOptions:(NSDictionary*)launchOptions { /* ... code generating warning/deprecation message ... */ return YES; } #pragma clang diagnostic pop 
+1
source

All Articles