MijickCamera/Sources/Internal/UI/MCamera/MCamera+Config.swift

29 lines
941 B
Swift
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//
// MCamera+Config.swift of MijickCamera
//
// Created by Tomasz Kurylik. Sending from Kraków!
// - Mail: tomasz.kurylik@mijick.com
// - GitHub: https://github.com/FulcrumOne
// - Medium: https://medium.com/@mijick
//
// Copyright ©2024 Mijick. All rights reserved.
import SwiftUI
extension MCamera { @MainActor class Config {
// MARK: Screens
var cameraScreen: CameraScreenBuilder = DefaultCameraScreen.init
var capturedMediaScreen: CapturedMediaScreenBuilder? = DefaultCapturedMediaScreen.init
var errorScreen: ErrorScreenBuilder = DefaultCameraErrorScreen.init
// MARK: Actions
var imageCapturedAction: (UIImage, MCamera.Controller) -> () = { _,_ in }
var videoCapturedAction: (URL, MCamera.Controller) -> () = { _,_ in }
var closeMCameraAction: () -> () = {}
// MARK: Others
var appDelegate: MApplicationDelegate.Type? = nil
var isCameraConfigured: Bool = false
}}