Replace Mark All as Read with progress indicator. Issues #1157 and #1165

This commit is contained in:
Maurice Parker
2019-10-25 13:34:59 -05:00
parent fa24e8a863
commit 6a281c7672
13 changed files with 153 additions and 398 deletions

View File

@@ -0,0 +1,31 @@
//
// UndoAvailableAlertController.swift
// NetNewsWire
//
// Created by Phil Viso on 9/29/19.
// Copyright © 2019 Ranchero Software. All rights reserved.
//
import Foundation
import UIKit
struct UndoAvailableAlertController {
static func alert(handler: @escaping (UIAlertAction) -> Void) -> UIAlertController {
let title = NSLocalizedString("Undo Available", comment: "Undo Available")
let message = NSLocalizedString("You can undo this and other actions with a three finger swipe to the left.",
comment: "Mark all articles")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let confirmTitle = NSLocalizedString("Got It", comment: "Got It")
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelAction = UIAlertAction(title: cancelTitle, style: .cancel)
let markAction = UIAlertAction(title: confirmTitle, style: .default, handler: handler)
alertController.addAction(cancelAction)
alertController.addAction(markAction)
return alertController
}
}