@@ -166,7 +166,7 @@ - (void)traitCollectionDidChange:(UITraitCollection *)previousTraitCollection {
166
166
return ;
167
167
}
168
168
169
- [self updateSheetFrameRemoveAnimations: YES ];
169
+ [self updateSheetFrame ];
170
170
}
171
171
172
172
- (void )safeAreaInsetsDidChange {
@@ -186,7 +186,7 @@ - (void)safeAreaInsetsDidChange {
186
186
187
187
// Note this is needed to make sure the full displayed frame updates to reflect the new safe
188
188
// area insets after rotation. See b/183357841 for context.
189
- [self updateSheetFrameRemoveAnimations: NO ];
189
+ [self updateSheetFrame ];
190
190
}
191
191
}
192
192
@@ -238,7 +238,7 @@ - (void)updateSheetHeight {
238
238
}
239
239
_preferredSheetHeight = adjustedPreferredSheetHeight;
240
240
241
- [self updateSheetFrameRemoveAnimations: YES ];
241
+ [self updateSheetFrame ];
242
242
}
243
243
244
244
- (void )setPreferredSheetHeight : (CGFloat)preferredSheetHeight {
@@ -252,10 +252,8 @@ - (void)setAdjustHeightForSafeAreaInsets:(BOOL)adjustHeightForSafeAreaInsets {
252
252
}
253
253
254
254
// Slides the sheet position downwards, so the right amount peeks above the bottom of the superview.
255
- - (void )updateSheetFrameRemoveAnimations : (BOOL )removeAnimations {
256
- if (removeAnimations) {
257
- [self .animator removeAllBehaviors ];
258
- }
255
+ - (void )updateSheetFrame {
256
+ [self .animator removeAllBehaviors ];
259
257
260
258
CGRect sheetRect = self.bounds ;
261
259
sheetRect.origin .y = CGRectGetMaxY (self.bounds ) - [self effectiveSheetHeight ];
0 commit comments