mirror of
https://github.com/yattee/yattee.git
synced 2025-05-18 04:21:08 +00:00
Display build number next to version
This commit is contained in:
parent
9f5e9ea237
commit
45c917160e
@ -36,7 +36,7 @@ struct PlayerControlsView<Content: View>: View {
|
|||||||
.foregroundColor(model.currentItem.isNil ? .secondary : .accentColor)
|
.foregroundColor(model.currentItem.isNil ? .secondary : .accentColor)
|
||||||
.lineLimit(1)
|
.lineLimit(1)
|
||||||
|
|
||||||
Text(model.currentItem?.video?.author ?? "Yattee v\(appVersion)")
|
Text(model.currentItem?.video?.author ?? "Yattee v\(appVersion) (build \(appBuild))")
|
||||||
.fontWeight(model.currentItem.isNil ? .light : .bold)
|
.fontWeight(model.currentItem.isNil ? .light : .bold)
|
||||||
.font(.system(size: 10))
|
.font(.system(size: 10))
|
||||||
.foregroundColor(.secondary)
|
.foregroundColor(.secondary)
|
||||||
@ -115,6 +115,10 @@ struct PlayerControlsView<Content: View>: View {
|
|||||||
Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "unknown"
|
Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "unknown"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private var appBuild: String {
|
||||||
|
Bundle.main.infoDictionary?["CFBundleVersion"] as? String ?? "unknown"
|
||||||
|
}
|
||||||
|
|
||||||
private var progressViewValue: Double {
|
private var progressViewValue: Double {
|
||||||
[model.time?.seconds, model.videoDuration].compactMap { $0 }.min() ?? 0
|
[model.time?.seconds, model.videoDuration].compactMap { $0 }.min() ?? 0
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user