Skip to content

Commit

Permalink
修复iOS18导航栏透底问题
Browse files Browse the repository at this point in the history
  • Loading branch information
zhouzhongguang committed Sep 20, 2024
1 parent 637cc01 commit 64904e9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions HBDNavigationBar/Classes/HBDNavigationController.m
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,10 @@ - (void)showFakeBarFrom:(UIViewController *)from to:(UIViewController *_Nonnull)
self.navigationBar.fakeView.alpha = 0;
self.navigationBar.shadowImageView.alpha = 0;
self.navigationBar.backgroundImageView.alpha = 0;

[self.navigationBar setNeedsLayout];
[self.navigationBar layoutIfNeeded];

[self showFakeBarFrom:from];
[self showFakeBarTo:to];
[UIView setAnimationsEnabled:YES];
Expand Down

0 comments on commit 64904e9

Please sign in to comment.