Add create room v2 to action sheet

This commit is contained in:
ismailgulek
2020-09-09 19:40:30 +03:00
parent 6a028e98ec
commit 8725dc4880
@@ -1659,6 +1659,20 @@
}]];
[currentAlert addAction:[UIAlertAction actionWithTitle:@"Create room (v2)"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
if (weakSelf)
{
typeof(self) self = weakSelf;
self->currentAlert = nil;
[self createNewRoom];
}
}]];
[currentAlert addAction:[UIAlertAction actionWithTitle:NSLocalizedStringFromTable(@"room_recents_join_room", @"Vector", nil)
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
@@ -1692,6 +1706,16 @@
[self presentViewController:currentAlert animated:YES completion:nil];
}
- (void)createNewRoom
{
// Sanity check
if (self.mainSession)
{
CreateRoomCoordinatorBridgePresenter *presenter = [[CreateRoomCoordinatorBridgePresenter alloc] initWithSession:self.mainSession];
[presenter presentFrom:self animated:YES];
}
}
- (void)createAnEmptyRoom
{
// Sanity check