mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-05 07:35:12 -04:00
Added Decline Button to Voip Toaster
Added new stylesheet from Beluga for the voip buttons
This commit is contained in:
parent
afa3f53b14
commit
2cc0f6dcd7
7 changed files with 183 additions and 62 deletions
|
@ -39,18 +39,19 @@ VOIPToasterItem::VOIPToasterItem(const RsPeerId &peer_id, const QString &msg, co
|
|||
|
||||
switch (mType){
|
||||
case AudioCall:
|
||||
toasterButton->setIcon(QIcon("://images/call-start.png"));
|
||||
toasterButton->setText(tr("Answer"));
|
||||
//acceptButton->setIcon(QIcon("://images/call-start.png"));
|
||||
acceptButton->setText(tr("Answer"));
|
||||
break;
|
||||
case VideoCall:
|
||||
toasterButton->setIcon(QIcon("://images/video-icon-on.png"));
|
||||
toasterButton->setText(tr("Answer with video"));
|
||||
acceptButton->setIcon(QIcon("://images/video-icon-on.png"));
|
||||
acceptButton->setText(tr("Answer with video"));
|
||||
break;
|
||||
default:
|
||||
ChatDialog::chatFriend(ChatId(mPeerId));
|
||||
}
|
||||
|
||||
connect(toasterButton, SIGNAL(clicked()), SLOT(chatButtonSlot()));
|
||||
connect(acceptButton, SIGNAL(clicked()), SLOT(chatButtonSlot()));
|
||||
connect(declineButton, SIGNAL(clicked()), SLOT(declineButtonSlot()));
|
||||
connect(closeButton, SIGNAL(clicked()), SLOT(hide()));
|
||||
|
||||
/* set informations */
|
||||
|
@ -79,6 +80,21 @@ void VOIPToasterItem::chatButtonSlot()
|
|||
hide();
|
||||
}
|
||||
|
||||
void VOIPToasterItem::declineButtonSlot()
|
||||
{
|
||||
switch (mType){
|
||||
case AudioCall:
|
||||
VOIPGUIHandler::HangupAudioCall(mPeerId);
|
||||
break;
|
||||
case VideoCall:
|
||||
VOIPGUIHandler::HangupVideoCall(mPeerId);
|
||||
break;
|
||||
default:
|
||||
ChatDialog::chatFriend(ChatId(mPeerId));
|
||||
}
|
||||
hide();
|
||||
}
|
||||
|
||||
#ifdef VOIPTOASTERNOTIFY_ALL
|
||||
void VOIPToasterItem::voipAcceptReceived(const RsPeerId &, int )
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue