Commit 3e75a989592693325da7c87c5a46982d731010ef
1 parent
bed99520
发版
Showing
11 changed files
with
95 additions
and
54 deletions
dist/css/ide.css
| @@ -187,6 +187,23 @@ html, body { | @@ -187,6 +187,23 @@ html, body { | ||
| 187 | #recordertab li:first-child { | 187 | #recordertab li:first-child { |
| 188 | border-right: 2px solid #FFF; } | 188 | border-right: 2px solid #FFF; } |
| 189 | 189 | ||
| 190 | +#recordertab > li:last-child { | ||
| 191 | + position: absolute; | ||
| 192 | + right: 20px; } | ||
| 193 | + #recordertab > li:last-child #quickTool { | ||
| 194 | + display: none; } | ||
| 195 | + #recordertab > li:last-child #quickTool button { | ||
| 196 | + background: transparent; | ||
| 197 | + color: #FFF; | ||
| 198 | + border: 1px solid #fff; | ||
| 199 | + border-radius: 24px; } | ||
| 200 | + #recordertab > li:last-child #quickTool .dropdown-menu { | ||
| 201 | + border-radius: 10px; } | ||
| 202 | + #recordertab > li:last-child #quickTool .dropdown-menu li a { | ||
| 203 | + color: #1FB6FF; } | ||
| 204 | + #recordertab > li:last-child #quickTool .dropdown-menu li a:hover { | ||
| 205 | + background-color: #62DCF5; } | ||
| 206 | + | ||
| 190 | .record-wrap { | 207 | .record-wrap { |
| 191 | width: 100%; | 208 | width: 100%; |
| 192 | height: 100%; | 209 | height: 100%; |
| @@ -467,28 +484,3 @@ html, body { | @@ -467,28 +484,3 @@ html, body { | ||
| 467 | 484 | ||
| 468 | #stderr, #cmpinfo, #output { | 485 | #stderr, #cmpinfo, #output { |
| 469 | padding: 12px 36px; } | 486 | padding: 12px 36px; } |
| 470 | - | ||
| 471 | - | ||
| 472 | -.nav-tabs>li:last-child{ | ||
| 473 | - position: absolute; | ||
| 474 | - right: 20px | ||
| 475 | - } | ||
| 476 | - #quickTool{ | ||
| 477 | - display: none; | ||
| 478 | - | ||
| 479 | - } | ||
| 480 | - #quickTool button{ | ||
| 481 | - background: transparent; | ||
| 482 | - color: #FFF; | ||
| 483 | - border: 1px solid #fff; | ||
| 484 | - border-radius: 24px; | ||
| 485 | - } | ||
| 486 | - .dropdown-menu{ | ||
| 487 | - border-radius: 10px; | ||
| 488 | - } | ||
| 489 | - .dropdown-menu>li>a{ | ||
| 490 | - color: #1FB6FF; | ||
| 491 | - } | ||
| 492 | - .dropdown-menu>li>a:hover{ | ||
| 493 | - background-color: #62DCF5; | ||
| 494 | - } |
dist/css/main.css
| @@ -59,6 +59,23 @@ html, body { | @@ -59,6 +59,23 @@ html, body { | ||
| 59 | #recordertab li:first-child { | 59 | #recordertab li:first-child { |
| 60 | border-right: 2px solid #FFF; } | 60 | border-right: 2px solid #FFF; } |
| 61 | 61 | ||
| 62 | +#recordertab > li:last-child { | ||
| 63 | + position: absolute; | ||
| 64 | + right: 20px; } | ||
| 65 | + #recordertab > li:last-child #quickTool { | ||
| 66 | + display: none; } | ||
| 67 | + #recordertab > li:last-child #quickTool button { | ||
| 68 | + background: transparent; | ||
| 69 | + color: #FFF; | ||
| 70 | + border: 1px solid #fff; | ||
| 71 | + border-radius: 24px; } | ||
| 72 | + #recordertab > li:last-child #quickTool .dropdown-menu { | ||
| 73 | + border-radius: 10px; } | ||
| 74 | + #recordertab > li:last-child #quickTool .dropdown-menu li a { | ||
| 75 | + color: #1FB6FF; } | ||
| 76 | + #recordertab > li:last-child #quickTool .dropdown-menu li a:hover { | ||
| 77 | + background-color: #62DCF5; } | ||
| 78 | + | ||
| 62 | .record-wrap { | 79 | .record-wrap { |
| 63 | width: 100%; | 80 | width: 100%; |
| 64 | height: 100%; | 81 | height: 100%; |
dist/gxb-ide/Dir.js
| @@ -76,10 +76,10 @@ | @@ -76,10 +76,10 @@ | ||
| 76 | dataType: "json", | 76 | dataType: "json", |
| 77 | contentType: "application/json", | 77 | contentType: "application/json", |
| 78 | success: function(res) { | 78 | success: function(res) { |
| 79 | - console.log(res); | 79 | + console.log(res); //目录包含文件 |
| 80 | console.log(_lang); | 80 | console.log(_lang); |
| 81 | $("title").html(_lang); | 81 | $("title").html(_lang); |
| 82 | - Dir.treeData = res[_lang]; | 82 | + Dir.treeData = res[_lang]; |
| 83 | Dir.treeObj = $.fn.zTree.init($(el), setting, Dir.treeData); | 83 | Dir.treeObj = $.fn.zTree.init($(el), setting, Dir.treeData); |
| 84 | addTextareaPage(Dir.treeData); | 84 | addTextareaPage(Dir.treeData); |
| 85 | CodingEditer.initCodeMirror(treeLinkEditor); | 85 | CodingEditer.initCodeMirror(treeLinkEditor); |
| @@ -145,11 +145,18 @@ | @@ -145,11 +145,18 @@ | ||
| 145 | console.log('////---------------------------') | 145 | console.log('////---------------------------') |
| 146 | console.log(treeLinkEditor); | 146 | console.log(treeLinkEditor); |
| 147 | for (var i = 0; i < treeLinkEditor.length; i++) { | 147 | for (var i = 0; i < treeLinkEditor.length; i++) { |
| 148 | + console.log(_this.manageName(obj.treeNode.name)); | ||
| 149 | + if (_this.manageName(obj.treeNode.name) !== 'index') { | ||
| 150 | + $('#quickTool').hide(); | ||
| 151 | + }else{ | ||
| 152 | + $('#quickTool').show(); | ||
| 153 | + } | ||
| 148 | if(treeLinkEditor[i].name == _this.manageName(obj.treeNode.name)){ | 154 | if(treeLinkEditor[i].name == _this.manageName(obj.treeNode.name)){ |
| 149 | - console.log(_this.manageName(obj.treeNode.name)); | ||
| 150 | $('.fileName').html(treeLinkEditor[i].filePath) | 155 | $('.fileName').html(treeLinkEditor[i].filePath) |
| 151 | _num = i; | 156 | _num = i; |
| 152 | } | 157 | } |
| 158 | + | ||
| 159 | + | ||
| 153 | } | 160 | } |
| 154 | // if(typeof obj.record != 'undefined' && obj.record){ | 161 | // if(typeof obj.record != 'undefined' && obj.record){ |
| 155 | // $('#recordertab a:eq(0)').tab('show'); | 162 | // $('#recordertab a:eq(0)').tab('show'); |
dist/gxb-ide/Iterm.js
| @@ -109,6 +109,7 @@ | @@ -109,6 +109,7 @@ | ||
| 109 | recodingConf() | 109 | recodingConf() |
| 110 | }, | 110 | }, |
| 111 | fullScreen: function(){ | 111 | fullScreen: function(){ |
| 112 | + | ||
| 112 | launchFullScreen(document.body); | 113 | launchFullScreen(document.body); |
| 113 | $('#back-screen').show(); | 114 | $('#back-screen').show(); |
| 114 | $('#full-screen').hide(); | 115 | $('#full-screen').hide(); |
| @@ -223,6 +224,7 @@ | @@ -223,6 +224,7 @@ | ||
| 223 | 224 | ||
| 224 | // 找到支持的方法, 使用需要全屏的 element 调用 | 225 | // 找到支持的方法, 使用需要全屏的 element 调用 |
| 225 | function launchFullScreen(element) { | 226 | function launchFullScreen(element) { |
| 227 | + | ||
| 226 | if (element.requestFullscreen) { | 228 | if (element.requestFullscreen) { |
| 227 | element.requestFullscreen(); | 229 | element.requestFullscreen(); |
| 228 | } else if (element.mozRequestFullScreen) { | 230 | } else if (element.mozRequestFullScreen) { |
| @@ -232,6 +234,8 @@ | @@ -232,6 +234,8 @@ | ||
| 232 | } else if (element.msRequestFullscreen) { | 234 | } else if (element.msRequestFullscreen) { |
| 233 | element.msRequestFullscreen(); | 235 | element.msRequestFullscreen(); |
| 234 | } | 236 | } |
| 237 | + | ||
| 238 | + | ||
| 235 | } | 239 | } |
| 236 | function exitFullscreen() { | 240 | function exitFullscreen() { |
| 237 | if (document.exitFullscreen) { | 241 | if (document.exitFullscreen) { |
dist/index.html
| @@ -89,20 +89,6 @@ | @@ -89,20 +89,6 @@ | ||
| 89 | <li> | 89 | <li> |
| 90 | <a href="#replayzone" data-toggle="tab"><i class="icon iconfont icon-yulan"></i><p class="pull-right"> 课程预览区</p></a> | 90 | <a href="#replayzone" data-toggle="tab"><i class="icon iconfont icon-yulan"></i><p class="pull-right"> 课程预览区</p></a> |
| 91 | </li> | 91 | </li> |
| 92 | - <li> | ||
| 93 | - <div class="btn-group" id="quickTool"> | ||
| 94 | - <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> | ||
| 95 | - <span id="text">快速引入文件</span> | ||
| 96 | - <span class="caret"></span> | ||
| 97 | - </button> | ||
| 98 | - <ul class="dropdown-menu"> | ||
| 99 | - <li><a href="#">图片</a></li> | ||
| 100 | - <li><a href="#">bootstrap.css</a></li> | ||
| 101 | - <li><a href="#">bootstrap.js</a></li> | ||
| 102 | - <li><a href="#">jQuery</a></li> | ||
| 103 | - </ul> | ||
| 104 | - </div> | ||
| 105 | - </li> | ||
| 106 | </ul> | 92 | </ul> |
| 107 | <div id="editorwrapper"> | 93 | <div id="editorwrapper"> |
| 108 | <button type="button" class="lang btn btn-default btn-primary pull-right" id="htmlbutton" title="" data-editorname="html"></button> | 94 | <button type="button" class="lang btn btn-default btn-primary pull-right" id="htmlbutton" title="" data-editorname="html"></button> |
dist/js/c.js
| @@ -35,7 +35,6 @@ $(function(){ | @@ -35,7 +35,6 @@ $(function(){ | ||
| 35 | }) | 35 | }) |
| 36 | 36 | ||
| 37 | 37 | ||
| 38 | - | ||
| 39 | // new一个老师录制的控制条工具 | 38 | // new一个老师录制的控制条工具 |
| 40 | var techTool = new ToolBox({ | 39 | var techTool = new ToolBox({ |
| 41 | el: '#toolBox', | 40 | el: '#toolBox', |
| @@ -79,27 +78,26 @@ $(function(){ | @@ -79,27 +78,26 @@ $(function(){ | ||
| 79 | $('#studentCompileBtn').show(); | 78 | $('#studentCompileBtn').show(); |
| 80 | } | 79 | } |
| 81 | 80 | ||
| 82 | - $('.dropdown-menu').on('click', function(e) { | 81 | + $('.dropdown-menu').on('click', function(e) { |
| 83 | var $target = $(e.target); | 82 | var $target = $(e.target); |
| 84 | $target.is('li') && $('#text').text($target.text()); | 83 | $target.is('li') && $('#text').text($target.text()); |
| 85 | 84 | ||
| 86 | var selectVal = $target.text(); | 85 | var selectVal = $target.text(); |
| 87 | 86 | ||
| 88 | if (selectVal == '图片') { | 87 | if (selectVal == '图片') { |
| 89 | - Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<img src="http://www.igeekbar.com/igeekbar/laitu/300x200&text=hello world/222222/ffffff" alt="占位图片">', "end") | 88 | + Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<img src="//www.igeekbar.com/igeekbar/laitu/300x200&text=hello world/222222/ffffff" alt="占位图片">', "end") |
| 90 | }else if (selectVal == 'bootstrap.css') { | 89 | }else if (selectVal == 'bootstrap.css') { |
| 91 | - Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<link href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">', "end") | 90 | + Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<link href="//cdn.gbtags.com/bootswatch/3.2.0+1/custom/bootstrap.min.css" rel="stylesheet">', "end") |
| 92 | }else if(selectVal == 'bootstrap.js'){ | 91 | }else if(selectVal == 'bootstrap.js'){ |
| 93 | - Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<script src="https://cdn.bootcss.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>', "end") | 92 | + Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<script src="//cdn.gbtags.com/twitter-bootstrap/3.2.0/js/bootstrap.min.js"></script>', "end") |
| 94 | }else if (selectVal == 'jQuery') { | 93 | }else if (selectVal == 'jQuery') { |
| 95 | - Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>', "end") | 94 | + Dir.treeLinkEditor[0].CodeMirrorRecord.replaceSelection('<script src="//cdn.gbtags.com/jquery/2.1.1/jquery.min.js"></script>', "end") |
| 96 | } | 95 | } |
| 97 | 96 | ||
| 98 | }) | 97 | }) |
| 99 | 98 | ||
| 100 | 99 | ||
| 101 | 100 | ||
| 102 | - | ||
| 103 | // 插入标准输入 | 101 | // 插入标准输入 |
| 104 | $(document).on('focus', '#runtimeArgus', function(){ | 102 | $(document).on('focus', '#runtimeArgus', function(){ |
| 105 | console.log('focus'); | 103 | console.log('focus'); |
dist/js/codedata.json
| @@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
| 14 | "viewcount": "0", | 14 | "viewcount": "0", |
| 15 | "saveformat": "5", | 15 | "saveformat": "5", |
| 16 | "deleteFlag": "1", | 16 | "deleteFlag": "1", |
| 17 | - "audioUrl": "https://gxb-file.gaoxiaobang.com/uploads/programming_audio/link/17/02/7/56f25406ecb34735b1ed80d41a64a68b", | 17 | + "audioUrl": "https://gxb-file.gaoxiaobang.comuploads/programming_audio/link/17/02/7/56f25406ecb34735b1ed80d41a64a68b", |
| 18 | "classId": null, | 18 | "classId": null, |
| 19 | "totaltime": "0", | 19 | "totaltime": "0", |
| 20 | "itemId": null, | 20 | "itemId": null, |
dist/js/util/util.js
| @@ -41,7 +41,7 @@ getCDNFile = function (cdnUrl) { | @@ -41,7 +41,7 @@ getCDNFile = function (cdnUrl) { | ||
| 41 | $w.utils = $w.utils || utils; | 41 | $w.utils = $w.utils || utils; |
| 42 | })(window, jQuery) | 42 | })(window, jQuery) |
| 43 | 43 | ||
| 44 | -window.console.log = function(){} | 44 | +// window.console.log = function(){} |
| 45 | window.console.info = function(){} | 45 | window.console.info = function(){} |
| 46 | 46 | ||
| 47 | 47 |
dist/scss/main.scss
| @@ -68,6 +68,35 @@ html, body{ | @@ -68,6 +68,35 @@ html, body{ | ||
| 68 | border-right: 2px solid #FFF; | 68 | border-right: 2px solid #FFF; |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | +#recordertab>li:last-child{ | ||
| 72 | + position: absolute; | ||
| 73 | + right: 20px; | ||
| 74 | + | ||
| 75 | + #quickTool{ | ||
| 76 | + display: none; | ||
| 77 | + | ||
| 78 | + button{ | ||
| 79 | + background: transparent; | ||
| 80 | + color: #FFF; | ||
| 81 | + border: 1px solid #fff; | ||
| 82 | + border-radius: 24px; | ||
| 83 | + } | ||
| 84 | + | ||
| 85 | + .dropdown-menu{ | ||
| 86 | + border-radius: 10px; | ||
| 87 | + | ||
| 88 | + li{ | ||
| 89 | + a{ | ||
| 90 | + color: #1FB6FF; | ||
| 91 | + &:hover{ | ||
| 92 | + background-color: #62DCF5; | ||
| 93 | + } | ||
| 94 | + } | ||
| 95 | + | ||
| 96 | + } | ||
| 97 | + } | ||
| 98 | + } | ||
| 99 | +} | ||
| 71 | 100 | ||
| 72 | // 录制区 | 101 | // 录制区 |
| 73 | .record-wrap{ | 102 | .record-wrap{ |
| @@ -437,3 +466,5 @@ html, body{ | @@ -437,3 +466,5 @@ html, body{ | ||
| 437 | } | 466 | } |
| 438 | 467 | ||
| 439 | 468 | ||
| 469 | + | ||
| 470 | + |
dist/v1.1/index.html
| @@ -48,8 +48,10 @@ | @@ -48,8 +48,10 @@ | ||
| 48 | vertical-align: middle; | 48 | vertical-align: middle; |
| 49 | padding-right: 2px; | 49 | padding-right: 2px; |
| 50 | } | 50 | } |
| 51 | - | ||
| 52 | - | 51 | + :-webkit-full-screen{ |
| 52 | + width: 100%; | ||
| 53 | + height: 100% | ||
| 54 | + } | ||
| 53 | </style> | 55 | </style> |
| 54 | 56 | ||
| 55 | 57 | ||
| @@ -80,6 +82,7 @@ | @@ -80,6 +82,7 @@ | ||
| 80 | <li><a href="#">bootstrap.css</a></li> | 82 | <li><a href="#">bootstrap.css</a></li> |
| 81 | <li><a href="#">bootstrap.js</a></li> | 83 | <li><a href="#">bootstrap.js</a></li> |
| 82 | <li><a href="#">jQuery</a></li> | 84 | <li><a href="#">jQuery</a></li> |
| 85 | + | ||
| 83 | </ul> | 86 | </ul> |
| 84 | </div> | 87 | </div> |
| 85 | </li> | 88 | </li> |
| @@ -103,7 +106,7 @@ | @@ -103,7 +106,7 @@ | ||
| 103 | <!-- 运行结果区 --> | 106 | <!-- 运行结果区 --> |
| 104 | <div class="console-wrap" id="console-wrap"> | 107 | <div class="console-wrap" id="console-wrap"> |
| 105 | <div class="CodeMirror-gutter"> | 108 | <div class="CodeMirror-gutter"> |
| 106 | - </div> | 109 | + </div> |
| 107 | <div id="toolbar"> | 110 | <div id="toolbar"> |
| 108 | <!-- Nav tabs --> | 111 | <!-- Nav tabs --> |
| 109 | <ul class="nav nav-tabs result-tabs need-compile" role="tablist" id="cmprun-tabs"> | 112 | <ul class="nav nav-tabs result-tabs need-compile" role="tablist" id="cmprun-tabs"> |
| @@ -142,9 +145,11 @@ | @@ -142,9 +145,11 @@ | ||
| 142 | <div class="tab-pane padall15" id="stderr"></div> | 145 | <div class="tab-pane padall15" id="stderr"></div> |
| 143 | <div class="tab-pane padall15" id="output"></div> | 146 | <div class="tab-pane padall15" id="output"></div> |
| 144 | </div> | 147 | </div> |
| 148 | + | ||
| 145 | <div class="panel-body no-compile" id="ifrcontainer" > | 149 | <div class="panel-body no-compile" id="ifrcontainer" > |
| 146 | <iframe id="resultiframe" frameBorder="0" width="100%" allowfullscreen></iframe> | 150 | <iframe id="resultiframe" frameBorder="0" width="100%" allowfullscreen></iframe> |
| 147 | </div> | 151 | </div> |
| 152 | + | ||
| 148 | </div> | 153 | </div> |
| 149 | </div> | 154 | </div> |
| 150 | <div class="pause-shodow" style="display: none;"> | 155 | <div class="pause-shodow" style="display: none;"> |
dist/v1.1/player.html
| @@ -24,6 +24,7 @@ | @@ -24,6 +24,7 @@ | ||
| 24 | 24 | ||
| 25 | <script> | 25 | <script> |
| 26 | var gxb_api = "https://restful.gaoxiaobang.com"; | 26 | var gxb_api = "https://restful.gaoxiaobang.com"; |
| 27 | + var vedio_url = "https://gxb-file.gaoxiaobang.com" | ||
| 27 | // var gxb_api = "http://192.168.80.223:8080" | 28 | // var gxb_api = "http://192.168.80.223:8080" |
| 28 | </script> | 29 | </script> |
| 29 | 30 |