Index: lams_tool_whiteboard/web/pages/learning/learning.jsp =================================================================== diff -u -r85a2af65cb5f008ebb4f38b1431b7f9482330f4b -r9496ff3ffe5e98272f7939a2cf4e8c6dbb2901f7 --- lams_tool_whiteboard/web/pages/learning/learning.jsp (.../learning.jsp) (revision 85a2af65cb5f008ebb4f38b1431b7f9482330f4b) +++ lams_tool_whiteboard/web/pages/learning/learning.jsp (.../learning.jsp) (revision 9496ff3ffe5e98272f7939a2cf4e8c6dbb2901f7) @@ -11,243 +11,221 @@ - + - - - <%@ include file="/common/header.jsp"%> - - + #countdown { + width: 150px; + font-size: 110%; + font-style: italic; + color:#47bc23; + text-align: center; + } - - - - - - - + + + + + + - - <%@ include file="websocket.jsp"%> - - + function finishSession(){ + document.location.href =''; + } + function continueReflect(){ + document.location.href=''; + } + + function displayCountdown(secondsLeft){ + var countdown = ''; + + $.blockUI({ + message: countdown, + showOverlay: false, + focusInput: false, + css: { + top: '40px', + left: '', + right: '0%', + opacity: '1', + width: '150px', + cursor: 'default', + border: 'none' + } + }); + + $('#countdown').countdown({ + until: '+' + secondsLeft +'S', + format: 'hMS', + compact: true, + alwaysExpire : true, + onTick: function(periods) { + // check for 30 seconds or less and display timer in red + var secondsLeft = $.countdown.periodsToSeconds(periods); + if (secondsLeft <= 30) { + $(this).addClass('countdown-timeout'); + } else { + $(this).removeClass('countdown-timeout'); + } + }, + onExpiry: function(periods) { + if (isWebsocketClosed('whiteboardTimeLimit${sessionMap.toolContentID}')){ + console.error('Time limit websocket closed on time expire, reloading page'); + alert('Connection issue. The page will now reload.'); + document.location.reload(); + return; + } + $.blockUI({ message: '' }); + + setTimeout(function() { + location.reload(); + }, 4000); + }, + description: "" + }); + } + + function whiteboardFullScreenChanged() { + var fullscreenElement = document.fullscreenElement || document.mozFullScreenElement || document.webkitFullscreenElement; + $('.full-screen-content-div').toggleClass('fullscreen', fullscreenElement && fullscreenElement != null); + } + + + <%@ include file="websocket.jsp"%> + + + - + - + - + @@ -257,22 +235,22 @@ - + - + - - + - - - + + + + src='${whiteboardServerUrl}/?whiteboardid=${wid}&username=${whiteboardAuthorName}${empty whiteboardAccessToken ? "" : "&accesstoken=".concat(whiteboardAccessToken)}©fromwid=${sourceWid}${empty whiteboardCopyAccessToken ? "" : "©accesstoken=".concat(whiteboardCopyAccessToken)}'> @@ -290,23 +268,23 @@ - - - - - - - - - - - - + + + + + + + + + + + + - + @@ -318,7 +296,7 @@ - @@ -329,7 +307,7 @@ title="" - > + > @@ -344,16 +322,16 @@ + class="btn btn-primary voffset5 pull-right na"> - - - - - - - + + + + + + + @@ -362,11 +340,11 @@ - + - - + + \ No newline at end of file
- - - -
- -
+ + + +
+ +