Browse Source

Syncs contactlist display names with thumbnails.

Uses the same display names in the contact list as in the thumbnails, for local and remote.
master
damencho 8 years ago
parent
commit
1a0677cb59
3 changed files with 8 additions and 5 deletions
  1. 0
    1
      lang/main.json
  2. 1
    1
      modules/UI/UI.js
  3. 7
    3
      modules/UI/side_pannels/contactlist/ContactList.js

+ 0
- 1
lang/main.json View File

5
     "downloadlogs": "Download logs",
5
     "downloadlogs": "Download logs",
6
     "feedback": "Give us your feedback",
6
     "feedback": "Give us your feedback",
7
     "roomUrlDefaultMsg": "Your conference is currently being created...",
7
     "roomUrlDefaultMsg": "Your conference is currently being created...",
8
-    "participant": "Participant",
9
     "me": "me",
8
     "me": "me",
10
     "speaker": "Speaker",
9
     "speaker": "Speaker",
11
     "raisedHand": "Would like to speak",
10
     "raisedHand": "Would like to speak",

+ 1
- 1
modules/UI/UI.js View File

292
     }
292
     }
293
 
293
 
294
     // Add myself to the contact list.
294
     // Add myself to the contact list.
295
-    ContactList.addContact(id);
295
+    ContactList.addContact(id, true);
296
 
296
 
297
     //update default button states before showing the toolbar
297
     //update default button states before showing the toolbar
298
     //if local role changes buttons state will be again updated
298
     //if local role changes buttons state will be again updated

+ 7
- 3
modules/UI/side_pannels/contactlist/ContactList.js View File

96
 
96
 
97
     /**
97
     /**
98
      * Adds a contact for the given id.
98
      * Adds a contact for the given id.
99
-     *
99
+     * @param isLocal is an id for the local user.
100
      */
100
      */
101
-    addContact (id) {
101
+    addContact (id, isLocal) {
102
         let contactlist = $('#contacts');
102
         let contactlist = $('#contacts');
103
 
103
 
104
         let newContact = document.createElement('li');
104
         let newContact = document.createElement('li');
112
 
112
 
113
         if (interfaceConfig.SHOW_CONTACTLIST_AVATARS)
113
         if (interfaceConfig.SHOW_CONTACTLIST_AVATARS)
114
             newContact.appendChild(createAvatar(id));
114
             newContact.appendChild(createAvatar(id));
115
-        newContact.appendChild(createDisplayNameParagraph("participant"));
115
+
116
+        newContact.appendChild(
117
+            createDisplayNameParagraph(
118
+                isLocal ? interfaceConfig.DEFAULT_LOCAL_DISPLAY_NAME : null,
119
+                isLocal ? null : interfaceConfig.DEFAULT_REMOTE_DISPLAY_NAME));
116
 
120
 
117
         if (APP.conference.isLocalId(id)) {
121
         if (APP.conference.isLocalId(id)) {
118
             contactlist.prepend(newContact);
122
             contactlist.prepend(newContact);

Loading…
Cancel
Save