mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
Fixed display of the friend status in chat window.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5014 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
499003d875
commit
fedba02d18
@ -162,11 +162,11 @@ void AudioPopupChatDialog::sendAudioData() {
|
||||
}
|
||||
}
|
||||
|
||||
void AudioPopupChatDialog::updateStatus(const QString& peer_id,int status)
|
||||
void AudioPopupChatDialog::updateStatus(int status)
|
||||
{
|
||||
audioListenToggleButton->setEnabled(true);
|
||||
audioMuteCaptureToggleButton->setEnabled(true);
|
||||
|
||||
updateStatus(peer_id,status) ;
|
||||
PopupChatDialog::updateStatus(status) ;
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ class AudioPopupChatDialog: public PopupChatDialog
|
||||
QtSpeex::SpeexInputProcessor* inputProcessor;
|
||||
QtSpeex::SpeexOutputProcessor* outputProcessor;
|
||||
|
||||
virtual void updateStatus(const QString& peer_id,int status) ;
|
||||
virtual void updateStatus(int status) ;
|
||||
|
||||
QPushButton *audioListenToggleButton ;
|
||||
QPushButton *audioMuteCaptureToggleButton ;
|
||||
|
@ -657,6 +657,7 @@ void ChatWidget::updateStatus(const QString &peer_id, int status)
|
||||
}
|
||||
|
||||
emit infoChanged(this);
|
||||
emit statusChanged(status);
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -78,17 +78,18 @@ private slots:
|
||||
void clearChatHistory();
|
||||
void deleteChatHistory();
|
||||
void messageHistory();
|
||||
void updateStatus(const QString &peer_id, int status);
|
||||
|
||||
signals:
|
||||
void infoChanged(ChatWidget*);
|
||||
void newMessage(ChatWidget*);
|
||||
void statusChanged(int);
|
||||
|
||||
protected:
|
||||
bool eventFilter(QObject *obj, QEvent *event);
|
||||
virtual void showEvent(QShowEvent *event);
|
||||
virtual void resizeEvent(QResizeEvent *event);
|
||||
void updateTitle();
|
||||
virtual void updateStatus(const QString &peer_id, int status);
|
||||
void resetStatusBar() ;
|
||||
|
||||
private slots:
|
||||
|
@ -52,6 +52,8 @@ PopupChatDialog::PopupChatDialog(QWidget *parent, Qt::WFlags flags)
|
||||
|
||||
void PopupChatDialog::init(const std::string &peerId, const QString &title)
|
||||
{
|
||||
connect(ui.chatWidget, SIGNAL(statusChanged(int)), this, SLOT(statusChanged(int)));
|
||||
|
||||
ChatDialog::init(peerId, title);
|
||||
|
||||
/* Hide or show the avatar frames */
|
||||
@ -227,3 +229,8 @@ void PopupChatDialog::clearOfflineMessages()
|
||||
rsMsgs->clearPrivateChatQueue(false, peerId);
|
||||
manualDelete = false;
|
||||
}
|
||||
|
||||
void PopupChatDialog::statusChanged(int status)
|
||||
{
|
||||
updateStatus(status);
|
||||
}
|
||||
|
@ -38,6 +38,7 @@ private slots:
|
||||
void showAvatarFrame(bool show);
|
||||
void clearOfflineMessages();
|
||||
void chatStatusChanged(const QString &peerId, const QString &statusString, bool isPrivateChat);
|
||||
void statusChanged(int);
|
||||
|
||||
protected:
|
||||
/** Default constructor */
|
||||
@ -50,6 +51,8 @@ protected:
|
||||
virtual ChatWidget *getChatWidget();
|
||||
virtual bool hasPeerStatus() { return true; }
|
||||
|
||||
virtual void updateStatus(int /*status*/) {}
|
||||
|
||||
void processSettings(bool load);
|
||||
|
||||
// used by plugins
|
||||
|
Loading…
Reference in New Issue
Block a user