Skip to content
This repository was archived by the owner on May 21, 2019. It is now read-only.

Commit 800d4f9

Browse files
committed
Update deprecated UIApplication, UIAlertController and UIAlertAction properties to reflect Swift 4.2
1 parent 3789750 commit 800d4f9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Text to Speech/AppDelegate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
2222
var window: UIWindow?
2323

2424

25-
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
25+
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
2626
// Override point for customization after application launch.
2727
return true
2828
}

Text to Speech/ViewController.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,8 @@ class ViewController: UIViewController {
104104

105105
/** Error handling to make sure user fills in required fields before speaking. */
106106
func alertUser(title: String, text: String) {
107-
let alert = UIAlertController(title: title, message: text, preferredStyle: UIAlertControllerStyle.alert)
108-
alert.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default, handler: nil))
107+
let alert = UIAlertController(title: title, message: text, preferredStyle: UIAlertController.Style.alert)
108+
alert.addAction(UIAlertAction(title: "Dismiss", style: UIAlertAction.Style.default, handler: nil))
109109
self.present(alert, animated: true, completion: nil)
110110
}
111111

0 commit comments

Comments
 (0)