truncate git reflogs
This commit is contained in:
Родитель
6a480eb989
Коммит
241aa7e103
|
@ -21,7 +21,7 @@ class AnalyticsViewController: UIViewController {
|
|||
case customEventButton:
|
||||
print("TODO: send a custom alert via Cocoapods")
|
||||
presentCustomEventAlert()
|
||||
|
||||
|
||||
case customColorButton:
|
||||
print("custom color property button pressed")
|
||||
presentColorPropertyAlert()
|
||||
|
@ -30,49 +30,49 @@ class AnalyticsViewController: UIViewController {
|
|||
break
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// - MARK: Alert Functions
|
||||
|
||||
|
||||
func presentCustomEventAlert() {
|
||||
let alert = UIAlertController(title: "Event sent",
|
||||
message: "",
|
||||
preferredStyle: UIAlertControllerStyle.alert)
|
||||
|
||||
|
||||
// OK Button
|
||||
alert.addAction(UIAlertAction(title: "OK",
|
||||
style: UIAlertActionStyle.default,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
}))
|
||||
self.present(alert, animated:true, completion: nil)
|
||||
present(alert, animated: true, completion: nil)
|
||||
}
|
||||
|
||||
|
||||
func presentColorPropertyAlert() {
|
||||
let alert = UIAlertController(title: "Choose a color",
|
||||
message: "",
|
||||
preferredStyle: .alert)
|
||||
alert.view.tintColor = UIColor.black
|
||||
|
||||
|
||||
// Yellow button
|
||||
alert.addAction(UIAlertAction(title: "Yellow",
|
||||
style: .default,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
}))
|
||||
//TODO: send yellow event here
|
||||
// TODO: send yellow event here
|
||||
|
||||
// Blue button
|
||||
alert.addAction(UIAlertAction(title: "Blue",
|
||||
style: .default,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
}))
|
||||
//TODO: send blue event here
|
||||
|
||||
// TODO: send blue event here
|
||||
|
||||
// Red button
|
||||
alert.addAction(UIAlertAction(title: "Red",
|
||||
style: .default,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
}))
|
||||
//TODO: send Red event here
|
||||
|
||||
self.present(alert, animated:true, completion: nil)
|
||||
// TODO: send Red event here
|
||||
|
||||
present(alert, animated: true, completion: nil)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,25 +17,25 @@ class CrashViewController: UIViewController {
|
|||
@IBAction func crashButtonTapped(_: UIButton) {
|
||||
presentCrashAlert()
|
||||
}
|
||||
|
||||
//- MARK: Alert Functions
|
||||
|
||||
// - MARK: Alert Functions
|
||||
func presentCrashAlert() {
|
||||
let alert = UIAlertController(title: "The app will close",
|
||||
message: "A crash report will be sent upon RE-LAUNCHING the app.",
|
||||
preferredStyle: UIAlertControllerStyle.alert)
|
||||
|
||||
|
||||
// Cancel Button
|
||||
alert.addAction(UIAlertAction(title: "Cancel",
|
||||
style: UIAlertActionStyle.default,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
}))
|
||||
// Crash App button
|
||||
alert.addAction(UIAlertAction(title: "Crash app",
|
||||
style: UIAlertActionStyle.destructive,
|
||||
handler: { (action) in alert.dismiss(animated: true, completion: nil)
|
||||
fatalError()
|
||||
handler: { _ in alert.dismiss(animated: true, completion: nil)
|
||||
fatalError()
|
||||
}))
|
||||
|
||||
self.present(alert, animated:true, completion: nil)
|
||||
|
||||
present(alert, animated: true, completion: nil)
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче