[jitsi-dev] [jitsi] MainToolBar.call : Display chat transport resource name along with name (#35)


#1

In Jitsi desktop version, in the case of Jabber/XMPP accounts (specifically Google Talk), if a contact is signed in through multiple clients (Jitsi, Google Hangouts), each client has a unique resource ID. (For Jitsi, jitsi-xxxxx and for Hangouts, Messaging-xxxxx)

In a chat panel, when the audio/video call button is clicked, a dropdown menu is shown, with the list of different XMPP addresses - however only the main address is shown (user@servername - e.g sandy.8925@gmail.com) - the resource portion (jitsi-xxxx,Messaging-xxxx) is not shown. (see attached picture)
![jitsi_xmpp_dropdown_problem](https://cloud.githubusercontent.com/assets/830671/3223422/c08cae2a-f022-11e3-9bc4-1791321bf924.jpg)

So, when attempting to start an audio/video call through Jitsi, it is difficult to identify which endpoint/client needs to be selected since the resource is not shown - instead a list of multiple copies of the same email address is shown. This is important since Googlngouts will not support audio/video calls with Jitsi, and the Jitsi client needs to be selected specifically.
You can merge this Pull Request by running:

  git pull https://github.com/sandy-8925/jitsi show_resource_in_dropdown

Or you can view, comment on it, or merge it online at:

  https://github.com/jitsi/jitsi/pull/35

-- Commit Summary --

  * MainToolBar.call : Display chat transport resource name along with name

-- File Changes --

    M src/net/java/sip/communicator/impl/gui/main/chat/toolBars/MainToolBar.java (2)

-- Patch Links --

https://github.com/jitsi/jitsi/pull/35.patch
https://github.com/jitsi/jitsi/pull/35.diff

···

---
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35


#2

I think it would be very nice to have the resource shown in the list, but this solution breaks calling for me -- calls fail with "blabla@jit.si-jitsi-3si32jj does not belong to our contact list". Also, some resources are null, in which case it tries to call "blabla@jit.si-null".

···

---
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35#issuecomment-45582149


#3

Ok, it looks like the string used for display is also used for calling, which causes this problem. I will try to come up with a way to display the way we want, but call correctly.

···

---
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35#issuecomment-45706641


#4

Hi, I don't know how to do my pull request together with this one, but I wrote a solution which works atleast with xmpp (I tested it with google).
For more details check "VoiceCall Target resource"

···

---
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35#issuecomment-46671811


#5

@@ -698,7 +698,7 @@ private void call(boolean isVideo, boolean isDesktopSharing)
             m.put(opSetClass, ct.getProtocolProvider());

             UIContactDetailImpl d = new UIContactDetailImpl(
- ct.getName(),
+ ct.getName() + " - " + ct.getResourceName(),
                                                 ct.getDisplayName(),

I just noticed this displayName parameter - it is described as a user-friendly name to be used when interacting with the user. We could pass the address + resource here, and then modify ChooseCallAccountPopupMenu.ContactMenuItem constructor to use UIContactDetailImpl.getDisplayName method. Then, it will display correctly and call the right contact.

···

---
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35/files#r14059336


#6

Closing in favor of #37

···

--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35#issuecomment-273633999


#7

Closed #35.

···

--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jitsi/jitsi/pull/35#event-928322607