Save incoming not read private chat messages in config and delete it after reading.

Added queue for outgoing private offline chat messages. The queue is also saved until the private chat message could be delivered.
It does not work in the short time between the shutdown of the peer and the switch of the state to offline for that peer. For this we need a response of the peer.
Need recompile.

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3517 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2010-09-21 00:08:06 +00:00
parent 412cf5f928
commit 37fe5ff3a3
19 changed files with 709 additions and 236 deletions

View file

@ -308,6 +308,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
/* call once */
updateMessages();
updateForums();
privateChatChanged(NOTIFY_LIST_PRIVATE_INCOMING_CHAT, NOTIFY_TYPE_ADD);
idle = new Idle();
idle->start();
@ -511,18 +512,20 @@ void MainWindow::updateStatus()
}
}
void MainWindow::privateChatChanged(int type)
void MainWindow::privateChatChanged(int list, int type)
{
/* first process the chat messages */
PopupChatDialog::privateChatChanged();
PopupChatDialog::privateChatChanged(list, type);
/* than count the chat messages */
int chatCount = rsMsgs->getChatQueueCount(true);
if (list == NOTIFY_LIST_PRIVATE_INCOMING_CHAT) {
/* than count the chat messages */
int chatCount = rsMsgs->getPrivateChatQueueCount(true);
if (chatCount) {
trayIconChat->show();
} else {
trayIconChat->hide();
if (chatCount) {
trayIconChat->show();
} else {
trayIconChat->hide();
}
}
}
@ -833,7 +836,7 @@ void MainWindow::trayIconChatClicked(QSystemTrayIcon::ActivationReason e)
if(e == QSystemTrayIcon::Trigger || e == QSystemTrayIcon::DoubleClick) {
PopupChatDialog *pcd = NULL;
std::list<std::string> ids;
if (rsMsgs->getPrivateChatQueueIds(ids) && ids.size()) {
if (rsMsgs->getPrivateChatQueueIds(true, ids) && ids.size()) {
pcd = PopupChatDialog::getPrivateChat(ids.front(), RS_CHAT_OPEN_NEW | RS_CHAT_REOPEN | RS_CHAT_FOCUS);
}

View file

@ -141,7 +141,7 @@ public slots:
void checkAndSetIdle(int idleTime);
void updateMessages();
void updateForums();
void privateChatChanged(int type);
void privateChatChanged(int list, int type);
protected:
/** Default Constructor */

View file

@ -439,7 +439,7 @@ void MessengerWindow::insertPeers()
std::list<std::string> privateChatIds;
#ifndef MINIMAL_RSGUI
rsMsgs->getPrivateChatQueueIds(privateChatIds);
rsMsgs->getPrivateChatQueueIds(true, privateChatIds);
#endif // MINIMAL_RSGUI
rsPeers->getGPGAcceptedList(gpgFriends);

View file

@ -474,7 +474,7 @@ void PeersDialog::insertPeers()
bool bHideUnconnected = ui.action_Hide_Offline_Friends->isChecked();
std::list<std::string> privateChatIds;
rsMsgs->getPrivateChatQueueIds(privateChatIds);
rsMsgs->getPrivateChatQueueIds(true, privateChatIds);
rsPeers->getGPGAcceptedList(gpgFriends);

View file

@ -127,8 +127,10 @@ PopupChatDialog::PopupChatDialog(std::string id, std::string name,
connect(ui.colorButton, SIGNAL(clicked()), this, SLOT(setColor()));
connect(ui.emoteiconButton, SIGNAL(clicked()), this, SLOT(smileyWidget()));
connect(ui.actionSave_Chat_History, SIGNAL(triggered()), this, SLOT(fileSaveAs()));
connect(ui.actionClearOfflineMessages, SIGNAL(triggered()), this, SLOT(clearOfflineMessages()));
connect(ui.textBrowser, SIGNAL(anchorClicked(const QUrl &)), SLOT(anchorClicked(const QUrl &)));
connect(ui.offlineTextBrowser, SIGNAL(anchorClicked(const QUrl &)), SLOT(anchorClicked(const QUrl &)));
connect(NotifyQt::getInstance(), SIGNAL(peerStatusChanged(const QString&, int)), this, SLOT(updateStatus(const QString&, int)));
connect(NotifyQt::getInstance(), SIGNAL(peerHasNewCustomStateString(const QString&, const QString&)), this, SLOT(updatePeersCustomStateString(const QString&, const QString&)));
@ -164,6 +166,7 @@ PopupChatDialog::PopupChatDialog(std::string id, std::string name,
QMenu * toolmenu = new QMenu();
toolmenu->addAction(ui.actionClear_Chat);
toolmenu->addAction(ui.actionSave_Chat_History);
toolmenu->addAction(ui.actionClearOfflineMessages);
//toolmenu->addAction(ui.action_Disable_Emoticons);
ui.pushtoolsButton->setMenu(toolmenu);
@ -198,6 +201,9 @@ PopupChatDialog::PopupChatDialog(std::string id, std::string name,
updatePeersCustomStateString(QString::fromStdString(dialogId), customStateString);
ui.chattextEdit->installEventFilter(this);
// call once
onPrivateChatChanged(NOTIFY_LIST_PRIVATE_OUTGOING_CHAT, NOTIFY_TYPE_ADD);
}
/** Destructor. */
@ -321,24 +327,29 @@ void PopupChatDialog::processSettings(bool bLoad)
chatDialogs.clear();
}
/*static*/ void PopupChatDialog::privateChatChanged()
/*static*/ void PopupChatDialog::privateChatChanged(int list, int type)
{
std::list<std::string> ids;
if (!rsMsgs->getPrivateChatQueueIds(ids)) {
#ifdef PEERS_DEBUG
std::cerr << "no chat available." << std::endl ;
#endif
return;
if (list == NOTIFY_LIST_PRIVATE_INCOMING_CHAT && type == NOTIFY_TYPE_ADD) {
std::list<std::string> ids;
if (rsMsgs->getPrivateChatQueueIds(true, ids)) {
uint chatflags = Settings->getChatFlags();
std::list<std::string>::iterator id;
for (id = ids.begin(); id != ids.end(); id++) {
PopupChatDialog *pcd = getPrivateChat(*id, chatflags);
if (pcd) {
pcd->insertChatMsgs();
}
}
}
}
uint chatflags = Settings->getChatFlags();
std::list<std::string>::iterator id;
for (id = ids.begin(); id != ids.end(); id++) {
PopupChatDialog *pcd = getPrivateChat(*id, chatflags);
if (pcd) {
pcd->insertChatMsgs();
/* now notify all open priavate chat windows */
std::map<std::string, PopupChatDialog *>::iterator it;
for (it = chatDialogs.begin (); it != chatDialogs.end(); it++) {
if (it->second) {
it->second->onPrivateChatChanged(list, type);
}
}
}
@ -349,37 +360,45 @@ void PopupChatDialog::chatFriend(std::string id)
return;
}
std::cerr<<" popup dialog chat friend 1"<<std::endl;
bool oneLocationConnected = false;
RsPeerDetails detail;
if (!rsPeers->getPeerDetails(id, detail)) {
return;
}
std::string firstId;
if (detail.isOnlyGPGdetail) {
//let's get the ssl child details, and open all the chat boxes
std::list<std::string> sslIds;
rsPeers->getSSLChildListOfGPGId(detail.gpg_id, sslIds);
for (std::list<std::string>::iterator it = sslIds.begin(); it != sslIds.end(); it++) {
if (firstId.empty()) {
firstId = *it;
}
RsPeerDetails sslDetails;
if (rsPeers->getPeerDetails(*it, sslDetails)) {
if (sslDetails.state & RS_PEER_STATE_CONNECTED) {
oneLocationConnected = true;
getPrivateChat(*it, RS_CHAT_OPEN_NEW | RS_CHAT_REOPEN | RS_CHAT_FOCUS);
return;
}
}
}
} else {
if (detail.state & RS_PEER_STATE_CONNECTED) {
oneLocationConnected = true;
getPrivateChat(id, RS_CHAT_OPEN_NEW | RS_CHAT_REOPEN | RS_CHAT_FOCUS);
return;
}
firstId = id;
}
if (!oneLocationConnected) {
/* info dialog */
if ((QMessageBox::question(NULL, tr("Friend not Online"),tr("Your Friend is offline \nDo you want to send them a Message instead"),QMessageBox::Yes|QMessageBox::No, QMessageBox::Yes))== QMessageBox::Yes) {
MessageComposer::msgFriend(id);
/* info dialog */
if ((QMessageBox::question(NULL, tr("Friend not Online"),tr("Your Friend is offline \nDo you want to send them a Message instead"),QMessageBox::Yes|QMessageBox::No, QMessageBox::Yes))== QMessageBox::Yes) {
MessageComposer::msgFriend(id);
} else {
if (firstId.empty() == false) {
getPrivateChat(firstId, RS_CHAT_OPEN_NEW | RS_CHAT_REOPEN | RS_CHAT_FOCUS);
}
}
}
@ -505,6 +524,32 @@ void PopupChatDialog::updateChat()
}
void PopupChatDialog::onPrivateChatChanged(int list, int type)
{
if (list == NOTIFY_LIST_PRIVATE_OUTGOING_CHAT && type) {
std::list<ChatInfo> offlineChat;
if (rsMsgs->getPrivateChatQueueCount(false) && rsMsgs->getPrivateChatQueue(false, dialogId, offlineChat)) {
ui.actionClearOfflineMessages->setEnabled(true);
ui.offlineTextBrowser->setVisible(true);
std::list<ChatInfo>::iterator it;
for(it = offlineChat.begin(); it != offlineChat.end(); it++) {
/* are they public? */
if ((it->chatflags & RS_CHAT_PRIVATE) == 0) {
/* this should not happen */
continue;
}
addChatMsg(it->rsid, it->sendTime, it->msg, true);
}
} else {
ui.actionClearOfflineMessages->setEnabled(false);
ui.offlineTextBrowser->setVisible(false);
ui.offlineTextBrowser->clear();
}
}
}
void PopupChatDialog::insertChatMsgs()
{
if (isVisible() == false) {
@ -515,7 +560,7 @@ void PopupChatDialog::insertChatMsgs()
m_bInsertOnVisible = false;
std::list<ChatInfo> newchat;
if (!rsMsgs->getPrivateChatQueue(dialogId, newchat))
if (!rsMsgs->getPrivateChatQueue(true, dialogId, newchat))
{
#ifdef PEERS_DEBUG
std::cerr << "no chat for " << dialogId << " available." << std::endl ;
@ -531,17 +576,21 @@ void PopupChatDialog::insertChatMsgs()
continue;
}
addChatMsg(it->rsid, it->sendTime, it->msg);
addChatMsg(it->rsid, it->sendTime, it->msg, false);
}
rsMsgs->clearPrivateChatQueue(true, dialogId);
playsound();
QApplication::alert(this);
}
void PopupChatDialog::addChatMsg(std::string &id, uint sendTime, std::wstring &msg)
void PopupChatDialog::addChatMsg(std::string &id, uint sendTime, std::wstring &msg, bool offline)
{
std::string ownId = rsPeers->getOwnId();
QDateTime timestamp = QDateTime::fromTime_t(sendTime);
QString name = QString::fromStdString(rsPeers->getPeerName(id));
QString name = QString::fromStdString(rsPeers->getPeerName(offline ? ownId : id));
QString message = QString::fromStdWString(msg);
#ifdef CHAT_DEBUG
@ -555,10 +604,14 @@ void PopupChatDialog::addChatMsg(std::string &id, uint sendTime, std::wstring &m
formatFlag |= CHAT_FORMATMSG_EMBED_SMILEYS;
}
ChatStyle::enumFormatMessage type = (id == rsPeers->getOwnId()) ? ChatStyle::FORMATMSG_INCOMING : ChatStyle::FORMATMSG_OUTGOING;
ChatStyle::enumFormatMessage type = (offline == false && id == ownId) ? ChatStyle::FORMATMSG_INCOMING : ChatStyle::FORMATMSG_OUTGOING;
QString formatMsg = style.formatMessage(type, name, timestamp, message, formatFlag);
if (offline) {
ui.offlineTextBrowser->append(formatMsg);
}
ui.textBrowser->append(formatMsg);
resetStatusBar() ;
@ -627,9 +680,10 @@ void PopupChatDialog::sendChat()
std::cout << "PopupChatDialog:sendChat " << std::endl;
#endif
addChatMsg(ownId, time(NULL), msg);
if (rsMsgs->sendPrivateChat(dialogId, msg)) {
addChatMsg(ownId, time(NULL), msg, false);
}
rsMsgs->sendPrivateChat(dialogId, msg);
chatWidget->clear();
setFont();
@ -928,9 +982,9 @@ void PopupChatDialog::fileHashingFinished(AttachFileItem* file)
std::wstring msg = message.toStdWString();
addChatMsg(ownId, time(NULL), msg);
rsMsgs->sendPrivateChat(dialogId, msg);
if (rsMsgs->sendPrivateChat(dialogId, msg)) {
addChatMsg(ownId, time(NULL), msg, false);
}
}
void PopupChatDialog::anchorClicked (const QUrl& link )
@ -1062,6 +1116,11 @@ void PopupChatDialog::setCurrentFileName(const QString &fileName)
setWindowModified(false);
}
void PopupChatDialog::clearOfflineMessages()
{
rsMsgs->clearPrivateChatQueue(false, dialogId);
}
void PopupChatDialog::updateStatus(const QString &peer_id, int status)
{
std::string stdPeerId = peer_id.toStdString();

View file

@ -42,7 +42,7 @@ public:
static void cleanupChat();
static void chatFriend(std::string id);
static void updateAllAvatars();
static void privateChatChanged();
static void privateChatChanged(int list, int type);
void updateChat();
void updatePeerAvatar(const std::string&);
@ -83,7 +83,7 @@ protected:
bool eventFilter(QObject *obj, QEvent *ev);
void insertChatMsgs();
void addChatMsg(std::string &id, uint sendTime, std::wstring &msg);
void addChatMsg(std::string &id, uint sendTime, std::wstring &msg, bool offline);
void updateAvatar();
@ -108,16 +108,20 @@ private slots:
bool fileSave();
bool fileSaveAs();
void setCurrentFileName(const QString &fileName);
void clearOfflineMessages();
private:
void setCurrentFileName(const QString &fileName);
void colorChanged(const QColor &c);
void fontChanged(const QFont &font);
void addAttachment(std::string,int flag);
void processSettings(bool bLoad);
void onPrivateChatChanged(int list, int type);
QAction *actionTextBold;
QAction *actionTextUnderline;
QAction *actionTextItalic;

View file

@ -38,7 +38,7 @@ stop:0 #F6FCFF, stop:1 #F6FCFF);}</string>
<property name="verticalSpacing">
<number>1</number>
</property>
<item row="0" column="0" rowspan="4">
<item row="0" column="0" rowspan="6">
<widget class="QFrame" name="frame">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
@ -109,7 +109,7 @@ stop:0 #F6FCFF, stop:1 #F6FCFF);}</string>
</layout>
</widget>
</item>
<item row="0" column="1" rowspan="4">
<item row="0" column="1" rowspan="6">
<widget class="QFrame" name="avatarframe">
<property name="maximumSize">
<size>
@ -355,121 +355,7 @@ border-image: url(:/images/closepressed.png)
</layout>
</widget>
</item>
<item row="2" column="2">
<widget class="QSplitter" name="chatsplitter">
<property name="lineWidth">
<number>1</number>
</property>
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="handleWidth">
<number>2</number>
</property>
<widget class="QTextBrowser" name="textBrowser">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QTextBrowser{border: 1px solid #B8B6B1;
border-radius: 6px;
background: white;}</string>
</property>
<property name="html">
<string notr="true">&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="openLinks">
<bool>false</bool>
</property>
</widget>
<widget class="QWidget" name="layoutWidget">
<layout class="QGridLayout" name="gridLayout_3">
<property name="spacing">
<number>0</number>
</property>
<item row="0" column="1">
<widget class="QLabel" name="statusLabel">
<property name="text">
<string/>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="indent">
<number>3</number>
</property>
</widget>
</item>
<item row="2" column="0" colspan="2">
<widget class="QTextEdit" name="chattextEdit">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>30</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QTextEdit{border: 1px solid #B8B6B1;
border-radius: 6px;
background: white;}</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="typingpixmapLabel">
<property name="minimumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="text">
<string notr="true">T</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
<item row="3" column="2">
<item row="5" column="2">
<widget class="QFrame" name="Chatbuttonframe">
<property name="minimumSize">
<size>
@ -823,9 +709,150 @@ border: 1px solid #CCCCCC;
</layout>
</widget>
</item>
<item row="4" column="0" colspan="3">
<item row="6" column="0" colspan="3">
<layout class="QVBoxLayout" name="vboxLayout"/>
</item>
<item row="4" column="2">
<widget class="QSplitter" name="chatsplitter">
<property name="lineWidth">
<number>1</number>
</property>
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="handleWidth">
<number>2</number>
</property>
<widget class="QWidget" name="verticalLayoutWidget">
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QTextBrowser" name="textBrowser">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>100</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QTextBrowser{border: 1px solid #B8B6B1;
border-radius: 6px;
background: white;}</string>
</property>
<property name="html">
<string notr="true">&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="openLinks">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QTextBrowser" name="offlineTextBrowser">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>100</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QTextBrowser{border: 1px solid #B8B6B1;
border-radius: 6px;
background: white;}</string>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="openLinks">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="layoutWidget">
<layout class="QGridLayout" name="gridLayout_3">
<property name="spacing">
<number>0</number>
</property>
<item row="0" column="1">
<widget class="QLabel" name="statusLabel">
<property name="text">
<string/>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="indent">
<number>3</number>
</property>
</widget>
</item>
<item row="2" column="0" colspan="2">
<widget class="QTextEdit" name="chattextEdit">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>30</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QTextEdit{border: 1px solid #B8B6B1;
border-radius: 6px;
background: white;}</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="typingpixmapLabel">
<property name="minimumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="text">
<string notr="true">T</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
<widget class="QStatusBar" name="statusbar"/>
@ -916,6 +943,11 @@ border: 1px solid #CCCCCC;
<string>Save Chat History</string>
</property>
</action>
<action name="actionClearOfflineMessages">
<property name="text">
<string>Clear offline messages</string>
</property>
</action>
</widget>
<resources>
<include location="../images.qrc"/>

View file

@ -232,11 +232,12 @@ void NotifyQt::notifyListChange(int list, int type)
#endif
emit publicChatChanged(type);
break;
case NOTIFY_LIST_PRIVATE_CHAT:
case NOTIFY_LIST_PRIVATE_INCOMING_CHAT:
case NOTIFY_LIST_PRIVATE_OUTGOING_CHAT:
#ifdef NOTIFY_DEBUG
std::cerr << "received private chat changed" << std::endl ;
#endif
emit privateChatChanged(type);
emit privateChatChanged(list, type);
break;
default:
break;

View file

@ -76,7 +76,7 @@ class NotifyQt: public QObject, public NotifyBase
void peerStatusChanged(const QString& /* peer_id */, int /* status */);
void peerStatusChangedSummary() const;
void publicChatChanged(int type) const ;
void privateChatChanged(int type) const ;
void privateChatChanged(int list, int type) const ;
/* Notify from GUI */
void chatStyleChanged(int /*ChatStyle::enumStyleType*/ styleType);

View file

@ -189,7 +189,7 @@ int main(int argc, char *argv[])
QObject::connect(notify,SIGNAL(transfersChanged()) ,w->transfersDialog ,SLOT(insertTransfers() )) ;
QObject::connect(notify,SIGNAL(friendsChanged()) ,w->peersDialog ,SLOT(insertPeers() )) ;
QObject::connect(notify,SIGNAL(publicChatChanged(int)) ,w->peersDialog ,SLOT(publicChatChanged(int) ));
QObject::connect(notify,SIGNAL(privateChatChanged(int)) ,w ,SLOT(privateChatChanged(int) ));
QObject::connect(notify,SIGNAL(privateChatChanged(int, int)) ,w ,SLOT(privateChatChanged(int, int) ));
QObject::connect(notify,SIGNAL(neighborsChanged()) ,w->networkDialog ,SLOT(insertConnect() )) ;
QObject::connect(notify,SIGNAL(messagesChanged()) ,w->messagesDialog ,SLOT(insertMessages() )) ;
QObject::connect(notify,SIGNAL(messagesTagsChanged()) ,w->messagesDialog ,SLOT(messagesTagsChanged() )) ;