forked from mirrors/linphone-iphone
Add green call banner
This commit is contained in:
parent
32dc6ea345
commit
cfe3bef32d
4 changed files with 31 additions and 2 deletions
|
|
@ -48,6 +48,9 @@
|
|||
},
|
||||
"#" : {
|
||||
|
||||
},
|
||||
"%@" : {
|
||||
|
||||
},
|
||||
"%lld" : {
|
||||
|
||||
|
|
@ -61,6 +64,9 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"%lld appels" : {
|
||||
|
||||
},
|
||||
"%lld Book (Example)" : {
|
||||
"extractionState" : "manual",
|
||||
|
|
|
|||
|
|
@ -113,6 +113,9 @@ class TelecomManager: ObservableObject {
|
|||
|
||||
setHeldOtherCalls(core: core, exceptCallid: "")
|
||||
requestTransaction(transaction, action: "startCall")
|
||||
withAnimation {
|
||||
self.callDisplayed = true
|
||||
}
|
||||
} else {
|
||||
try doCall(core: core, addr: addr!, isSas: isSas, isVideo: isVideo, isConference: isConference)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ class CallViewModel: ObservableObject {
|
|||
|
||||
private var mConferenceSuscriptions = Set<AnyCancellable?>()
|
||||
|
||||
var calls: [Call] = []
|
||||
@Published var calls: [Call] = []
|
||||
|
||||
let timer = Timer.publish(every: 1, on: .main, in: .common).autoconnect()
|
||||
|
||||
|
|
@ -996,7 +996,6 @@ class CallViewModel: ObservableObject {
|
|||
default: "cell-signal-none"
|
||||
}
|
||||
|
||||
print("iconiconicon \(icon) \(self.currentCall!.currentQuality)")
|
||||
DispatchQueue.main.async {
|
||||
self.qualityValue = quality
|
||||
self.qualityIcon = icon
|
||||
|
|
|
|||
|
|
@ -73,7 +73,28 @@ struct ContentView: View {
|
|||
VStack(spacing: 0) {
|
||||
if telecomManager.callInProgress && !fullscreenVideo && ((!telecomManager.callDisplayed && callViewModel.calls.count == 1) || callViewModel.calls.count > 1) {
|
||||
HStack {
|
||||
Image("phone")
|
||||
.renderingMode(.template)
|
||||
.resizable()
|
||||
.foregroundStyle(.white)
|
||||
.frame(width: 26, height: 26)
|
||||
.padding(.leading, 10)
|
||||
|
||||
if callViewModel.calls.count > 1 {
|
||||
Text("\(callViewModel.calls.count) appels")
|
||||
.default_text_style_white(styleSize: 16)
|
||||
} else {
|
||||
Text("\(callViewModel.displayName)")
|
||||
.default_text_style_white(styleSize: 16)
|
||||
}
|
||||
|
||||
Spacer()
|
||||
|
||||
if callViewModel.calls.count == 1 {
|
||||
Text("\(callViewModel.isPaused || telecomManager.isPausedByRemote ? "En pause" : "Actif")")
|
||||
.default_text_style_white(styleSize: 16)
|
||||
.padding(.trailing, 10)
|
||||
}
|
||||
}
|
||||
.frame(maxWidth: .infinity)
|
||||
.frame(height: 30)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue