diff --git a/retroshare-gui/src/gui/chat/ChatWidget.cpp b/retroshare-gui/src/gui/chat/ChatWidget.cpp index f31ee3b31..15736c786 100644 --- a/retroshare-gui/src/gui/chat/ChatWidget.cpp +++ b/retroshare-gui/src/gui/chat/ChatWidget.cpp @@ -1088,8 +1088,8 @@ void ChatWidget::updateStatusTyping() #ifdef ONLY_FOR_LINGUIST tr("is typing..."); #endif - - rsMsgs->sendStatusString(chatId, "is typing..."); + if(!Settings->getChatDoNotSendIsTyping()) + rsMsgs->sendStatusString(chatId, "is typing..."); lastStatusSendTime = time(NULL) ; } } diff --git a/retroshare-gui/src/gui/settings/ChatPage.cpp b/retroshare-gui/src/gui/settings/ChatPage.cpp index e4e32abdf..2293d41a0 100644 --- a/retroshare-gui/src/gui/settings/ChatPage.cpp +++ b/retroshare-gui/src/gui/settings/ChatPage.cpp @@ -131,6 +131,7 @@ ChatPage::save(QString &/*errmsg*/) Settings->setChatSendMessageWithCtrlReturn(ui.sendMessageWithCtrlReturn->isChecked()); Settings->setChatSendAsPlainTextByDef(ui.sendAsPlainTextByDef->isChecked()); Settings->setChatLoadEmbeddedImages(ui.loadEmbeddedImages->isChecked()); + Settings->setChatDoNotSendIsTyping(ui.DontSendTyping->isChecked()); Settings->setChatSearchCharToStartSearch(ui.sbSearch_CharToStart->value()); Settings->setChatSearchCaseSensitively(ui.cbSearch_CaseSensitively->isChecked()); @@ -240,6 +241,7 @@ ChatPage::load() ui.sendMessageWithCtrlReturn->setChecked(Settings->getChatSendMessageWithCtrlReturn()); ui.sendAsPlainTextByDef->setChecked(Settings->getChatSendAsPlainTextByDef()); ui.loadEmbeddedImages->setChecked(Settings->getChatLoadEmbeddedImages()); + ui.DontSendTyping->setChecked(Settings->getChatDoNotSendIsTyping()); ui.sbSearch_CharToStart->setValue(Settings->getChatSearchCharToStartSearch()); ui.cbSearch_CaseSensitively->setChecked(Settings->getChatSearchCaseSensitively()); diff --git a/retroshare-gui/src/gui/settings/ChatPage.ui b/retroshare-gui/src/gui/settings/ChatPage.ui index d9569af3f..de8ffbdb4 100644 --- a/retroshare-gui/src/gui/settings/ChatPage.ui +++ b/retroshare-gui/src/gui/settings/ChatPage.ui @@ -271,6 +271,13 @@ + + + + Do not send typing notifications + + + diff --git a/retroshare-gui/src/gui/settings/rsharesettings.cpp b/retroshare-gui/src/gui/settings/rsharesettings.cpp index 46ecdd147..553417ee5 100644 --- a/retroshare-gui/src/gui/settings/rsharesettings.cpp +++ b/retroshare-gui/src/gui/settings/rsharesettings.cpp @@ -514,6 +514,16 @@ void RshareSettings::setChatSendMessageWithCtrlReturn(bool bValue) setValueToGroup("Chat", "SendMessageWithCtrlReturn", bValue); } +bool RshareSettings::getChatDoNotSendIsTyping() +{ + return valueFromGroup("Chat", "DoNotSendIsTyping", false).toBool(); +} + +void RshareSettings::setChatDoNotSendIsTyping(bool bValue) +{ + setValueToGroup("Chat", "DoNotSendIsTyping", bValue); +} + bool RshareSettings::getChatSendAsPlainTextByDef() { return valueFromGroup("Chat", "SendAsPlainTextByDef", false).toBool(); diff --git a/retroshare-gui/src/gui/settings/rsharesettings.h b/retroshare-gui/src/gui/settings/rsharesettings.h index 9ad2d31ff..8f544f903 100644 --- a/retroshare-gui/src/gui/settings/rsharesettings.h +++ b/retroshare-gui/src/gui/settings/rsharesettings.h @@ -210,6 +210,9 @@ public: bool getChatSendMessageWithCtrlReturn(); void setChatSendMessageWithCtrlReturn(bool bValue); + bool getChatDoNotSendIsTyping(); + void setChatDoNotSendIsTyping(bool bValue); + bool getChatSendAsPlainTextByDef(); void setChatSendAsPlainTextByDef(bool bValue);