Forráskód Böngészése

Fix visual bug when pushing explorers from some screens

When the search bar is pinned — like it was on the view hierarchy screen or the runtime browser screen — pushing another view controller causes it to have a really tall gap at the top of the table view momentarily. Unpinning it makes this gap and the animation associated with it vanish. This is the best I can do for now until I can really track down the cause, which is likely a UIKit bug or intentional.
Tanner Bennett 6 éve
szülő
commit
1ac04cd52c

+ 5 - 1
Classes/GlobalStateExplorers/RuntimeBrowser/FLEXObjcRuntimeViewController.m

@@ -35,7 +35,11 @@
     
     // Search bar stuff, must be first because this creates self.searchController
     self.showsSearchBar = YES;
-    self.pinSearchBar = YES;
+    self.showSearchBarInitially = YES;
+    // Using pinSearchBar on this screen causes a weird visual
+    // thing on the next view controller that gets pushed.
+    //
+    // self.pinSearchBar = YES;
     self.searchController.searchBar.placeholder = @"UIKit*.UIView.-setFrame:";
 
     // Search controller stuff

+ 5 - 1
Classes/ViewHierarchy/TreeExplorer/FLEXHierarchyTableViewController.m

@@ -75,7 +75,11 @@ typedef NS_ENUM(NSUInteger, FLEXHierarchyScope) {
     [self.tableView setSeparatorInset:UIEdgeInsetsZero];
     
     self.showsSearchBar = YES;
-    self.pinSearchBar = YES;
+    self.showSearchBarInitially = YES;
+    // Using pinSearchBar on this screen causes a weird visual
+    // thing on the next view controller that gets pushed.
+    //
+    // self.pinSearchBar = YES;
     self.searchBarDebounceInterval = kFLEXDebounceInstant;
     self.automaticallyShowsSearchBarCancelButton = NO;
     if (self.showScopeBar) {