From 6de8286be5637216715b963e17d2cc008f52232d Mon Sep 17 00:00:00 2001 From: Cody Weaver Date: Thu, 26 Sep 2019 13:17:02 -0700 Subject: [PATCH] [NavigationDrawer] Fix broken header when content expands (#8514) In #8503 this line was removed but after further testing when the contentViewController expands it's preferredContentSize this causes a regression in the header behavior. With this line added back into the check this behavior is fixed. --- .../src/private/MDCBottomDrawerContainerViewController.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/NavigationDrawer/src/private/MDCBottomDrawerContainerViewController.m b/components/NavigationDrawer/src/private/MDCBottomDrawerContainerViewController.m index 8f209acd7a8..34a0cb97294 100644 --- a/components/NavigationDrawer/src/private/MDCBottomDrawerContainerViewController.m +++ b/components/NavigationDrawer/src/private/MDCBottomDrawerContainerViewController.m @@ -661,7 +661,8 @@ - (void)updateViewWithContentOffset:(CGPoint)contentOffset { transitionRatio:transitionPercentage]; [self updateDrawerState:transitionPercentage]; - self.currentlyFullscreen = self.contentReachesFullscreen && contentOffset.y > 0; + self.currentlyFullscreen = + self.contentReachesFullscreen && headerTransitionToTop >= 1 && contentOffset.y > 0; CGFloat fullscreenHeaderHeight = self.contentReachesFullscreen ? self.topHeaderHeight : [self contentHeaderHeight];