Skip to content

Subclasses UIAlertController and turns the background black and white.

Notifications You must be signed in to change notification settings

Janscho/UIAlertControllerDimmed

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

UIAlertControllerDimmed

Subclasses UIAlertController and turns the background black and white.

Usage

Standard UIAlertController

let alertController: UIAlertController = UIAlertController(title: nil, message: "Message", preferredStyle: .alert)
alertController.addAction(UIAlertAction(title: "OK", style: .cancel, handler: nil))
present(alertController, animated: true, completion: nil)

UIAlertControllerDimmed

let alertController: UIAlertControllerDimmed = UIAlertControllerDimmed(title: nil, message: "Message", preferredStyle: .alert)
alertController.addAction(UIAlertAction(title: "OK", style: .cancel, handler: nil))
alertController.presentWithGrayBackground()

Simply use UIAlertControllerDimmed instead of UIAlertController and call presentWithGrayBackground.

SO question that led to that repo

About

Subclasses UIAlertController and turns the background black and white.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages