Link to BWWalkthrough library: https://github.com/ariok/BWWalkthrough
I'm new to iOS development (Swift 2.2, Xcode 7.3.1). I have walk through working for my App using library BWWalkthrough. When walkthrough page (Class BWWalkthroughPageViewController) is loaded, I want to auto play video on each page. Currently, I can add images, labels, buttons etc. using view scene in Main storyboard for walkthrough pages but how can I add video to these pages? Should I create "XViewController.swift" file for each of these pages to add video programmatically ? But how can I link these files with walkthrough pages ? Currently, pages are added to walkthrough as:
@IBAction func openInstrButtonPressed(){
let stb = UIStoryboard(name: "Main", bundle: nil)
walkthrough = stb.instantiateViewControllerWithIdentifier("container") as! BWWalkthroughViewController
let page_one = stb.instantiateViewControllerWithIdentifier("instr_page1")
let page_two = stb.instantiateViewControllerWithIdentifier("instr_page2")
let page_three = stb.instantiateViewControllerWithIdentifier("instr_page3")
let page_four = stb.instantiateViewControllerWithIdentifier("instr_page4")
// Attach the pages to the master
walkthrough.delegate = self
walkthrough.addViewController(page_one)
walkthrough.addViewController(page_two)
walkthrough.addViewController(page_three)
walkthrough.addViewController(page_four)
self.presentViewController(walkthrough, animated: true) {
()->() in
self.needWalkthrough = false
}
}
Since walkthrough pages are using class "BWWalkthroughPageViewController", should I define a new class to add video programmatically?