Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-daemon
Commits
5ef841a9
Commit
5ef841a9
authored
May 02, 2006
by
yanmorin
Browse files
Fix flashing button bug
parent
3f11928a
Changes
6
Hide whitespace changes
Inline
Side-by-side
CHANGES
View file @
5ef841a9
SFLphoned (0.7.0) / 2006-..-..
*
partially
fix: click on
a
flashing button
(only if the button is not red)
* fix: click on flashing button
s
* fix: send ringing, hangup, busy message
* fix for using call command two times in a row
* add --disable-sflphoneqt 2006-05-01
...
...
src/call.h
View file @
5ef841a9
...
...
@@ -65,6 +65,11 @@ public:
void
setPeerName
(
const
std
::
string
&
name
)
{
_peerName
=
name
;
}
const
std
::
string
&
getPeerName
()
{
return
_peerName
;
}
/**
* Tell if the call is incoming
*/
bool
isIncoming
()
{
return
(
_type
==
Incoming
)
?
true
:
false
;
}
/**
* Set the connection state of the call (protected by mutex)
*/
...
...
src/gui/qt/PhoneLineButton.cpp
View file @
5ef841a9
/*
* Copyright (C) 2004-2005 Savoir-Faire Linux inc.
* Copyright (C) 2004-2006 Savoir-Faire Linux inc.
* Author: Yan Morin <yan.morin@savoirfairelinux.com>
* Author: Jean-Philippe Barrette-LaPierre
* <jean-philippe.barrette-lapierre@savoirfairelinux.com>
*
...
...
@@ -41,6 +42,7 @@ PhoneLineButton::PhoneLineButton(unsigned int line,
this
,
SLOT
(
swap
()));
connect
(
this
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
sendClicked
()));
mIsFlashing
=
false
;
}
void
...
...
@@ -65,6 +67,7 @@ void
PhoneLineButton
::
suspend
()
{
setDown
(
false
);
mIsFlashing
=
true
;
mTimer
->
start
(
500
);
}
...
...
@@ -72,11 +75,18 @@ void
PhoneLineButton
::
sendClicked
()
{
if
(
isOn
())
{
mIsFlashing
=
false
;
mTimer
->
stop
();
emit
selected
(
mLine
);
}
else
{
emit
unselected
(
mLine
);
if
(
mIsFlashing
)
{
mIsFlashing
=
false
;
mTimer
->
stop
();
emit
selected
(
mLine
);
}
else
{
emit
unselected
(
mLine
);
}
}
}
src/gui/qt/PhoneLineButton.hpp
View file @
5ef841a9
/*
* Copyright (C) 2004-2005 Savoir-Faire Linux inc.
* Copyright (C) 2004-2006 Savoir-Faire Linux inc.
* Author: Yan Morin <yan.morin@savoirfairelinux.com>
* Author: Jean-Philippe Barrette-LaPierre
* <jean-philippe.barrette-lapierre@savoirfairelinux.com>
*
...
...
@@ -59,7 +60,12 @@ private:
unsigned
int
mLine
;
QTimer
*
mTimer
;
unsigned
int
mFace
;
/**
* If the line is flashing, we want to retreive it
* on or off
*/
bool
mIsFlashing
;
};
#endif // defined(__J_PUSH_BUTTON_H__)
src/managerimpl.cpp
View file @
5ef841a9
...
...
@@ -389,9 +389,13 @@ ManagerImpl::refuseCall (const CallID& id)
return
false
;
}
bool
returnValue
=
getAccountLink
(
accountid
)
->
refuse
(
id
);
removeWaitingCall
(
id
);
removeCallAccount
(
id
);
switchCall
(
""
);
// if the call was outgoing or established, we didn't refuse it
// so the method did nothing
if
(
returnValue
)
{
removeWaitingCall
(
id
);
removeCallAccount
(
id
);
switchCall
(
""
);
}
return
returnValue
;
}
...
...
src/sipvoiplink.cpp
View file @
5ef841a9
...
...
@@ -773,8 +773,16 @@ bool
SIPVoIPLink
::
refuse
(
const
CallID
&
id
)
{
SIPCall
*
call
=
getSIPCall
(
id
);
if
(
call
==
0
)
{
_debug
(
"Call doesn't exist
\n
"
);
return
false
;
}
// can't refuse outgoing call or connected
if
(
!
call
->
isIncoming
()
||
call
->
getConnectionState
()
==
Call
::
Connected
)
{
_debug
(
"It's not an incoming call, or it's already answered
\n
"
);
return
false
;
}
osip_message_t
*
answerMessage
=
NULL
;
eXosip_lock
();
// not BUSY.. where decline the invitation!
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment