Skip to content

Commit

Permalink
修复当UINavigationBar的translucent为No时的显示问题。
Browse files Browse the repository at this point in the history
  • Loading branch information
pcjbird committed Jan 5, 2018
1 parent 0f0d6c7 commit 54fb2f4
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion QuickWebKit.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "QuickWebKit"
s.version = "1.0.4"
s.version = "1.0.5"
s.summary = "A great & strong plugin based WebViewController. 一款基于插件的 WebView 视图控制器,您可以基于它设计您的浏览器插件,然后像积木一样来组装它们。"
s.description = <<-DESC
A great & strong plugin based WebViewController. 一款基于插件的 WebView 视图控制器,您可以基于它设计您的浏览器插件,然后像积木一样来组装它们。
Expand Down
2 changes: 1 addition & 1 deletion QuickWebKit/QuickWebCore/QuickWebViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ -(void)viewDidLayoutSubviews
top += [_contentWebView.scrollView quickweb_safeAreaInsets].top;
if (!IsiOS11Later)
{
if(!_navbarTransparent)
if(!_navbarTransparent&&self.navigationController.navigationBar.translucent)
{
top += StatusBarHeight;
top += NavigationBarHeight;
Expand Down
3 changes: 3 additions & 0 deletions QuickWebKit/QuickWebKit.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
// 框架名称:QuickWebKit
// 框架功能:A great & strong plugin based WebViewController. 一款基于插件的 WebView 视图控制器,您可以基于它设计您的浏览器插件,然后像积木一样来组装它们。
// 修改记录:
// pcjbird 2018-01-05 Version:1.0.5 Build:201801050001
// 1.修复当UINavigationBar的translucent为No时的显示问题。
//
// pcjbird 2018-01-04 Version:1.0.4 Build:201801040001
// 1.新增Spotlight插件
//
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ -(void)webViewControllerDidLayoutSubviews:(QuickWebViewController *)webViewContr
top += [webViewController.webView.scrollView quickweb_safeAreaInsets].top;
if (!IsiOS11Later)
{
if(!webViewController.navbarTransparent)
if(!webViewController.navbarTransparent && webViewController.navigationController.navigationBar.translucent)
{
top += [[UIApplication sharedApplication] statusBarFrame].size.height;
top += 44.0f;
Expand Down
2 changes: 1 addition & 1 deletion QuickWebKit/Supporting Files/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>1.0.4</string>
<string>1.0.5</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSPrincipalClass</key>
Expand Down

0 comments on commit 54fb2f4

Please sign in to comment.