Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
东方怂天
cxmooc-tools
提交
cf443fa7
C
cxmooc-tools
项目概览
东方怂天
/
cxmooc-tools
通知
11
Star
1
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
C
cxmooc-tools
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
cf443fa7
编写于
6月 06, 2018
作者:
C
CodFrm
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
视频线路记录 & README.md #19
上级
da9c73cd
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
38 addition
and
39 deletion
+38
-39
README.md
README.md
+13
-3
build/cxmooc-tools/img/soft/soft_01.png
build/cxmooc-tools/img/soft/soft_01.png
+0
-0
src/cxmooc-tools/action.js
src/cxmooc-tools/action.js
+25
-36
未找到文件。
README.md
浏览文件 @
cf443fa7
...
...
@@ -67,14 +67,24 @@ Build->扩展程序->开启开发者模式->加载已解压的扩展程序->目
下载发布版本cxmooc-tools.crx文件,直接拖入浏览器安装
## 说明
PC打开超星慕课课程页面,在视频上方将会
显示一个按钮,单击按钮即可直接将视频看完,但是有一定的风险
PC打开超星慕课课程页面,在视频上方将会
有按钮显示
开始挂机需要先播放视频后,再点击,还在优化中
**秒过视频**
功能可直接将视频看完,但是
**有一定的风险**
挂机模式2,还在测试中,不知道有什么样的风险,欢迎反馈,如果能成功,将在全自动挂机迈出一大步^_^
开始挂机(钩为已经实现,空为更新内容):
*
[x] 后台挂机
*
[x] 视频内题目填充(选择类型的题目,填空的没有案例,未测试)
*
[ ] 视频源选择
*
[ ] 自动下一集
![](
/build/cxmooc-tools/img/soft/soft_01.png
)
#### 题库
关于题库,可以访问该页面:
[
https://github.com/CodFrm/cxmooc-tools/issues/16
](
https://github.com/CodFrm/cxmooc-tools/issues/16
)
不定期的更新题库文件,因为没有自己手动的去收集题目,所以大部分题目
**需要有人第一次做过**
,后来的人才能搜索到题目
## 其他
如果有兴趣的可以来一起开发,完善功能
...
...
build/cxmooc-tools/img/soft/soft_01.png
查看替换文件 @
da9c73cd
浏览文件 @
cf443fa7
19.5 KB
|
W:
|
H:
20.6 KB
|
W:
|
H:
2-up
Swipe
Onion skin
src/cxmooc-tools/action.js
浏览文件 @
cf443fa7
...
...
@@ -26,22 +26,35 @@ window.monitorPlay = function () {
window
.
removeOldPlayer
=
function
(
obj
)
{
//移除老的视频对象
console
.
log
(
obj
);
paras
=
obj
.
parentNode
.
parentNode
;
console
.
log
(
obj
.
parentNode
.
parentNode
.
removeChild
(
obj
.
parentNode
));
// <div id="note1-wrap">
// <div id="hl"></div>
// <div id="note1">
// 正在为您加载视频...
// </div>
// </div>
var
parent
=
obj
.
parentNode
.
parentNode
;
obj
.
parentNode
.
parentNode
.
removeChild
(
obj
.
parentNode
);
var
note
=
this
.
document
.
getElementById
(
'
note
'
);
var
note1
=
document
.
createElement
(
'
div
'
);
note1
.
id
=
'
note1-wrap
'
;
note1
.
innerHTML
=
'
<div id="hl"></div><div id="note1">cxmooc-tools正在为您更换播放器...</div></div>
'
;
document
.
body
.
insertBefore
(
note1
,
note
);
newPlayer
();
// obj.setAttribute('data', document.head.getAttribute('url') + 'player/cxmooc-tools.swf?v=' + document.head.getAttribute('v'));
//对线路进行监控和切换
$
(
parent
).
bind
(
'
onChangeLine
'
,
function
(
h
,
g
)
{
//监听线路切换
localStorage
[
'
lineIndex
'
]
=
g
;
});
var
timer
=
setInterval
(
function
()
{
var
obj
=
document
.
querySelector
(
'
object
'
);
if
(
obj
!=
null
)
{
clearInterval
(
timer
);
//切换上一次记录的线路,如果没有或者为0就不进行切换了
if
(
localStorage
[
'
lineIndex
'
]
==
undefined
||
localStorage
[
'
lineIndex
'
]
==
0
){
return
;
}
var
flashvars
=
obj
.
querySelector
(
'
[name="flashvars"]
'
).
getAttribute
(
'
value
'
);
obj
.
querySelector
(
'
[name="flashvars"]
'
).
setAttribute
(
'
value
'
,
flashvars
.
replace
(
'
dftLineIndex%22%3A0%2C%22
'
,
'
dftLineIndex%22%3A
'
+
localStorage
[
'
lineIndex
'
]
+
'
%2C%22
'
)
);
obj
.
setAttribute
(
'
data
'
,
obj
.
getAttribute
(
'
data
'
));
}
},
500
);
}
/**
...
...
@@ -88,32 +101,8 @@ window.newPlayer = function () {
data
:
paras
,
height
:
540
,
width
:
676
,
playerPath
:
document
.
head
.
getAttribute
(
'
url
'
)
+
'
player/cxmooc-tools.swf?v=
'
+
document
.
head
.
getAttribute
(
'
v
'
),
ResourcePlugPath
:
document
.
head
.
getAttribute
(
'
url
'
)
+
'
player/ResourcePlug.swf?v=
'
+
document
.
head
.
getAttribute
(
'
v
'
),
});
}
function
showHTML5Player
(
paras
)
{
loadMultiFile
([{
href
:
'
videoplayer/video-js.css
'
,
tag
:
'
link
'
,
rel
:
'
stylesheet
'
},
{
src
:
'
videoplayer/video.js
'
,
tag
:
'
script
'
,
type
:
'
text/javascript
'
,
defer
:
'
defer
'
}],
function
()
{
var
html
=
[
'
<video id="video" class="video-js vjs-default-skin" controls preload="auto" width="100%" height="100%" poster="{0}" data-setup="{}">
'
,
'
<source src="{1}" type="video/mp4">
'
,
'
<source src="video.webm" type="video/webm">
'
,
'
</video>
'
].
join
(
''
);
html
=
Ext
.
String
.
format
(
html
,
paras
.
screenshot
,
paras
.
http
);
Ext
.
get
(
'
reader
'
).
setHTML
(
html
);
playerPath
:
document
.
head
.
getAttribute
(
'
url
'
)
+
'
player/cxmooc-tools.swf?v=
'
+
document
.
head
.
getAttribute
(
'
v
'
),
ResourcePlugPath
:
document
.
head
.
getAttribute
(
'
url
'
)
+
'
player/ResourcePlug.swf?v=
'
+
document
.
head
.
getAttribute
(
'
v
'
),
});
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录