Browse Source

Improves the pin and hover borders

j8
yanas 8 years ago
parent
commit
1c8535a2d5

+ 0
- 5
css/_base.scss View File

85
     background-color: #00ccff;
85
     background-color: #00ccff;
86
 }
86
 }
87
 
87
 
88
-.glow
89
-{
90
-    text-shadow: 0px 0px 30px #06a5df, 0px 0px 10px #06a5df, 0px 0px 5px #06a5df,0px 0px 3px #06a5df;
91
-}
92
-
93
 .watermark {
88
 .watermark {
94
     display: block;
89
     display: block;
95
     position: absolute;
90
     position: absolute;

+ 5
- 0
css/_toolbars.scss View File

110
     cursor: default;
110
     cursor: default;
111
 }
111
 }
112
 
112
 
113
+.button.glow
114
+{
115
+    text-shadow: 0px 0px 5px $toolbarToggleBackground;
116
+}
117
+
113
 a.button.unclickable:hover,
118
 a.button.unclickable:hover,
114
 a.button.unclickable:active,
119
 a.button.unclickable:active,
115
 a.button.unclickable.selected{
120
 a.button.unclickable.selected{

+ 2
- 1
css/_variables.scss View File

30
 
30
 
31
 $toolbarBadgeBackground: #165ECC;
31
 $toolbarBadgeBackground: #165ECC;
32
 $toolbarBadgeColor: #FFFFFF;
32
 $toolbarBadgeColor: #FFFFFF;
33
+$toolbarToggleBackground: #165ECC;
33
 
34
 
34
 // Main controls
35
 // Main controls
35
 $inputBackground: rgba(132, 132, 132, .5);
36
 $inputBackground: rgba(132, 132, 132, .5);
39
 $buttonBackground: #44A5FF;
40
 $buttonBackground: #44A5FF;
40
 
41
 
41
 // Video layout.
42
 // Video layout.
42
-$videoThumbnailHovered: #44A5FF;
43
+$videoThumbnailHovered: #BFEBFF;
43
 $videoThumbnailSelected: #165ECC;
44
 $videoThumbnailSelected: #165ECC;
44
 $participantNameColor: #fff;
45
 $participantNameColor: #fff;
45
 $thumbnailPictogramColor: #fff;
46
 $thumbnailPictogramColor: #fff;

+ 19
- 7
css/_videolayout_default.scss View File

25
     left: 0;
25
     left: 0;
26
     right: 0;
26
     right: 0;
27
     width:auto;
27
     width:auto;
28
-    border:1px solid transparent;
28
+    border: 2px solid transparent;
29
     z-index: 5;
29
     z-index: 5;
30
     transition: bottom 2s;
30
     transition: bottom 2s;
31
     overflow: visible !important;
31
     overflow: visible !important;
48
     background-size: contain;
48
     background-size: contain;
49
     border-radius:1px;
49
     border-radius:1px;
50
     margin: 0 $thumbnailVideoMargin;
50
     margin: 0 $thumbnailVideoMargin;
51
-    border: 1px solid $defaultDarkColor;
52
 }
51
 }
53
 
52
 
54
 /**
53
 /**
67
     padding: 0 5px 0 5px;
66
     padding: 0 5px 0 5px;
68
 }
67
 }
69
 
68
 
69
+#remoteVideos .videocontainer.videoContainerFocused,
70
+#remoteVideos .videocontainer:hover {
71
+    cursor: hand;
72
+    margin-right: $thumbnailVideoMargin - 2;
73
+    margin-left: $thumbnailVideoMargin - 2;
74
+    margin-top: -2px;
75
+}
70
 /**
76
 /**
71
  * Focused video thumbnail.
77
  * Focused video thumbnail.
72
  */
78
  */
73
 #remoteVideos .videocontainer.videoContainerFocused {
79
 #remoteVideos .videocontainer.videoContainerFocused {
74
-    cursor: hand;
75
     transition-duration: 0.5s;
80
     transition-duration: 0.5s;
76
     -webkit-transition-duration: 0.5s;
81
     -webkit-transition-duration: 0.5s;
77
     -webkit-animation-name: greyPulse;
82
     -webkit-animation-name: greyPulse;
78
     -webkit-animation-duration: 2s;
83
     -webkit-animation-duration: 2s;
79
     -webkit-animation-iteration-count: 1;
84
     -webkit-animation-iteration-count: 1;
80
-    border: 1px solid $videoThumbnailSelected;
85
+    border: 2px solid $videoThumbnailSelected !important;
86
+    box-shadow: inset 0 0 3px $videoThumbnailSelected,
87
+                0 0 3px $videoThumbnailSelected !important;
81
 }
88
 }
82
 
89
 
83
-#remoteVideos .videocontainer:hover,
84
-#remoteVideos .videocontainer.videoContainerFocused:hover {
85
-    border: 1px solid $videoThumbnailHovered;
90
+/**
91
+ * Hovered video thumbnail.
92
+ */
93
+#remoteVideos .videocontainer:hover {
94
+    cursor: hand;
95
+    border: 2px solid $videoThumbnailHovered;
96
+    box-shadow: inset 0 0 3px $videoThumbnailHovered,
97
+              0 0 3px $videoThumbnailHovered;
86
 }
