Commit 60b9f93a authored by Ronan Abhamon's avatar Ronan Abhamon

feat(ui/views/App/Calls/Incall): better encryption tooltip

parent bd6a2a89
...@@ -315,10 +315,6 @@ ...@@ -315,10 +315,6 @@
<source>callErrorNotAcceptable</source> <source>callErrorNotAcceptable</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>noMediaEncryption</source>
<translation>None</translation>
</message>
</context> </context>
<context> <context>
<name>CallSipAddress</name> <name>CallSipAddress</name>
...@@ -812,6 +808,14 @@ Server url not configured.</translation> ...@@ -812,6 +808,14 @@ Server url not configured.</translation>
<source>pendingRequestLabel</source> <source>pendingRequestLabel</source>
<translation>Please to wait, a request is pending.</translation> <translation>Please to wait, a request is pending.</translation>
</message> </message>
<message>
<source>securedStringFormat</source>
<translation>Call is encrypted with: %1.</translation>
</message>
<message>
<source>callNotSecured</source>
<translation>Call not encrypted.</translation>
</message>
</context> </context>
<context> <context>
<name>InviteFriends</name> <name>InviteFriends</name>
......
...@@ -315,10 +315,6 @@ ...@@ -315,10 +315,6 @@
<source>callErrorNotAcceptable</source> <source>callErrorNotAcceptable</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>noMediaEncryption</source>
<translation>Aucun</translation>
</message>
</context> </context>
<context> <context>
<name>CallSipAddress</name> <name>CallSipAddress</name>
...@@ -812,6 +808,14 @@ Url du serveur non configurée.</translation> ...@@ -812,6 +808,14 @@ Url du serveur non configurée.</translation>
<source>pendingRequestLabel</source> <source>pendingRequestLabel</source>
<translation>Merci de patienter, une requête est en attente.</translation> <translation>Merci de patienter, une requête est en attente.</translation>
</message> </message>
<message>
<source>securedStringFormat</source>
<translation>L&apos;appel est chiffré avec: %1.</translation>
</message>
<message>
<source>callNotSecured</source>
<translation>Appel non chiffré.</translation>
</message>
</context> </context>
<context> <context>
<name>InviteFriends</name> <name>InviteFriends</name>
......
...@@ -541,7 +541,7 @@ QString CallModel::getSecuredString () const { ...@@ -541,7 +541,7 @@ QString CallModel::getSecuredString () const {
break; break;
} }
return tr("noMediaEncryption"); return QStringLiteral("");
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
......
...@@ -64,6 +64,14 @@ function handleVideoRequested () { ...@@ -64,6 +64,14 @@ function handleVideoRequested () {
}) })
} }
function makeReadableSecuredString (securedString) {
if (!securedString.length) {
return qsTr('callNotSecured')
}
return qsTr('securedStringFormat').replace('%1', securedString)
}
function showFullscreen () { function showFullscreen () {
if (incall._fullscreen) { if (incall._fullscreen) {
return return
......
...@@ -111,7 +111,7 @@ Rectangle { ...@@ -111,7 +111,7 @@ Rectangle {
onClicked: zrtp.visible = (incall.call.encryption === CallModel.CallEncryptionZRTP) onClicked: zrtp.visible = (incall.call.encryption === CallModel.CallEncryptionZRTP)
TooltipArea { TooltipArea {
text: incall.call.securedString text: Logic.makeReadableSecuredString(incall.call.securedString)
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment