diff --git a/src/widget/form/chatform.cpp b/src/widget/form/chatform.cpp index 73477fbff..08391180e 100644 --- a/src/widget/form/chatform.cpp +++ b/src/widget/form/chatform.cpp @@ -1085,5 +1085,17 @@ void ChatForm::hideNetcam() void ChatForm::retranslateUi() { + QString volObjectName = volButton->objectName(); + QString micObjectName = micButton->objectName(); loadHistoryAction->setText(tr("Load chat history...")); + + if (volObjectName == QStringLiteral("green")) + volButton->setToolTip(tr("Mute call")); + else if (volObjectName == QStringLiteral("red")) + volButton->setToolTip(tr("Unmute call")); + + if (micObjectName == QStringLiteral("green")) + micButton->setToolTip(tr("Mute microphone")); + else if (micObjectName == QStringLiteral("red")) + micButton->setToolTip(tr("Unmute microphone")); } diff --git a/src/widget/form/genericchatform.cpp b/src/widget/form/genericchatform.cpp index ec86c0304..69ce5ff35 100644 --- a/src/widget/form/genericchatform.cpp +++ b/src/widget/form/genericchatform.cpp @@ -512,12 +512,27 @@ bool GenericChatForm::eventFilter(QObject* object, QEvent* event) void GenericChatForm::retranslateUi() { + QString callObjectName = callButton->objectName(); + QString videoObjectName = videoButton->objectName(); + + if (callObjectName == QStringLiteral("green")) + callButton->setToolTip(tr("Start audio call")); + else if (callObjectName == QStringLiteral("yellow")) + callButton->setToolTip(tr("Accept audio call")); + else if (callObjectName == QStringLiteral("red")) + callButton->setToolTip(tr("End audio call")); + + if (videoObjectName == QStringLiteral("green")) + videoButton->setToolTip(tr("Start video call")); + else if (videoObjectName == QStringLiteral("yellow")) + videoButton->setToolTip(tr("Accept video call")); + else if (videoObjectName == QStringLiteral("red")) + videoButton->setToolTip(tr("End video call")); + sendButton->setToolTip(tr("Send message")); emoteButton->setToolTip(tr("Smileys")); fileButton->setToolTip(tr("Send file(s)")); screenshotButton->setToolTip(tr("Send a screenshot")); - callButton->setToolTip(tr("Start an audio call")); - videoButton->setToolTip(tr("Start a video call")); saveChatAction->setText(tr("Save chat log")); clearAction->setText(tr("Clear displayed messages")); }