Skip to content

Instantly share code, notes, and snippets.

Last active August 16, 2020 16:55
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save hashaam/fd352f25f8fee6f5614f1243594d9322 to your computer and use it in GitHub Desktop.
// Youtube:
// Source:
import UIKit
class LaunchViewController: UIViewController {
override func viewDidLoad() {
private extension LaunchViewController {
func setupViews() {
func addRequestCameraAuthorizationView() {
let requestCameraAuthorizationView = RequestCameraAuthorizationView()
requestCameraAuthorizationView.translatesAutoresizingMaskIntoConstraints = false
requestCameraAuthorizationView.delegate = self
requestCameraAuthorizationView.leadingAnchor.constraint(equalTo: view.leadingAnchor),
requestCameraAuthorizationView.topAnchor.constraint(equalTo: view.topAnchor),
requestCameraAuthorizationView.trailingAnchor.constraint(equalTo: view.trailingAnchor),
requestCameraAuthorizationView.bottomAnchor.constraint(equalTo: view.bottomAnchor)
extension LaunchViewController: RequestCameraAuthorizationViewDelegate {
func requestCameraAuthorizationActionButtonTapped() {
print("request camera authorization button tapped")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment