From 42c679e1ec3bbebe611892eb66446e8aef1617f3 Mon Sep 17 00:00:00 2001 From: Ryan Nystrom Date: Wed, 27 Sep 2017 21:48:16 -0400 Subject: [PATCH] resign search bar when tapping search results, fixes #445 --- Classes/Search/SearchResultSectionController.swift | 11 ++++++++++- Classes/Search/SearchViewController.swift | 11 +++++++++-- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/Classes/Search/SearchResultSectionController.swift b/Classes/Search/SearchResultSectionController.swift index 4cccd32b..46e51116 100644 --- a/Classes/Search/SearchResultSectionController.swift +++ b/Classes/Search/SearchResultSectionController.swift @@ -8,12 +8,18 @@ import IGListKit +protocol SearchResultSectionControllerDelegate: class { + func didSelect(sectionController: SearchResultSectionController) +} + final class SearchResultSectionController: ListGenericSectionController { + private weak var delegate: SearchResultSectionControllerDelegate? = nil private let client: GithubClient - init(client: GithubClient) { + init(client: GithubClient, delegate: SearchResultSectionControllerDelegate) { self.client = client + self.delegate = delegate super.init() } @@ -34,6 +40,9 @@ final class SearchResultSectionController: ListGenericSectionController