Commit 0d3090b24b71acd0ae65c7a7a462d398e669e150

Authored by ykxie
2 parents b10a772d 6c38411c

merged fix fullscreen

src/css/main.css
1 1
2 .real-program-content{ 2 .real-program-content{
3 padding: 0 16px; 3 padding: 0 16px;
4 - padding-top: 16px;  
5 } 4 }
6 .recording{ 5 .recording{
7 background-color: #FFF; 6 background-color: #FFF;
src/css/recording.css
@@ -31,10 +31,12 @@ button { @@ -31,10 +31,12 @@ button {
31 31
32 .player .col-md-8 { 32 .player .col-md-8 {
33 padding-right: 0; 33 padding-right: 0;
34 - overflow: hidden; } 34 + overflow: hidden;
  35 + padding-left: 0; }
35 36
36 .player .col-md-4 { 37 .player .col-md-4 {
37 - padding-left: 0; } 38 + padding-left: 0;
  39 + padding-right: 0; }
38 40
39 .upload-tip { 41 .upload-tip {
40 position: absolute; 42 position: absolute;
src/index.html
@@ -16,7 +16,7 @@ @@ -16,7 +16,7 @@
16 <link href="css/recording.css" rel="stylesheet"> 16 <link href="css/recording.css" rel="stylesheet">
17 17
18 <script> 18 <script>
19 - var gxb_api = "https://restful1.gaoxiaobang.com"; 19 + var gxb_api = "https://restful.gaoxiaobang.com";
20 // var gxb_api = "https://restful.gaoxiaobang.cn" 20 // var gxb_api = "https://restful.gaoxiaobang.cn"
21 21
22 </script> 22 </script>
@@ -55,21 +55,6 @@ @@ -55,21 +55,6 @@
55 55
56 </head> 56 </head>
57 <body> 57 <body>
58 -<!-- <div class="real-program-title">  
59 - <div class="back">  
60 - <i class="gxbrecording record-back" style="color: #1FB6FF"> 返回课程</i>  
61 - <span>| 我的课程</span>  
62 - </div>  
63 - <div class="save-wrap">  
64 - <div class="upload-tip" style="display: none;">  
65 - <img src="img/upload_tip.png" alt="">  
66 - </div>  
67 - <input type="button" id="upload" class="upload-teach" style="display: ;" disabled="disabled" value="保存">  
68 - <input type="button" id="savecorde" class="upload-stud" style="display: none;" disabled="disabled" value="保存">  
69 - <input type="button" id="cancel" value="关闭">  
70 - </div>  
71 - </div> -->  
72 -  
73 <div class="real-program-content recording-page"> 58 <div class="real-program-content recording-page">
74 <div class="row"> 59 <div class="row">
75 <div class="col-md-8" id="editorpanel"> 60 <div class="col-md-8" id="editorpanel">
@@ -137,7 +122,7 @@ @@ -137,7 +122,7 @@
137 <div class="btn-group pull-right" id="comprunbtngrp"></div> 122 <div class="btn-group pull-right" id="comprunbtngrp"></div>
138 </div> 123 </div>
139 <div class="panel-body hidden" id="cmprun-output"> 124 <div class="panel-body hidden" id="cmprun-output">
140 - <div id="resultoutput" style="overflow:auto;"> 125 + <div id="resultoutput">
141 <!-- Nav tabs --> 126 <!-- Nav tabs -->
142 <ul class="nav nav-tabs" role="tablist" id="cmprun-tabs"> 127 <ul class="nav nav-tabs" role="tablist" id="cmprun-tabs">
143 <li class="active"><a href="#stdin" role="tab" data-toggle="tab" class="text-warning">标准输入</a></li> 128 <li class="active"><a href="#stdin" role="tab" data-toggle="tab" class="text-warning">标准输入</a></li>
@@ -182,17 +167,6 @@ @@ -182,17 +167,6 @@
182 </div> 167 </div>
183 </div> 168 </div>
184 169
185 -<!-- <div class="recording-audio recording">  
186 - <button class="audio-finish" type="button" data="1" title="正在录音">  
187 - <span class="stop"></span>  
188 - </button>  
189 - <button class="audio-play" title="正在录音" disable="false"></button>  
190 - <div class="f1 audio-wrap" style="line-height: 60px;">  
191 - <audio id="audio" autoplay></audio>  
192 - </div>  
193 - <div class="recording-time" value=""></div>  
194 - </div> -->  
195 -  
196 <div class="upload-tip" style="display: none;"> 170 <div class="upload-tip" style="display: none;">
197 <img src="img/upload_tip.png" alt=""> 171 <img src="img/upload_tip.png" alt="">
198 </div> 172 </div>
src/js/gbreplayer.js
@@ -471,7 +471,6 @@ $(function(){ @@ -471,7 +471,6 @@ $(function(){
471 if(document.URL.indexOf('player.html')>=0){ 471 if(document.URL.indexOf('player.html')>=0){
472 if(playstatus){ 472 if(playstatus){
473 GBCodePlayBack.pauseData = new Date().getTime(); // 暂停的时间 473 GBCodePlayBack.pauseData = new Date().getTime(); // 暂停的时间
474 - console.log(GBCodePlayBack.pauseData)  
475 myAudio[0].pause(); 474 myAudio[0].pause();
476 $('#play').find('i').removeClass('icon-playcopy').addClass('icon-play').attr('data-original-title', '播放'); 475 $('#play').find('i').removeClass('icon-playcopy').addClass('icon-play').attr('data-original-title', '播放');
477 }else{ 476 }else{
@@ -500,32 +499,21 @@ $(function(){ @@ -500,32 +499,21 @@ $(function(){
500 if (tag === 1) { 499 if (tag === 1) {
501 GBCodePlayBack.stopIntervalTime = playbackrecord[0].intervaltime - (GBCodePlayBack.pauseData - GBCodePlayBack.playRecordStart); 500 GBCodePlayBack.stopIntervalTime = playbackrecord[0].intervaltime - (GBCodePlayBack.pauseData - GBCodePlayBack.playRecordStart);
502 starttime = GBCodePlayBack.stopIntervalTime 501 starttime = GBCodePlayBack.stopIntervalTime
503 - console.log(starttime)  
504 tag++; 502 tag++;
505 }else{ 503 }else{
506 GBCodePlayBack.stopIntervalTime = GBCodePlayBack.stopIntervalTime - (GBCodePlayBack.pauseData - GBCodePlayBack.playRecordStart); 504 GBCodePlayBack.stopIntervalTime = GBCodePlayBack.stopIntervalTime - (GBCodePlayBack.pauseData - GBCodePlayBack.playRecordStart);
507 starttime = GBCodePlayBack.stopIntervalTime; 505 starttime = GBCodePlayBack.stopIntervalTime;
508 - console.log('------------------------------')  
509 - console.log(tag)  
510 - console.log(starttime)  
511 - console.log('------------------------------')  
512 } 506 }
513 - console.log(starttime)  
514 } 507 }
515 508
516 - console.log(starttime)  
517 509
518 }else{ 510 }else{
519 starttime = parseInt(starttime) + parseInt(replayinterval); 511 starttime = parseInt(starttime) + parseInt(replayinterval);
520 512
521 if (GBCodePlayBack.pauseData && GBCodePlayBack.pauseData - playbackrecord[i-1].playTime > 0) { 513 if (GBCodePlayBack.pauseData && GBCodePlayBack.pauseData - playbackrecord[i-1].playTime > 0) {
522 - console.log('+++++++++++++++++++++++++++++++++++++++')  
523 GBCodePlayBack.stopIntervalTime = GBCodePlayBack.pauseData - playbackrecord[i-1].playTime; 514 GBCodePlayBack.stopIntervalTime = GBCodePlayBack.pauseData - playbackrecord[i-1].playTime;
524 starttime = GBCodePlayBack.stopIntervalTime + parseInt(replayinterval); 515 starttime = GBCodePlayBack.stopIntervalTime + parseInt(replayinterval);
525 - console.log(starttime)  
526 } 516 }
527 -  
528 - console.log(starttime)  
529 } 517 }
530 518
531 timeoutcontroller = setTimeout( GBCodePlayBack.changeValueCallback(playbackrecord[i]), starttime/GBCodePlayBack.speed ); 519 timeoutcontroller = setTimeout( GBCodePlayBack.changeValueCallback(playbackrecord[i]), starttime/GBCodePlayBack.speed );
@@ -538,7 +526,6 @@ $(function(){ @@ -538,7 +526,6 @@ $(function(){
538 } 526 }
539 // 记录播放的时间 527 // 记录播放的时间
540 GBCodePlayBack.playRecordStart = new Date().getTime(); 528 GBCodePlayBack.playRecordStart = new Date().getTime();
541 - console.log(GBCodePlayBack.playRecordStart);  
542 }else{ 529 }else{
543 var recordtimeoutcontrolls = GBCodePlayBack.recordtimeoutcontrolls; 530 var recordtimeoutcontrolls = GBCodePlayBack.recordtimeoutcontrolls;
544 531
@@ -548,8 +535,6 @@ $(function(){ @@ -548,8 +535,6 @@ $(function(){
548 535
549 GBCodePlayBack.recordtimeouts = []; 536 GBCodePlayBack.recordtimeouts = [];
550 // GBCodePlayBack.playRecordStart = new Date().getTime(); // 再次开始播放的时间 537 // GBCodePlayBack.playRecordStart = new Date().getTime(); // 再次开始播放的时间
551 -  
552 - console.log(GBCodePlayBack);  
553 } 538 }
554 $(this).data('status', !playstatus); 539 $(this).data('status', !playstatus);
555 }); 540 });
@@ -653,7 +638,6 @@ $(function(){ @@ -653,7 +638,6 @@ $(function(){
653 //播放代码回放 638 //播放代码回放
654 $('#playrecord').click(function(){ 639 $('#playrecord').click(function(){
655 // GBCodePlayBack.playRecordStart = new Date().getTime(); // 开始播放的时间 640 // GBCodePlayBack.playRecordStart = new Date().getTime(); // 开始播放的时间
656 - // console.log(GBCodePlayBack.playRecordStart);  
657 if($(window).width()>992){ 641 if($(window).width()>992){
658 var $tutorial = $('#tutorialinfopanel'), 642 var $tutorial = $('#tutorialinfopanel'),
659 $editorpanel = $('#editorpanel'), 643 $editorpanel = $('#editorpanel'),
@@ -669,7 +653,7 @@ $(function(){ @@ -669,7 +653,7 @@ $(function(){
669 653
670 $sliderpropress.slider( "option", "disabled", false ); 654 $sliderpropress.slider( "option", "disabled", false );
671 655
672 - $(this).popover('destroy'); 656 + // $(this).popover('destroy');
673 657
674 $(this).find('span').toggleClass('glyphicon-cloud-download').toggleClass('glyphicon-play'); 658 $(this).find('span').toggleClass('glyphicon-cloud-download').toggleClass('glyphicon-play');
675 659
@@ -1027,7 +1011,6 @@ $(function(){ @@ -1027,7 +1011,6 @@ $(function(){
1027 dataType: "json", 1011 dataType: "json",
1028 contentType: "application/json", 1012 contentType: "application/json",
1029 success: function(data){ 1013 success: function(data){
1030 - console.log(data)  
1031 $(window).unbind('beforeunload'); 1014 $(window).unbind('beforeunload');
1032 var _data = { 1015 var _data = {
1033 "programId": data.codeReplayId, 1016 "programId": data.codeReplayId,
@@ -1055,7 +1038,6 @@ $(function(){ @@ -1055,7 +1038,6 @@ $(function(){
1055 dataType: "json", 1038 dataType: "json",
1056 contentType: "application/json", 1039 contentType: "application/json",
1057 success: function(data) { 1040 success: function(data) {
1058 - console.log(data)  
1059 $(window).unbind('beforeunload'); 1041 $(window).unbind('beforeunload');
1060 var _data = { 1042 var _data = {
1061 "programId": data.studentReplayId, 1043 "programId": data.studentReplayId,
@@ -1421,6 +1403,7 @@ $(function(){ @@ -1421,6 +1403,7 @@ $(function(){
1421 var calcHeight = function() { 1403 var calcHeight = function() {
1422 var $resultpanel = $("#resultpanel").offset(); 1404 var $resultpanel = $("#resultpanel").offset();
1423 var $recordpanel = $("#recordpanel").offset(); 1405 var $recordpanel = $("#recordpanel").offset();
  1406 + var $resultoutput = $('#resultoutput').offset();
1424 1407
1425 if (document.URL.indexOf('index.htm') >= 0) { 1408 if (document.URL.indexOf('index.htm') >= 0) {
1426 $("#recordpanel").height($(window).height() - $recordpanel.top - 16 - 70); 1409 $("#recordpanel").height($(window).height() - $recordpanel.top - 16 - 70);
@@ -1431,6 +1414,8 @@ $(function(){ @@ -1431,6 +1414,8 @@ $(function(){
1431 $("#resultpanel").height($(window).height() - $resultpanel.top - 16 - 34); 1414 $("#resultpanel").height($(window).height() - $resultpanel.top - 16 - 34);
1432 $(".CodeMirror").height($(window).height() - $recordpanel.top - 16 - 34); 1415 $(".CodeMirror").height($(window).height() - $recordpanel.top - 16 - 34);
1433 } 1416 }
  1417 + $('#resultoutput').find('.tab-content').height($(window).height() - $resultoutput.top - 164).css({'overflow-y': "scroll"})
  1418 +
1434 /*保证编辑器都尺寸自动变化(包括滚动条)*/ 1419 /*保证编辑器都尺寸自动变化(包括滚动条)*/
1435 if(typeof GBCodePlayBack.htmleditor !=='undefined'&&typeof GBCodePlayBack.csseditor!=='undefined'&&typeof GBCodePlayBack.jseditor!=='undefined'){ 1420 if(typeof GBCodePlayBack.htmleditor !=='undefined'&&typeof GBCodePlayBack.csseditor!=='undefined'&&typeof GBCodePlayBack.jseditor!=='undefined'){
1436 GBCodePlayBack.htmleditor.refresh(); 1421 GBCodePlayBack.htmleditor.refresh();
@@ -1443,7 +1428,7 @@ $(function(){ @@ -1443,7 +1428,7 @@ $(function(){
1443 // $('#editorwrapper').find('button').removeClass('btn-primary').find('#allbutton').addClass('btn-primary'); 1428 // $('#editorwrapper').find('button').removeClass('btn-primary').find('#allbutton').addClass('btn-primary');
1444 calcHeight(); 1429 calcHeight();
1445 //窗口变化则隐藏popover 1430 //窗口变化则隐藏popover
1446 - $('#playrecord').popover('hide'); 1431 + // $('#playrecord').popover('hide');
1447 }).load(function() { 1432 }).load(function() {
1448 calcHeight(); 1433 calcHeight();
1449 }); 1434 });
@@ -1489,7 +1474,6 @@ $(function(){ @@ -1489,7 +1474,6 @@ $(function(){
1489 1474
1490 record.trigger = 1; //标记已运行 1475 record.trigger = 1; //标记已运行
1491 record.playTime = new Date().getTime(); // 播放开始时间 1476 record.playTime = new Date().getTime(); // 播放开始时间
1492 - console.log(record)  
1493 1477
1494 if(replay_type){ 1478 if(replay_type){
1495 GBCodePlayBack.excercise_triggertotal += 1; 1479 GBCodePlayBack.excercise_triggertotal += 1;
src/player.html
@@ -15,7 +15,7 @@ @@ -15,7 +15,7 @@
15 <link href="css/recording.css" rel="stylesheet"> 15 <link href="css/recording.css" rel="stylesheet">
16 16
17 <script> 17 <script>
18 - var gxb_api = "https://restful1.gaoxiaobang.com"; 18 + var gxb_api = "https://restful.gaoxiaobang.com";
19 // var gxb_api = "https://restful.gaoxiaobang.com" 19 // var gxb_api = "https://restful.gaoxiaobang.com"
20 </script> 20 </script>
21 21
@@ -141,7 +141,7 @@ @@ -141,7 +141,7 @@
141 </div> 141 </div>
142 142
143 <div class="play-bar"> 143 <div class="play-bar">
144 - <button id="playrecord" data-status='0' title="播放"> 144 + <button id="playrecord" data-status='0' title="播adasdas放">
145 <i class="icon iconfont icon-play"></i> 145 <i class="icon iconfont icon-play"></i>
146 </button> 146 </button>
147 <button id="play" class="" style="display: none;" data-status='0' title="暂停"> 147 <button id="play" class="" style="display: none;" data-status='0' title="暂停">
src/scss/recording.scss
@@ -29,10 +29,12 @@ button{ @@ -29,10 +29,12 @@ button{
29 .player{ 29 .player{
30 .col-md-8{ 30 .col-md-8{
31 padding-right: 0; 31 padding-right: 0;
32 - overflow: hidden 32 + overflow: hidden;
  33 + padding-left: 0;
33 } 34 }
34 .col-md-4{ 35 .col-md-4{
35 padding-left: 0; 36 padding-left: 0;
  37 + padding-right: 0;
36 } 38 }
37 } 39 }
38 40