Merge pull request #4 from DavidLari/master

Add title property/Remove hard coded title
This commit is contained in:
Florian Gabach
2017-03-08 16:58:39 +01:00
committed by GitHub
2 changed files with 3 additions and 1 deletions
@@ -13,7 +13,7 @@ public class OpenSourceController: NSObject {
// Contains list of licence object
open var licences: [LicenceFile]?
// Client-side authorization options.
// Configuration
open var config = OpenSourceControllerConfig()
/// Present OpenSourceViewController embbeded in navigation controller
@@ -25,6 +25,7 @@ public class OpenSourceController: NSObject {
// Init licence
licenceController.licences = self.licences
licenceController.title = title ?? ""
// Init config
licenceController.config = self.config
@@ -69,6 +69,7 @@ class OpenSourceViewController: UITableViewController {
fileprivate func prepareTableView() {
// Common init
self.tableView.tableFooterView = UIView()
self.tableView.register(OpenSourceTableViewCell.self, forCellReuseIdentifier: self.reuseIdentifier)
self.title = self.config.title
self.tableView.register(OpenSourceTableViewCell.self,
forCellReuseIdentifier: self.reuseIdentifier)