Skip to content

Commit 74d652e

Browse files
committed
Change the calculation method of the navigation bar's frame
1 parent ccb7eed commit 74d652e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

KMNavigationBarTransition/UIViewController+KMNavigationBarTransition.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ - (void)km_resizeTransitionNavigationBarFrame {
119119
return;
120120
}
121121
UIView *backgroundView = [self.navigationController.navigationBar valueForKey:@"_backgroundView"];
122-
CGRect rect = [backgroundView.superview convertRect:backgroundView.frame toView:self.view];
122+
CGRect rect = [self.navigationController.navigationBar convertRect:backgroundView.frame toView:self.view];
123123
self.km_transitionNavigationBar.frame = rect;
124124
}
125125

0 commit comments

Comments
 (0)