Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
东方怂天
cxmooc-tools
提交
04b4ab56
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 搜索 >>
提交
04b4ab56
编写于
12月 23, 2018
作者:
C
CodFrm
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
秒过确认&视频加速
上级
ff98df7c
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
22 addition
and
1 deletion
+22
-1
src/cxmooc-tools/action.js
src/cxmooc-tools/action.js
+1
-0
src/cxmooc-tools/popup.html
src/cxmooc-tools/popup.html
+4
-0
src/cxmooc-tools/popup.js
src/cxmooc-tools/popup.js
+10
-0
src/cxmooc-tools/start.js
src/cxmooc-tools/start.js
+2
-1
src/cxmooc-tools/video.js
src/cxmooc-tools/video.js
+5
-0
未找到文件。
src/cxmooc-tools/action.js
浏览文件 @
04b4ab56
...
...
@@ -49,6 +49,7 @@ window.monitorPlay = function (playOver, config) {
player
.
play
();
console
.
log
(
config
);
player
.
muted
=
config
.
video_mute
;
player
.
playbackRate
=
config
.
video_multiple
;
}
else
{
clearInterval
(
time
);
}
...
...
src/cxmooc-tools/popup.html
浏览文件 @
04b4ab56
...
...
@@ -70,6 +70,10 @@
<input
type=
"checkbox"
id=
"answer-ignore"
/>
<label
for=
"answer-ignore"
title=
"自动挂机时,忽略掉题目不做,直接跳过"
>
忽略题目
</label>
</div>
<div
class=
"config-item"
style=
"width:120px"
>
<label
for=
"video-multiple"
title=
"视频播放的倍数,1为正常速度"
>
播放速度:
</label>
<input
type=
"text"
id=
"video-multiple"
style=
"font-size: 10px;width: 30%"
placeholder=
"倍"
/>
倍
</div>
<a
href=
"import.html"
target=
"_black"
>
题库导入
</a>
</div>
<div>
...
...
src/cxmooc-tools/popup.js
浏览文件 @
04b4ab56
...
...
@@ -31,6 +31,11 @@ window.onload = function () {
document
.
getElementById
(
'
video-mute
'
).
checked
=
items
.
video_mute
;
document
.
getElementById
(
'
video-mute
'
).
onchange
();
});
chrome
.
storage
.
sync
.
get
(
'
video_multiple
'
,
function
(
items
)
{
document
.
getElementById
(
'
video-multiple
'
).
value
=
items
.
video_multiple
==
undefined
?
1
:
items
.
video_multiple
;
});
chrome
.
storage
.
sync
.
get
(
'
answer_ignore
'
,
function
(
items
)
{
document
.
getElementById
(
'
answer-ignore
'
).
checked
=
items
.
answer_ignore
;
document
.
getElementById
(
'
answer-ignore
'
).
onchange
();
...
...
@@ -71,4 +76,9 @@ window.onload = function () {
'
interval
'
:
document
.
getElementById
(
'
interval
'
).
value
});
}
document
.
getElementById
(
'
video-multiple
'
).
onblur
=
function
()
{
chrome
.
storage
.
sync
.
set
({
'
video_multiple
'
:
document
.
getElementById
(
'
video-multiple
'
).
value
});
}
}
\ No newline at end of file
src/cxmooc-tools/start.js
浏览文件 @
04b4ab56
...
...
@@ -16,7 +16,8 @@ window.onload = function () {
'
interval
'
,
'
auto
'
,
'
video_mute
'
,
'
answer_ignore
'
'
answer_ignore
'
,
'
video_multiple
'
],
function
(
items
)
{
//设置一下配置
console
.
log
(
items
);
...
...
src/cxmooc-tools/video.js
浏览文件 @
04b4ab56
...
...
@@ -304,6 +304,11 @@ module.exports = function (_this, elLogo, index) {
//秒过按钮事件
boom
.
onclick
=
function
()
{
if
(
localStorage
[
'
boom_no_prompt
'
]
==
undefined
||
localStorage
[
'
boom_no_prompt
'
]
!=
1
)
{
var
msg
=
prompt
(
'
秒过视频会产生不良记录,是否继续?如果以后不想再弹出本对话框请在下方填写yes
'
)
if
(
msg
===
null
)
return
;
if
(
msg
===
'
yes
'
)
localStorage
[
'
boom_no_prompt
'
]
=
1
;
}
getVideoInfo
(
function
(
json
)
{
var
playTime
=
parseInt
(
json
.
duration
-
Math
.
random
(
1
,
2
));
send_time_pack
(
playTime
,
function
(
ret
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录