Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @IBOutlet weak var tableView: UITableView!
- var mainController = ViewController()
- var movie = ViewController().self.movieArray[0]
- var titles = ["Title", "Release Date","Genres","OverView"]
- override func viewDidLoad() {
- super.viewDidLoad()
- print(movie)
- // Do any additional setup after loading the view.
- }
- func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
- return titles.count
- }
- func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
- let cell = self.tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) as! DetailsCustomcell
- cell.detailTitle.text = titles[indexPath.row]
- if indexPath.row == 0{
- cell.detailContent.text = ""
- }
- if indexPath.row == 1{
- cell.detailContent.text = ""
- }
- if indexPath.row == 2{
- cell.detailContent.text = "Movie genre´s is not fixed yet"
- }
- if indexPath.row == 3{
- cell.detailContent.text = ""
- }
- return cell
- }
- /*
- // MARK: - Navigation
- // In a storyboard-based application, you will often want to do a little preparation before navigation
- override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
- // Get the new view controller using segue.destinationViewController.
- // Pass the selected object to the new view controller.
- }
- */
- @IBOutlet weak var detailTitle: UILabel!
- @IBOutlet weak var detailContent: UILabel!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement