Browse Source

fix the first display of library with the search bar hidden on iPad

Signed-off-by: Felix Paul Kühne <fkuehne@videolan.org>
Pierre SAGASPE 10 years ago
parent
commit
91d56370bc
1 changed files with 3 additions and 0 deletions
  1. 3 0
      Sources/VLCPlaylistViewController.m

+ 3 - 0
Sources/VLCPlaylistViewController.m

@@ -228,6 +228,9 @@ static NSString *kDisplayedFirstSteps = @"Did we display the first steps tutoria
     _searchBar.delegate = self;
     _searchBar.hidden = YES;
 
+    if (!_usingTableViewToShowData)
+        _collectionView.contentInset = UIEdgeInsetsMake(-[VLCLibraryHeaderView headerHeight], 0, 0, 0);
+
     UITapGestureRecognizer *tapTwiceGesture = [[UITapGestureRecognizer alloc] initWithTarget:self  action:@selector(tapTwiceGestureAction:)];
     [tapTwiceGesture setNumberOfTapsRequired:2];
     [self.navigationController.navigationBar addGestureRecognizer:tapTwiceGesture];