gmoledina / GMGridView

A performant Grid-View for iOS (iPhone/iPad) that allows sorting of views with gestures (the user can move the items with his finger to sort them) and pinching/rotating/panning gestures allow the user to play with the view and toggle from the cellview to a fullsize display.
MIT License
2.3k stars 512 forks source link

After rotate top cells bounds wasn't recalculated #177

Closed sergianiskin closed 9 years ago

sergianiskin commented 11 years ago
  1. Rotate to landscape
  2. Scroll to the bottom
  3. Call scrollToObjectAtIndex:0
  4. Rotate to portrait

Top cells bounds and positions wasn't recalculated. Its because if cached subviews. I solved this problem with one line added to layoutSubviews

if (_rotationActive) { _rotationActive = NO;

    // After rotation need to update cached subviews array
    [self setSubviewsCacheAsInvalid];