Height of UIWebView minus 44px programmatically?

前端 未结 2 1702
滥情空心
滥情空心 2020-12-18 16:19

Is it possible to set the height of a UIWebView by doing something like this..

[webView.height: currentHeight - 44px];

So essentially, I wa

2条回答
  •  無奈伤痛
    2020-12-18 17:04

    I guess this should be enough.

    webView.frame = CGRectMake(webView.frame.origin.x, webView.frame.origin.y, webView.frame.size.width, webView.frame.size.height - 44);
    

提交回复
热议问题