Answers for "swift video view"

0

swift webview load html

let webView1 = UIWebView()
webView1.loadHTMLString("<html><body><p>Hello!</p></body></html>", baseURL: nil)
Posted by: Guest on June-04-2020
0

screen recorder swift

func stopRecording() {
        
        recorder.stopRecording { [unowned self] (preview, error) in
            print("Stopped recording")
            
            guard preview != nil else {
                print("Preview controller is not available.")
                return
            }
            
            let alert = UIAlertController(title: "Recording Finished", message: "Would you like to edit or delete your recording?", preferredStyle: .alert)
                
            let deleteAction = UIAlertAction(title: "Delete", style: .destructive, handler: { (action: UIAlertAction) in
                self.recorder.discardRecording(handler: { () -> Void in
                    print("Recording suffessfully deleted.")
                })
            })
                
            let editAction = UIAlertAction(title: "Edit", style: .default, handler: { (action: UIAlertAction) -> Void in
                preview?.previewControllerDelegate = self
                self.present(preview!, animated: true, completion: nil)
            })
                
            alert.addAction(editAction)
            alert.addAction(deleteAction)
            self.present(alert, animated: true, completion: nil)
                
                        self.isRecording = false
            self.viewReset()
                
        }
            
    }
Posted by: Guest on June-11-2020

Code answers related to "Swift"

Browse Popular Code Answers by Language