Merge pull request #6840 from vector-im/doug/search-freeze

Bugfix on hotfix branch: Element freezes after searching in a room #6762
This commit is contained in:
Doug
2022-10-10 12:56:56 +01:00
committed by GitHub
2 changed files with 9 additions and 3 deletions
@@ -89,8 +89,12 @@
self.navigationItem.leftBarButtonItem = nil;
// Add the search bar
self.navigationItem.titleView = self.searchBar;
UIView *searchBarContainer = [[UIView alloc] initWithFrame:CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width, 44)];
searchBarContainer.backgroundColor = [UIColor clearColor];
searchBarContainer.autoresizingMask = UIViewAutoresizingFlexibleWidth;
self.navigationItem.titleView = searchBarContainer;
[searchBarContainer addSubview:self.searchBar];
self.extendedLayoutIncludesOpaqueBars = YES;
// On iPad, there is no cancel button inside the UISearchBar
@@ -177,8 +181,9 @@
// Initialise internal data at the first call
searchInternals = [[UIViewControllerRiotSearchInternals alloc] init];
UISearchBar *searchBar = [[UISearchBar alloc] init];
UISearchBar *searchBar = [[UISearchBar alloc] initWithFrame:CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width, 44)];
searchBar.showsCancelButton = YES;
searchBar.autoresizingMask = UIViewAutoresizingFlexibleWidth;
searchBar.delegate = (id<UISearchBarDelegate>)self;
searchInternals.searchBar = searchBar;
+1
View File
@@ -0,0 +1 @@
Element freezes after searching in a room.