build run stop
This commit is contained in:
parent
22403f3b83
commit
fae810df5e
|
@ -15,9 +15,13 @@
|
||||||
"Password": "admin",
|
"Password": "admin",
|
||||||
"Workspace": "{pwd}/data/user_workspaces/admin",
|
"Workspace": "{pwd}/data/user_workspaces/admin",
|
||||||
"LatestSessionContent": {
|
"LatestSessionContent": {
|
||||||
"FileTree": [],
|
"FileTree": [
|
||||||
"Files": [],
|
"E:\\Work\\go\\src\\github.com\\b3log\\wide\\data\\user_workspaces\\admin\\src\\mytest"
|
||||||
"CurrentFile": ""
|
],
|
||||||
|
"Files": [
|
||||||
|
"E:\\Work\\go\\src\\github.com\\b3log\\wide\\data\\user_workspaces\\admin\\src\\mytest\\1123"
|
||||||
|
],
|
||||||
|
"CurrentFile": "E:\\Work\\go\\src\\github.com\\b3log\\wide\\data\\user_workspaces\\admin\\src\\mytest\\1123"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
@ -36,5 +36,6 @@
|
||||||
"goto": "跳转",
|
"goto": "跳转",
|
||||||
"input_no_empty": "输入不能为空",
|
"input_no_empty": "输入不能为空",
|
||||||
"tip": "提示",
|
"tip": "提示",
|
||||||
"confirm": "确定"
|
"confirm": "确定",
|
||||||
|
"stop": "停止"
|
||||||
}
|
}
|
|
@ -261,8 +261,9 @@ var wide = {
|
||||||
wide.curProcessId = data.pid;
|
wide.curProcessId = data.pid;
|
||||||
} else if ('run-done' === data.cmd) { // 运行结束
|
} else if ('run-done' === data.cmd) { // 运行结束
|
||||||
wide.curProcessId = undefined;
|
wide.curProcessId = undefined;
|
||||||
|
// 运行结束后修改 [构建&运行] 图标状态为可用状态
|
||||||
// TODO: 运行结束后修改 [构建&运行] 图标状态为可用状态
|
$(".toolbars .ico-stop").removeClass("ico-stop")
|
||||||
|
.addClass("ico-buildrun").attr("title", config.label.build_n_run);
|
||||||
} else if ('build' === data.cmd || 'go install' === data.cmd) {
|
} else if ('build' === data.cmd || 'go install' === data.cmd) {
|
||||||
$('.bottom-window-group .output').text(data.output);
|
$('.bottom-window-group .output').text(data.output);
|
||||||
|
|
||||||
|
@ -275,7 +276,8 @@ var wide = {
|
||||||
message: lint.msg, severity: lint.severity});
|
message: lint.msg, severity: lint.severity});
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: 修改 [构建&运行] 图标状态为可用状态
|
$(".toolbars .ico-stop").removeClass("ico-stop")
|
||||||
|
.addClass("ico-buildrun").attr("title", config.label.build_n_run);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 触发一次 gutter lint
|
// 触发一次 gutter lint
|
||||||
|
@ -352,7 +354,7 @@ var wide = {
|
||||||
// TODO: exit
|
// TODO: exit
|
||||||
},
|
},
|
||||||
stop: function () {
|
stop: function () {
|
||||||
if ($(".toolbars .ico-buildrun").length === 1) {
|
if ($(".toolbars .ico-buildrun").length === 1) {
|
||||||
wide.run();
|
wide.run();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -369,7 +371,8 @@ var wide = {
|
||||||
// $('.bottom-window-group .output').text('');
|
// $('.bottom-window-group .output').text('');
|
||||||
},
|
},
|
||||||
success: function (data) {
|
success: function (data) {
|
||||||
$(".toolbars .ico-stop").removeClass("ico-stop").addClass("ico-buildrun");
|
$(".toolbars .ico-stop").removeClass("ico-stop")
|
||||||
|
.addClass("ico-buildrun").attr("title", config.label.build_n_run);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -393,7 +396,8 @@ var wide = {
|
||||||
$('.bottom-window-group .output').text('');
|
$('.bottom-window-group .output').text('');
|
||||||
},
|
},
|
||||||
success: function (data) {
|
success: function (data) {
|
||||||
$(".toolbars .ico-buildrun").addClass("ico-stop").removeClass("ico-buildrun");
|
$(".toolbars .ico-buildrun").addClass("ico-stop")
|
||||||
|
.removeClass("ico-buildrun").attr("title", config.label.stop);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -195,7 +195,9 @@
|
||||||
"create_file": "{{.i18n.create_file}}",
|
"create_file": "{{.i18n.create_file}}",
|
||||||
"create_dir": "{{.i18n.create_dir}}",
|
"create_dir": "{{.i18n.create_dir}}",
|
||||||
"tip": "{{.i18n.tip}}",
|
"tip": "{{.i18n.tip}}",
|
||||||
"confirm": "{{.i18n.confirm}}"
|
"confirm": "{{.i18n.confirm}}",
|
||||||
|
"build_n_run": "{{.i18n.build_n_run}}",
|
||||||
|
"stop": "{{.i18n.stop}}"
|
||||||
},
|
},
|
||||||
"channel": {
|
"channel": {
|
||||||
"editor": '{{.conf.EditorChannel}}',
|
"editor": '{{.conf.EditorChannel}}',
|
||||||
|
|
Loading…
Reference in New Issue