简体   繁体   English

IBM Worklight 6.0-iOS7上的App Center无法打开

[英]IBM Worklight 6.0 - App Center on iOS7 fails to open

After building the IBMAppCenter application with Xcode 5.0.2, 使用Xcode 5.0.2构建IBMAppCenter应用程序之后,
When running the .ipa on an iPhone it unfortunately doesn't work. 不幸的是,当在iPhone上运行.ipa时,它不起作用。

When clicking the app it opens up, shows the splash image for a few seconds, but then closes without throwing an error. 单击该应用程序时,它会打开,显示启动图像几秒钟,然后关闭而不会引发错误。

Is this a known error? 这是已知错误吗?

Make sure that you have followed the instructions on how to enable the AppCenter application for iOS 7, as detailed in the following IBM technote: http://www-01.ibm.com/support/docview.wss?uid=swg27039574 确保已遵循有关如何为iOS 7启用AppCenter应用程序的说明,如以下IBM技术说明中所述: http ://www-01.ibm.com/support/docview.wss?uid=swg27039574

I'd even say to make sure you are running the correct version of Worklight. 我什至要确保您运行的是正确版本的Worklight。
Please carefully read the technote. 请仔细阅读技术说明。

Copy/paste: 复制粘贴:

Enable the Application Center Client 启用应用程序中心客户端

Complete the following steps to enable your Application Center Client to run on iOS 7: 完成以下步骤,以使您的Application Center Client在iOS 7上运行:

  1. Import the App Center project into Eclipse as the documentation states. 根据文档说明将App Center项目导入Eclipse。

  2. Use the Worklight Studio wizard to create another Worklight project and add an iPhone environment. 使用Worklight Studio向导创建另一个Worklight项目并添加iPhone环境。

  3. Copy the apps/appName/iphone/native/WorklightSDK/libWorklightStaticLibProject.a file to the App Center project. apps/appName/iphone/native/WorklightSDK/libWorklightStaticLibProject.a文件apps/appName/iphone/native/WorklightSDK/libWorklightStaticLibProject.a到App Center项目。 Overlay the existing file by using the same name. 使用相同的名称覆盖现有文件。

  4. Add the following code in the CDVMainViewController Worklight generated class ( CDVMainViewController.m ). CDVMainViewController Worklight生成的类( CDVMainViewController.m )中添加以下代码。 This code handles the iOS 7 status bar design change. 此代码处理iOS 7状态栏的设计更改。

     - (UIStatusBarStyle)preferredStatusBarStyle { return UIStatusBarStyleLightContent; } - (void)viewWillAppear:(BOOL)animated { CGFloat version = [[UIDevice currentDevice].systemVersion floatValue]; if (version >= 7) { // iOS 7 or above CGRect oldBounds = [self.view bounds]; CGRect newViewBounds = CGRectMake( 0, -10, oldBounds.size.width, oldBounds.size.height-20 ); CGRect newWebViewBounds = CGRectMake( 0, -20, oldBounds.size.width, oldBounds.size.height-40 ); UIColor *headerColor = [UIColor colorWithRed:0.0f green:0.0f blue:0.0f alpha:1.0f]; [self.view setBackgroundColor:headerColor]; [self.view setBounds:newViewBounds]; [self.webView setBounds:newWebViewBounds]; } [super viewWillAppear:animated]; } 

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM