aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java
diff options
context:
space:
mode:
authorLyubomir Marinov <lyubomir.marinov@jitsi.org>2012-02-22 11:11:53 +0000
committerLyubomir Marinov <lyubomir.marinov@jitsi.org>2012-02-22 11:11:53 +0000
commit054a8a24933a0f90b3e9a085d271cb308c2998a5 (patch)
treea1d26f5906d658c6732a6a68df4d05801d4f06b5 /src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java
parent6b7a06bc6c992866350886dc70744687a7e7d565 (diff)
downloadjitsi-054a8a24933a0f90b3e9a085d271cb308c2998a5.zip
jitsi-054a8a24933a0f90b3e9a085d271cb308c2998a5.tar.gz
jitsi-054a8a24933a0f90b3e9a085d271cb308c2998a5.tar.bz2
Tries to always use one and the same Call for conference members from one and the same ProtocolProvider regardless of whether the Call is cross-protocol or not.
Diffstat (limited to 'src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java')
-rw-r--r--src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java35
1 files changed, 11 insertions, 24 deletions
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java b/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java
index beab812..cdef0f7 100644
--- a/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java
+++ b/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetBasicTelephonyJabberImpl.java
@@ -344,7 +344,8 @@ public class OperationSetBasicTelephonyJabberImpl
boolean isGingle = false;
String gingleURI = null;
- // choose the resource that has the highest priority AND support Jingle
+ // Choose the resource which has the highest priority AND supports
+ // Jingle.
while(it.hasNext())
{
Presence presence = it.next();
@@ -381,24 +382,14 @@ public class OperationSetBasicTelephonyJabberImpl
isGingle = false;
}
}
- else
+ else if (protocolProvider.isGTalkTesting() /* test GTALK property */
+ /* see if peer supports Google Talk voice */
+ && (hasGtalkCaps || alwaysCallGtalk)
+ && (priority > bestPriority))
{
- // test GTALK property
- if(!protocolProvider.isGTalkTesting())
- {
- continue;
- }
-
- /* see if peer supports Google Talk voice */
- if(hasGtalkCaps || alwaysCallGtalk)
- {
- if(priority > bestPriority)
- {
- bestPriority = priority;
- isGingle = true;
- gingleURI = calleeURI;
- }
- }
+ bestPriority = priority;
+ isGingle = true;
+ gingleURI = calleeURI;
}
}
@@ -417,9 +408,7 @@ public class OperationSetBasicTelephonyJabberImpl
if(isGingle)
{
if(logger.isInfoEnabled())
- {
logger.info(gingleURI + ": Google Talk dialect supported");
- }
fullCalleeURI = gingleURI;
}
else if(di != null)
@@ -430,8 +419,8 @@ public class OperationSetBasicTelephonyJabberImpl
else
{
if (logger.isInfoEnabled())
- logger.info(calleeURI +
- ": jingle and Google Talk not supported ?");
+ logger.info(
+ calleeURI + ": jingle and Google Talk not supported?");
throw new OperationFailedException(
"Failed to create OutgoingJingleSession.\n"
@@ -440,9 +429,7 @@ public class OperationSetBasicTelephonyJabberImpl
}
if(logger.isInfoEnabled())
- {
logger.info("Choose one is: " + fullCalleeURI + " " + bestPriority);
- }
AbstractCallPeer<?, ?> peer = null;