Browse Source

style(LargeVideo): Rename LARGE_VIDEO_AVATAR_DISPLAYED event

j8
hristoterezov 8 years ago
parent
commit
4acfb033c8

+ 6
- 3
modules/UI/ring_overlay/RingOverlay.js View File

9
 let overlay = null;
9
 let overlay = null;
10
 
10
 
11
 /**
11
 /**
12
- * Handler for UIEvents.LARGE_VIDEO_AVATAR_DISPLAYED event.
12
+ * Handler for UIEvents.LARGE_VIDEO_AVATAR_VISIBLE event.
13
  * @param {boolean} shown indicates whether the avatar on the large video is
13
  * @param {boolean} shown indicates whether the avatar on the large video is
14
  *  currently displayed or not.
14
  *  currently displayed or not.
15
  */
15
  */
112
         $(`#${this._containerId}`).remove();
112
         $(`#${this._containerId}`).remove();
113
     }
113
     }
114
 
114
 
115
+    /**
116
+     * Stops the ringing and clears related timers.
117
+     */
115
     _stopAudio() {
118
     _stopAudio() {
116
         if (this.interval) {
119
         if (this.interval) {
117
             clearInterval(this.interval);
120
             clearInterval(this.interval);
144
         }
147
         }
145
 
148
 
146
         overlay = new RingOverlay(callee, disableRingingSound);
149
         overlay = new RingOverlay(callee, disableRingingSound);
147
-        APP.UI.addListener(UIEvents.LARGE_VIDEO_AVATAR_DISPLAYED,
150
+        APP.UI.addListener(UIEvents.LARGE_VIDEO_AVATAR_VISIBLE,
148
             onAvatarDisplayed);
151
             onAvatarDisplayed);
149
     },
152
     },
150
 
153
 
158
         }
161
         }
159
         overlay.destroy();
162
         overlay.destroy();
160
         overlay = null;
163
         overlay = null;
161
-        APP.UI.removeListener(UIEvents.LARGE_VIDEO_AVATAR_DISPLAYED,
164
+        APP.UI.removeListener(UIEvents.LARGE_VIDEO_AVATAR_VISIBLE,
162
             onAvatarDisplayed);
165
             onAvatarDisplayed);
163
         return true;
166
         return true;
164
     },
167
     },

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

397
         this.$avatar.css("visibility", show ? "visible" : "hidden");
397
         this.$avatar.css("visibility", show ? "visible" : "hidden");
398
         this.avatarDisplayed = show;
398
         this.avatarDisplayed = show;
399
 
399
 
400
-        this.emitter.emit(UIEvents.LARGE_VIDEO_AVATAR_DISPLAYED, show);
400
+        this.emitter.emit(UIEvents.LARGE_VIDEO_AVATAR_VISIBLE, show);
401
     }
401
     }
402
 
402
 
403
     /**
403
     /**

+ 2
- 2
service/UI/UIEvents.js View File

118
     /**
118
     /**
119
      * Notifies that the avatar is displayed or not on the largeVideo.
119
      * Notifies that the avatar is displayed or not on the largeVideo.
120
      */
120
      */
121
-    LARGE_VIDEO_AVATAR_DISPLAYED: "UI.large_video_avatar_displayed",
122
-    
121
+    LARGE_VIDEO_AVATAR_VISIBLE: "UI.large_video_avatar_visible",
122
+
123
     /**
123
     /**
124
      * Toggling room lock
124
      * Toggling room lock
125
      */
125
      */

Loading…
Cancel
Save