From 663764177afd872d2e5f05d218a66d4129024bf7 Mon Sep 17 00:00:00 2001 From: Davide De Rosa Date: Sat, 27 Oct 2018 12:12:01 +0200 Subject: [PATCH] Forward wizard delegate after import Necessary to delegate adding to organizer. --- .../Scenes/Organizer/ImportedHostsViewController.swift | 3 +++ .../Scenes/Organizer/OrganizerViewController.swift | 2 ++ 2 files changed, 5 insertions(+) diff --git a/Passepartout-iOS/Scenes/Organizer/ImportedHostsViewController.swift b/Passepartout-iOS/Scenes/Organizer/ImportedHostsViewController.swift index f5cbd812..e9cd0087 100644 --- a/Passepartout-iOS/Scenes/Organizer/ImportedHostsViewController.swift +++ b/Passepartout-iOS/Scenes/Organizer/ImportedHostsViewController.swift @@ -33,6 +33,8 @@ class ImportedHostsViewController: UITableViewController { private lazy var pendingConfigurationURLs = TransientStore.shared.service.pendingConfigurationURLs() private var parsedFile: ParsedFile? + + weak var wizardDelegate: WizardDelegate? override func viewDidLoad() { super.viewDidLoad() @@ -75,6 +77,7 @@ class ImportedHostsViewController: UITableViewController { return } wizard.parsedFile = parsedFile + wizard.delegate = wizardDelegate } @IBAction private func close() { diff --git a/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift b/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift index 0785cd76..f503499d 100644 --- a/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift +++ b/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift @@ -139,6 +139,8 @@ class OrganizerViewController: UITableViewController, TableModelHost { providerVC.availableNames = availableProviderNames ?? [] } vc.delegate = self + } else if let vc = destination as? ImportedHostsViewController { + vc.wizardDelegate = self } }