CGA_BaseViewController

class CGA_BaseViewController : UIViewController

This class exists only to manage the background, navbar and logo image. If we are in Dark Mode, or High-Contrast Mode, we make the background darker (and possibly monochromatic), and reduce the prominence of the logo.

  • This is a simple accessor for the app persistent preferences.

    Declaration

    Swift

    var prefs: CGA_PersistentPrefs! { get }
  • The navbar main color (Dark Mode).

    Declaration

    Swift

    private let _darkMode_navbar_color: UIColor
  • The navbar main color (High Contrast Mode and Dark Mode).

    Declaration

    Swift

    private let _darkMode_high_contrast_navbar_color: UIColor
  • The navbar main color (Light Mode).

    Declaration

    Swift

    private let _lightMode_navbar_color: UIColor
  • The navbar main color (High Contrast Mode and Light Mode).

    Declaration

    Swift

    private let _lightMode_high_contrast_navbar_color: UIColor
  • The logo transparency (Dark Mode).

    Declaration

    Swift

    private let _darkMode_logo_alpha: CGFloat
  • The logo transparency (High Contrast Mode and Dark Mode).

    Declaration

    Swift

    private let _darkMode_high_contrast_logo_alpha: CGFloat
  • The logo transparency (Light Mode).

    Declaration

    Swift

    private let _lightMode_logo_alpha: CGFloat
  • The logo transparency (High Contrast Mode and Light Mode).

    Declaration

    Swift

    private let _lightMode_high_contrast_logo_alpha: CGFloat
  • The background gradient transparency (Light or Dark Mode).

    Declaration

    Swift

    private let _background_alpha: CGFloat
  • The background gradient transparency (High Contrast Mode).

    Declaration

    Swift

    private let _high_contrast_background_alpha: CGFloat
  • This is the background gradient image behind each screen.

    Declaration

    Swift

    @IBOutlet
    weak var backgroundGradientImage: UIImageView!
  • This is the BlueVanClef logo image, displayed in the center of the screen.

    Declaration

    Swift

    @IBOutlet
    weak var logoImage: UIImageView!
  • Called when the view has finished loading.

    This is used to set up the common elements for the appropriate mode.

    Declaration

    Swift

    override func viewDidLoad()