【问题标题】:I am getting a large black bar at the top and bottom of the screen in all simulator我在所有模拟器的屏幕顶部和底部都有一个大黑条
【发布时间】:2019-10-26 13:31:53
【问题描述】:

this 是在 CDVViewController.m 中编写的代码,仅基于其显示内容。 Iam 刚接触 Cordova,谁能帮帮我?

 -(void)createView
    {CGRect webViewBounds = self.view.bounds;

        webViewBounds.origin = self.view.bounds.origin;

        self.webView = [self newCordovaViewWithFrame:webViewBounds];
        self.webView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight);

        [self.view addSubview:self.webView];
        [self.view sendSubviewToBack:self.webView];
    }
    -(UIWebView*)newCordovaViewWithFrame:(CGRect)bounds
    {
        return [[UIWebView alloc] initWithFrame:bounds];
    }

【问题讨论】:

  • 添加所需尺寸的启动画面。
  • @NiravKotecha 嗨,你能看到我上面的截图,这是我现在面临的问题如何解决?在 2 张图片中重叠

标签: ios objective-c cordova uiwebview uiwindow


【解决方案1】:

听起来您没有包含启动故事板(或所有预期尺寸的启动图像)。将其中之一添加到您的项目中,您应该没问题。

【讨论】:

  • 仍然,顶部有一点黑条,我如何解决它..?
  • 能否提供截图之类的?
  • 我添加了截图,请查看
  • 你好 Andre Slotta,如果我向上滚动,你能看到我的屏幕截图重叠在屏幕上吗?如何解决这个问题?
猜你喜欢
  • 2015-11-25
  • 1970-01-01
  • 2021-05-27
  • 2014-10-01
  • 2018-04-20
  • 1970-01-01
  • 2019-05-07
  • 2016-12-08
相关资源
最近更新 更多