Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
445 views
in Technique[技术] by (71.8m points)

user interface - iOS9 App has black bars on top and bottom

My app doesn't use auto layout, it was originally designed for an iPhone 4/4s and the UI has been mostly untouched since then. The layout is fairly minimal, so it hasnt been deemed a priority to switch it autolayout.

Previously building for iOS8 my app would scale properly on iPhone 5, and newer, filling the screen. The View itself would fill the entire screen, while the icons would scale proportionally (such that they were not distorted). however it seems now that using the iOS9 beta the app receives black bars at both top and bottom, and its basically displayed as a scaled iPhone 4 app, resulting in black bars on the top and bottom.

Basically I want to it simply scale to fit the full screen, the same as it did in iOS8. Can anyone shine some light onto what has changed which has caused these black bars?

I should add, if it build using xcode 7 (ios9 xcode) and deploy a device with iOs8 it works fine, the issue is deploying to iOS9 devices.

The app looks like this on iOS9 now, the red area is the apps usable space now, whereas previously it was the entire size (note black bars).

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

@Fantina @Goles I was able to temporarily fix this by creating and adding a [email protected] file with resolution 640x1136. I then updated the 'App Icons and Launch Images' Section to look like this:

No Image Source or Launch Screen File

I don't think this is a long term solution because in order to be compliant with iOS9 and split-screen apps, Apple is requiring storyboard or xib files. This makes it difficult for developers who rely solely on programatic view generation/layout. URGH.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...