Public rooms search: Do not open directory page if the result count is 0 or if the data source is fetching data

This commit is contained in:
manuroe
2015-12-21 11:31:30 +01:00
parent 342d17e3cc
commit b9b5372d63
3 changed files with 10 additions and 0 deletions
@@ -24,6 +24,9 @@
- (void)render:(PublicRoomsDirectoryDataSource *)publicRoomsDirectoryDataSource
{
self.userInteractionEnabled = NO;
self.chevronImageView.hidden = YES;
// Show information according to the data source state
switch (publicRoomsDirectoryDataSource.state)
{
@@ -38,6 +41,11 @@
publicRoomsDirectoryDataSource.filteredRooms.count,
publicRoomsDirectoryDataSource.filter];
if (publicRoomsDirectoryDataSource.filteredRooms.count)
{
self.userInteractionEnabled = YES;
self.chevronImageView.hidden = NO;
}
break;
case MXKDataSourceStateFailed: