[ 
https://issues.apache.org/jira/browse/CB-4806?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13787636#comment-13787636
 ] 

Ken Whipday commented on CB-4806:
---------------------------------

The splashscreen still moves vertically during the app launch.  It is easy to 
recreate (I've listed the steps below in case I'm doing something wrong, in 
which case please point it out):

* cordova create demo com.example.demo demo
* cordova platform add iOS
* cordova prepare IOS
* open the project in xcode and run demo on a device 
This works, the splash screen is displayed and does not move
* add the the spashscreen plugin: cordova plugin add 
org.apache.cordova.splashscreen
* cordova prepare iOS
* open the project in xcode and run it on iphone 4s with IOS7 and the 
splashscreen moves vertically just before the apache cordova page is displayed
* using the emulator the splashscreen moves on both IOS6 and IOS7

I'm using cordova 3.1.0-0.1.0.  Is there a setting somewhere I should be 
changing, or is there still a bug?



> Update splashscreen image bounds for iOS 7
> ------------------------------------------
>
>                 Key: CB-4806
>                 URL: https://issues.apache.org/jira/browse/CB-4806
>             Project: Apache Cordova
>          Issue Type: Task
>          Components: iOS, Plugin SplashScreen
>    Affects Versions: Master
>            Reporter: Shazron Abdullah
>            Assignee: Shazron Abdullah
>              Labels: ios7
>             Fix For: 3.1.0
>
>
> See code from this thread: http://markmail.org/message/khqi5vpubxp2qppk
> diff replicated below:
> {code}
> diff --git a/CordovaLib/Classes/CDVSplashScreen.m
> b/CordovaLib/Classes/CDVSplashScreen.m
> index fdb79fa..809ce35 100644
> --- a/CordovaLib/Classes/CDVSplashScreen.m
> +++ b/CordovaLib/Classes/CDVSplashScreen.m
> @@ -170,7 +170,9 @@
>      // There's a special case when the image is the size of the screen.
>      if (CGSizeEqualToSize(screenSize, imgBounds.size)) {
>          CGRect statusFrame = [self.viewController.view
> convertRect:[UIApplication sharedApplication].statusBarFrame fromView:nil];
> -        imgBounds.origin.y -= statusFrame.size.height;
> +        if (floor(NSFoundationVersionNumber) <=
> NSFoundationVersionNumber_iOS_6_1) {
> +            imgBounds.origin.y -= statusFrame.size.height;
> +        }
>      } else {
>          CGRect viewBounds = self.viewController.view.bounds;
>          CGFloat imgAspect = imgBounds.size.width / imgBounds.size.height;
> {code}



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to