Skip to content

Commit

Permalink
#4769, #6130 - Fix filtering search bar cancel button not clearing th…
Browse files Browse the repository at this point in the history
…e results.
  • Loading branch information
stefanceriu committed May 19, 2022
1 parent 53375b1 commit f715d68
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Riot/Modules/Common/Recents/RecentsViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -2274,7 +2274,8 @@ - (void)searchBarCancelButtonClicked:(UISearchBar *)searchBar
self.recentsTableView.contentOffset = CGPointMake(0, self.recentsSearchBar.frame.size.height);
self.recentsTableView.tableHeaderView = nil;
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.1 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[self refreshRecentsTable];
[self.recentsDataSource searchWithPatterns:nil];
[self.recentsSearchBar setText:nil];
});
}

Expand Down

0 comments on commit f715d68

Please sign in to comment.