This commit is contained in:
gaelle 2025-03-20 17:45:52 +01:00
parent f81400eed0
commit 3eca1736d5
23 changed files with 1522 additions and 1456 deletions

View file

@ -574,8 +574,9 @@ void ConferenceInfoCore::save() {
if (CoreModel::getInstance()->getCore()->getDefaultAccount()->getState() !=
linphone::RegistrationState::Ok) {
//: "Erreur"
//: "Votre compte est déconnecté"
Utils::showInformationPopup(tr("information_popup_error_title"), tr("information_popup_disconnected_account_message"), false);
Utils::showInformationPopup(tr("information_popup_error_title"),
//: "Votre compte est déconnecté"
tr("information_popup_disconnected_account_message"), false);
emit saveFailed();
return;
}

View file

@ -26,6 +26,7 @@
DEFINE_ABSTRACT_OBJECT(FriendCore)
// Translation does not work if not in class directly
//: "Adresse SIP"
const QString _addressLabel = FriendCore::tr("sip_address");
//: "Téléphone"
@ -64,7 +65,7 @@ FriendCore::FriendCore(const std::shared_ptr<linphone::Friend> &contact, bool is
auto addresses = contact->getAddresses();
for (auto &address : addresses) {
mAddressList.append(Utils::createFriendAddressVariant(
_addressLabel, Utils::coreStringToAppString(address->asStringUriOnly())));
tr("sip_address"), Utils::coreStringToAppString(address->asStringUriOnly())));
}
mDefaultAddress = defaultAddress ? Utils::coreStringToAppString(defaultAddress->asStringUriOnly()) : QString();
mDefaultFullAddress = defaultAddress ? Utils::coreStringToAppString(defaultAddress->asString()) : QString();
@ -72,7 +73,7 @@ FriendCore::FriendCore(const std::shared_ptr<linphone::Friend> &contact, bool is
auto phoneNumbers = contact->getPhoneNumbersWithLabel();
for (auto &phoneNumber : phoneNumbers) {
auto label = Utils::coreStringToAppString(phoneNumber->getLabel());
if (label.isEmpty()) label = _phoneLabel;
if (label.isEmpty()) label = tr("device_id");
mPhoneNumberList.append(
Utils::createFriendAddressVariant(label, Utils::coreStringToAppString(phoneNumber->getPhoneNumber())));
}
@ -185,7 +186,7 @@ void FriendCore::setSelf(QSharedPointer<FriendCore> me) {
QList<QVariant> addr;
for (auto &num : numbers) {
addr.append(Utils::createFriendAddressVariant(
_addressLabel, Utils::coreStringToAppString(num->asStringUriOnly())));
tr("sip_address"), Utils::coreStringToAppString(num->asStringUriOnly())));
}
mFriendModelConnection->invokeToCore([this, addr]() { resetPhoneNumbers(addr); });
});
@ -193,7 +194,7 @@ void FriendCore::setSelf(QSharedPointer<FriendCore> me) {
auto numbers = mFriendModel->getPhoneNumbers();
QList<QVariant> addr;
for (auto &num : numbers) {
addr.append(Utils::createFriendAddressVariant(_phoneLabel,
addr.append(Utils::createFriendAddressVariant(tr("device_id"),
Utils::coreStringToAppString(num->getPhoneNumber())));
}
mFriendModelConnection->invokeToCore([this, addr]() { resetPhoneNumbers(addr); });
@ -415,10 +416,11 @@ void FriendCore::appendAddress(const QString &addr) {
QString interpretedFullAddress = linphoneAddr ? Utils::coreStringToAppString(linphoneAddr->asString()) : "";
QString interpretedAddress = linphoneAddr ? Utils::coreStringToAppString(linphoneAddr->asStringUriOnly()) : "";
mCoreModelConnection->invokeToCore([this, interpretedAddress, interpretedFullAddress]() {
//: "Adresse invalide"
if (interpretedAddress.isEmpty()) Utils::showInformationPopup(tr("information_popup_error_title"), tr("information_popup_invalid_address_message"), false);
if (interpretedAddress.isEmpty()) Utils::showInformationPopup(tr("information_popup_error_title"),
//: "Adresse invalide"
tr("information_popup_invalid_address_message"), false);
else {
mAddressList.append(Utils::createFriendAddressVariant(_addressLabel, interpretedAddress));
mAddressList.append(Utils::createFriendAddressVariant(tr("sip_address"), interpretedAddress));
if (mDefaultFullAddress.isEmpty()) mDefaultFullAddress = interpretedFullAddress;
if (mDefaultAddress.isEmpty()) mDefaultAddress = interpretedAddress;
emit addressChanged();
@ -607,7 +609,7 @@ void FriendCore::writeFromModel(const std::shared_ptr<FriendModel> &model) {
QList<QVariant> addresses;
for (auto &addr : model->getAddresses()) {
addresses.append(
Utils::createFriendAddressVariant(_addressLabel, Utils::coreStringToAppString(addr->asStringUriOnly())));
Utils::createFriendAddressVariant(tr("sip_address"), Utils::coreStringToAppString(addr->asStringUriOnly())));
}
mAddressList = addresses;
mDefaultAddress = model->getDefaultAddress();

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -113,8 +113,9 @@ Item {
onClicked: {
if (mainItem.conference) {
UtilsCpp.copyToClipboard(mainItem.call.core.remoteAddress)
//: Le lien de la réunion a été copié dans le presse-papier
showInformationPopup(qsTr("copied"), qsTr("information_popup_meeting_address_copied_to_clipboard"), true)
showInformationPopup(qsTr("copied"),
//: Le lien de la réunion a été copié dans le presse-papier
qsTr("information_popup_meeting_address_copied_to_clipboard"), true)
}
}
}

View file

@ -50,8 +50,9 @@ ListView {
Text {
id: callStateText
//: "Réunion
//: "Appel"
property string type: modelData.core.isConference ? qsTr("meeting") : qsTr("call")
property string type: modelData.core.isConference ? qsTr("meeting")
//: "Appel"
: qsTr("call")
Layout.rightMargin: Math.round(2 * DefaultStyle.dp)
text: modelData.core.state === LinphoneEnums.CallState.Paused
|| modelData.core.state === LinphoneEnums.CallState.PausedByRemote

View file

@ -196,8 +196,9 @@ FocusScope {
visible: searchResultItem.core.isStored
&& !searchResultItem.core.readOnly
//: "Enlever des favoris"
//: "Ajouter aux favoris"
text: searchResultItem.core.starred ? qsTr("contact_details_remove_from_favourites") : qsTr("contact_details_add_to_favourites")
text: searchResultItem.core.starred ? qsTr("contact_details_remove_from_favourites")
//: "Ajouter aux favoris"
: qsTr("contact_details_add_to_favourites")
icon.source: searchResultItem.core.starred ? AppIcons.heartFill : AppIcons.heart
spacing: Math.round(10 * DefaultStyle.dp)
textColor: DefaultStyle.main2_500main
@ -222,15 +223,17 @@ FocusScope {
var filepath = UtilsCpp.createVCardFile(
username, vcard)
if (filepath == "")
//: "La création du fichier vcard a échoué"
UtilsCpp.showInformationPopup(
qsTr("information_popup_error_title"), qsTr("information_popup_vcard_creation_error"),
qsTr("information_popup_error_title"),
//: La création du fichier vcard a échoué
qsTr("information_popup_vcard_creation_error"),
false)
else
//: "VCard créée"
//: "VCard du contact enregistrée dans %1"
mainWindow.showInformationPopup(qsTr("information_popup_vcard_creation_title"), qsTr("information_popup_vcard_creation_success").arg(filepath))
//: "Partage de contact"
//: VCard créée
mainWindow.showInformationPopup(qsTr("information_popup_vcard_creation_title"),
//: "VCard du contact enregistrée dans %1"
qsTr("information_popup_vcard_creation_success").arg(filepath))
//: Partage de contact
UtilsCpp.shareByEmail(qsTr("contact_sharing_email_title"),vcard, filepath)
}
style: ButtonStyle.noBackground

View file

@ -21,9 +21,11 @@ Popup {
property string text
property string details
//: "Confirmer"
//: "Annuler"
property string firstButtonText: firstButtonAccept ? qsTr("dialog_confirm") : qsTr("dialog_cancel")
property string secondButtonText: secondButtonAccept ? qsTr("dialog_confirm") : qsTr("dialog_cancel")
property string firstButtonText: firstButtonAccept ? qsTr("dialog_confirm")
//: "Annuler"
: qsTr("dialog_cancel")
property string secondButtonText: secondButtonAccept ? qsTr("dialog_confirm")
: qsTr("dialog_cancel")
property alias content: contentLayout.data
property alias buttons: buttonsLayout.data
property alias firstButton: firstButtonId

View file

@ -109,7 +109,7 @@ FocusScope {
fillMode: Image.PreserveAspectFit
}
Text {
text: "Appel de groupe"
text: qsTr("call_start_group_call_title")
color: DefaultStyle.grey_1000
font {
pixelSize: Typography.h4.pixelSize

View file

@ -293,7 +293,8 @@ MainRightPanel {
Layout.preferredWidth: Math.round(421 * DefaultStyle.dp)
Layout.preferredHeight: height
onEditingFinished: {
if (text.length != 0) mainItem.contact.core.setAddressAt(index, qsTr("sip_address"), text)
var label = qsTr("sip_address")
if (text.length != 0) mainItem.contact.core.setAddressAt(index, label, text)
}
property string _initialText: modelData.address
initialText: SettingsCpp.onlyDisplaySipUriUsername ? UtilsCpp.getUsername(_initialText) : _initialText

View file

@ -193,8 +193,10 @@ Item {
id: magicSearchBar
Layout.fillWidth: true
//: "Rechercher un contact, appeler %1"
//: "ou envoyer un message "
placeholderText: qsTr("searchbar_placeholder_text").arg(SettingsCpp.disableChatFeature ? "…" : qsTr("searchbar_placeholder_text_chat_feature_enabled"))
placeholderText: qsTr("searchbar_placeholder_text").arg(SettingsCpp.disableChatFeature
? "…"
//: "ou envoyer un message "
: qsTr("searchbar_placeholder_text_chat_feature_enabled"))
focusedBorderColor: DefaultStyle.main1_500_main
numericPadButton.visible: text.length === 0
numericPadButton.checkable: false

View file

@ -63,8 +63,8 @@ AbstractSettingsLayout {
spacing: Math.round(40 * DefaultStyle.dp)
SwitchSetting {
Layout.fillWidth: true
//: "Démarrer automatiquement Linphone"
titleText: qsTr("settings_advanced_auto_start_title")
//: "Démarrer automatiquement %1"
titleText: qsTr("settings_advanced_auto_start_title").arg(applicationName)
propertyName: "autoStart"
propertyOwner: SettingsCpp
}

View file

@ -55,8 +55,10 @@ AbstractSettingsLayout {
visible: !SettingsCpp.disableCallRecordings
}
SwitchSetting {
titleText: qsTr("Tonalités")
subTitleText: qsTr("Activer les tonalités")
//: Tonalités
titleText: qsTr("settings_call_enable_tones_title")
//: Activer les tonalités
subTitleText: qsTr("settings_call_enable_tones_subtitle")
propertyName: "callToneIndicationsEnabled"
propertyOwner: SettingsCpp
}

View file

@ -27,19 +27,22 @@ AbstractSettingsLayout {
if (carddavGui.core.isValid()) {
carddavGui.core.save()
} else {
//: "Vérifiez que toutes les informations ont été saisies."
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"), qsTr("settings_contacts_carddav_popup_invalid_error"), false, mainWindow)
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"),
//: "Vérifiez que toutes les informations ont été saisies."
qsTr("settings_contacts_carddav_popup_invalid_error"), false, mainWindow)
}
}
Connections {
target: carddavGui.core
function onSaved(success) {
if (success)
//: "Le carnet d'adresse CardDAV est synchronisé."
UtilsCpp.showInformationPopup(qsTr("information_popup_synchronization_success_title"), qsTr("settings_contacts_carddav_synchronization_success_message"), true, mainWindow)
UtilsCpp.showInformationPopup(qsTr("information_popup_synchronization_success_title"),
//: "Le carnet d'adresse CardDAV est synchronisé."
qsTr("settings_contacts_carddav_synchronization_success_message"), true, mainWindow)
else
//: "Erreur de synchronisation!"
UtilsCpp.showInformationPopup(qsTr("settings_contacts_carddav_popup_synchronization_error_title"), qsTr("settings_contacts_carddav_popup_synchronization_error_message"), false, mainWindow)
UtilsCpp.showInformationPopup(qsTr("settings_contacts_carddav_popup_synchronization_error_title"),
//: "Erreur de synchronisation!"
qsTr("settings_contacts_carddav_popup_synchronization_error_message"), false, mainWindow)
}
}
Component {

View file

@ -12,7 +12,7 @@ AbstractSettingsLayout {
{
//: Annuaires LDAP
title: qsTr("settings_contacts_ldap_title"),
//: "Ajouter vos annuaires LDAP pour pouvoir effectuer des recherches dans la magic search bar."
//: "Ajouter vos annuaires LDAP pour pouvoir effectuer des recherches dans la barre de recherche."
subTitle: qsTr("settings_contacts_ldap_subtitle"),
contentComponent: ldapParametersComponent,
hideTopMargin: true

View file

@ -89,8 +89,9 @@ RowLayout {
Connections {
target: modelData.core
function onSavedChanged() {
//: "Les changements ont été sauvegardés"
if (modelData.core.saved) UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"), qsTr("information_popup_changes_saved"), true, mainWindow)
if (modelData.core.saved) UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"),
//: "Les changements ont été sauvegardés"
qsTr("information_popup_changes_saved"), true, mainWindow)
}
}

View file

@ -26,11 +26,13 @@ AbstractSettingsLayout {
onSave: {
if (ldapGui.core.isValid()) {
ldapGui.core.save()
//: "L'annuaire LDAP a été sauvegardé"
UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"), qsTr("settings_contacts_ldap_success_toast"), true, mainWindow)
UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"),
//: "L'annuaire LDAP a été sauvegardé"
qsTr("settings_contacts_ldap_success_toast"), true, mainWindow)
} else {
//: "Une erreur s'est produite, la configuration LDAP n'a pas été sauvegardée !"
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"), qsTr("settings_contacts_ldap_error_toast"), false, mainWindow)
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"),
//: "Une erreur s'est produite, la configuration LDAP n'a pas été sauvegardée !"
qsTr("settings_contacts_ldap_error_toast"), false, mainWindow)
}
}

View file

@ -231,9 +231,10 @@ AbstractMainPage {
visible: historyListView.count === 0
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: Math.round(137 * DefaultStyle.dp)
//: "Aucun appel dans votre historique"
//: "Aucun résultat"
text: searchBar.text.length != 0 ? qsTr("list_filter_no_result_found") : qsTr("history_list_empty_history")
text: searchBar.text.length != 0 ? qsTr("list_filter_no_result_found")
//: "Aucun appel dans votre historique"
: qsTr("history_list_empty_history")
font {
pixelSize: Typography.h4.pixelSize
weight: Typography.h4.weight
@ -389,7 +390,7 @@ AbstractMainPage {
}
Text {
//: "%n participant(s) sélectionné(s)"
text: qsTr("group_call_participant_selected").arg(mainItem.selectedParticipantsCount)
text: qsTr("group_call_participant_selected", '', mainItem.selectedParticipantsCount).arg(mainItem.selectedParticipantsCount)
color: DefaultStyle.main2_500main
maximumLineCount: 1
font {

View file

@ -4,6 +4,7 @@ import QtQuick.Effects
import QtQuick.Controls.Basic as Control
import Linphone
import UtilsCpp
import SettingsCpp
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
RowLayout {

View file

@ -705,7 +705,7 @@ FriendGui{
property var listViewModelData: modelData
property var callObj
property CallGui deviceCall: callObj ? callObj.value : null
//: "Appareil sans nom"
//: "Appareil inconnu"
property string deviceName: listViewModelData.name.length != 0 ? listViewModelData.name : qsTr("contact_device_without_name")
Text {
text: deviceDelegate.deviceName

View file

@ -308,8 +308,7 @@ AbstractMainPage {
}
else if (meetingSetup.conferenceInfoGui.core.schedulerState == LinphoneEnums.ConferenceSchedulerState.AllocationPending
|| meetingSetup.conferenceInfoGui.core.schedulerState == LinphoneEnums.ConferenceSchedulerState.Updating) {
//: Création de la réunion en cours
mainWin.showLoadingPopup(qsTr("meeting_schedule_creation_processing"), true, function () {
mainWin.showLoadingPopup(qsTr("meeting_schedule_creation_in_progress"), true, function () {
leftPanelStackView.pop()
})
} else {
@ -532,8 +531,8 @@ AbstractMainPage {
}
Text {
//: "%n participant(s) sélectionné(s)"
text: qsTr("group_call_participant_selected").arg(addParticipantLayout.selectedParticipantsCount)
color: DefaultStyle.main2_500main
text: qsTr("group_call_participant_selected", '', addParticipantLayout.selectedParticipantsCount).arg(addParticipantLayout.selectedParticipantsCount)
color: DefaultStyle.main2_500main
Layout.leftMargin: addParticipantsBackButton.width + addParticipantsButtons.spacing
maximumLineCount: 1
font {

View file

@ -131,8 +131,9 @@ AbstractWindow {
function joinConference(uri, options) {
if (uri.length === 0)
//: "La conférence n'a pas pu démarrer en raison d'une erreur d'uri."
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"), qsTr("conference_error_empty_uri"),mainWindow)
UtilsCpp.showInformationPopup(qsTr("information_popup_error_title"),
//: "La conférence n'a pas pu démarrer en raison d'une erreur d'uri."
qsTr("conference_error_empty_uri"),mainWindow)
else {
UtilsCpp.createCall(uri, options)
}
@ -560,8 +561,8 @@ AbstractWindow {
: mainWindow.conference
//: "Un participant enregistre la réunion"
? qsTr("conference_remote_is_recording")
//: "Votre correspondant enregistre l'appel"
: qsTr("call_remote_recording")
//: "%1 enregistre l'appel"
: qsTr("call_remote_recording").arg(mainWindow.call.core.remoteName)
: ""
}
}
@ -942,7 +943,7 @@ AbstractWindow {
searchBarColor: DefaultStyle.grey_0
searchBarBorderColor: DefaultStyle.grey_200
onSelectedParticipantsCountChanged: {
rightPanel.headerSubtitleText = qsTr("group_call_participant_selected").arg(selectedParticipantsCount)
rightPanel.headerSubtitleText = qsTr("group_call_participant_selected", '', selectedParticipantsCount).arg(selectedParticipantsCount)
participantsStack.selectedParticipants = selectedParticipants
}
Connections {
@ -950,7 +951,7 @@ AbstractWindow {
function onCurrentItemChanged() {
if (participantsStack.currentItem == addParticipantLayout) {
rightPanel.headerTitleText = qsTr("meeting_schedule_add_participants_title")
rightPanel.headerSubtitleText = qsTr("group_call_participant_selected").arg(addParticipantLayout.selectedParticipants.length)
rightPanel.headerSubtitleText = qsTr("group_call_participant_selected", '', addParticipantLayout.selectedParticipants.length).arg(addParticipantLayout.selectedParticipants.length)
}
}
}

View file

@ -101,9 +101,10 @@ AbstractWindow {
initStackViewItem()
}
function onIsSavedChanged() {
//: "Les changements ont été sauvegardés"
if (SettingsCpp.isSaved) UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"), qsTr("information_popup_changes_saved"), true, mainWindow)
}
if (SettingsCpp.isSaved) UtilsCpp.showInformationPopup(qsTr("information_popup_success_title"),
//: "Les changements ont été sauvegardés"
qsTr("information_popup_changes_saved"), true, mainWindow)
}
}
Connections {