98
 }
87
 
99
 
88
 #localVideoWrapper {
100
 #localVideoWrapper {

+ 11
- 24
modules/UI/audio_levels/AudioLevels.js View File

147
      * Updates the audio level canvas for the given id. If the canvas
147
      * Updates the audio level canvas for the given id. If the canvas
148
      * didn't exist we create it.
148
      * didn't exist we create it.
149
      */
149
      */
150
-    createAudioLevelCanvas (id, thumbWidth, thumbHeight) {
151
-
152
-        let videoSpanId = (id === "local")
153
-                        ? "localVideoContainer"
154
-                        : `participant_${id}`;
150
+    createAudioLevelCanvas (videoSpanId, thumbWidth, thumbHeight) {
155
 
151
 
156
         let videoSpan = document.getElementById(videoSpanId);
152
         let videoSpan = document.getElementById(videoSpanId);
157
 
153
 
158
         if (!videoSpan) {
154
         if (!videoSpan) {
159
-            if (id) {
160
-                console.error("No video element for id", id);
155
+            if (videoSpanId) {
156
+                console.error("No video element for id", videoSpanId);
161
             } else {
157
             } else {
162
                 console.error("No video element for local video.");
158
                 console.error("No video element for local video.");
163
             }
159
             }
245
     },
241
     },
246
 
242
 
247
     updateCanvasSize (localVideo, remoteVideo) {
243
     updateCanvasSize (localVideo, remoteVideo) {
248
-        let localCanvasWidth
249
-            = localVideo.thumbWidth + interfaceConfig.CANVAS_EXTRA;
250
-        let localCanvasHeight
251
-            = localVideo.thumbHeight + interfaceConfig.CANVAS_EXTRA;
252
-        let remoteCanvasWidth
253
-            = remoteVideo.thumbWidth + interfaceConfig.CANVAS_EXTRA;
254
-        let remoteCanvasHeight
255
-            = remoteVideo.thumbHeight + interfaceConfig.CANVAS_EXTRA;
256
-
257
         let { remoteThumbs, localThumb } = FilmStrip.getThumbs();
244
         let { remoteThumbs, localThumb } = FilmStrip.getThumbs();
258
 
245
 
259
-        remoteThumbs.children('canvas').each(function () {
260
-            $(this).attr('width', remoteCanvasWidth);
261
-            $(this).attr('height', remoteCanvasHeight);
246
+        remoteThumbs.each(( index, element ) => {
247
+            this.createAudioLevelCanvas(element.id,
248
+                                        remoteVideo.thumbWidth,
249
+                                        remoteVideo.thumbHeight);
262
         });
250
         });
263
 
251
 
264
-        if(localThumb) {
265
-            localThumb.children('canvas').each(function () {
266
-                $(this).attr('width', localCanvasWidth);
267
-                $(this).attr('height', localCanvasHeight);
268
-            });
252
+        if (localThumb) {
253
+            this.createAudioLevelCanvas(localThumb.get(0).id,
254
+                                        localVideo.thumbWidth,
255
+                                        localVideo.thumbHeight);
269
         }
256
         }
270
     }
257
     }
271
 };
258
 };

+ 3
- 2
modules/UI/videolayout/RemoteVideo.js View File

33
         this.addRemoteVideoMenu();
33
         this.addRemoteVideoMenu();
34
     }
34
     }
35
 
35
 
36
-    let { remoteVideo } = this.VideoLayout.resizeThumbnails();
36
+    let { remoteVideo } = this.VideoLayout.resizeThumbnails(false, true);
37
     let { thumbHeight, thumbWidth } = remoteVideo;
37
     let { thumbHeight, thumbWidth } = remoteVideo;
38
-    AudioLevels.createAudioLevelCanvas(this.id, thumbWidth, thumbHeight);
38
+    AudioLevels.createAudioLevelCanvas(
39
+        this.videoSpanId, thumbWidth, thumbHeight);
39
 
40
 
40
     return this.container;
41
     return this.container;
41
 };
42
 };

+ 3
- 1
modules/UI/videolayout/VideoLayout.js View File

109
         // the local video thumb maybe one pixel
109
         // the local video thumb maybe one pixel
110
         let { localVideo } = this.resizeThumbnails(false, true);
110
         let { localVideo } = this.resizeThumbnails(false, true);
111
         AudioLevels.createAudioLevelCanvas(
111
         AudioLevels.createAudioLevelCanvas(
112
-            "local", localVideo.thumbWidth, localVideo.thumbHeight);
112
+            "localVideoContainer",
113
+            localVideo.thumbWidth,
114
+            localVideo.thumbHeight);
113
 
115
 
114
         emitter.addListener(UIEvents.CONTACT_CLICKED, onContactClicked);
116
         emitter.addListener(UIEvents.CONTACT_CLICKED, onContactClicked);
115
         this.lastNCount = config.channelLastN;
117
         this.lastNCount = config.channelLastN;

Loading…
Cancel
Save