SettingsModel.swift
1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
//
// SettingsModel.swift
// InterQR-Internship
//
// Created by Leyter on 09.06.2022.
//
import Foundation
import UIKit
enum SettingsModel: CaseIterable {
case displayName
case doNotDisturb
case ringtone
case editResidents
case widgetLock
func getTitle() -> String {
switch self {
case .displayName :
return "Your display name"
case .doNotDisturb :
return "Do not disturb"
case .editResidents :
return "Edit residents"
case .widgetLock:
return "Widget lock"
case .ringtone:
return "Rringtone"
}
}
func getIcon() -> UIImage? {
switch self {
case .displayName:
return UIImage(named: "Profile")
case .doNotDisturb:
return UIImage(named: "Notification")
case .editResidents:
return UIImage(named: "Password")
case .widgetLock:
return UIImage(named: "Profile")
case .ringtone:
return UIImage(named: "Volume")
}
}
func getDescription() -> String {
switch self {
case .displayName :
return "This name will be dispayed everywhere"
case .doNotDisturb :
return "This name will be dispayed everywhere"
case .editResidents :
return "This name will be dispayed everywhere"
case .widgetLock:
return "This name will be dispayed everywhere"
case .ringtone:
return "This name will be dispayed everywhere"
}
}
}