From 29ac92e961d7aa5ec28d951dc94258fdfdfd1e9c Mon Sep 17 00:00:00 2001 From: Niels Andriesse Date: Mon, 6 May 2019 10:52:39 +1000 Subject: [PATCH] Hook up new conversation button --- .../src/ViewControllers/NewContactThreadViewController.m | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Signal/src/ViewControllers/NewContactThreadViewController.m b/Signal/src/ViewControllers/NewContactThreadViewController.m index 803f6832e..7f868ebb6 100644 --- a/Signal/src/ViewControllers/NewContactThreadViewController.m +++ b/Signal/src/ViewControllers/NewContactThreadViewController.m @@ -402,7 +402,12 @@ NS_ASSUME_NONNULL_BEGIN addItem:[OWSTableItem disclosureItemWithText:NSLocalizedString(@"Start a Conversation", @"") accessibilityIdentifier:ACCESSIBILITY_IDENTIFIER_WITH_NAME(self, @"start_conversation") customRowHeight:UITableViewAutomaticDimension - actionBlock:^{ NSLog(@"Start a Conversation"); }]]; + actionBlock:^{ + typeof(self) strongSelf = weakSelf; + if (!strongSelf) { return; } + NSString *publicKey = strongSelf.searchBar.text; + [strongSelf newConversationWithRecipientId:publicKey]; + }]]; [contents addSection:newConversationSection]; // ========