mirror of
https://shylinux.com/x/volcanos
synced 2025-04-25 16:58:06 +08:00
opt share
This commit is contained in:
parent
22c2690809
commit
6f78a40a1e
4
.gitignore
vendored
4
.gitignore
vendored
@ -1,7 +1,7 @@
|
|||||||
*.swp
|
*.swp
|
||||||
*.swo
|
*.swo
|
||||||
can.js
|
cmd.js
|
||||||
can.css
|
cmd.css
|
||||||
cache.js
|
cache.js
|
||||||
cache.css
|
cache.css
|
||||||
.DS_Store
|
.DS_Store
|
||||||
|
3
frame.js
3
frame.js
@ -26,7 +26,8 @@ Volcanos("onengine", {help: "搜索引擎", list: [], _init: function(can, meta,
|
|||||||
_search: function(event, can, msg, panel, cmds, cb) {
|
_search: function(event, can, msg, panel, cmds, cb) {
|
||||||
var sub, mod = can, fun = can, key = ""; can.core.List(cmds[1].split("."), function(value) {
|
var sub, mod = can, fun = can, key = ""; can.core.List(cmds[1].split("."), function(value) {
|
||||||
fun && (sub = mod, mod = fun, fun = mod[value], key = value)
|
fun && (sub = mod, mod = fun, fun = mod[value], key = value)
|
||||||
}); if (!sub || !mod || !fun) { can.misc.Warn("not found", cmds)
|
}); if (!sub || !mod || !fun) {
|
||||||
|
// can.misc.narn("not found", cmds)
|
||||||
return can.base.isFunc(cb) && cb(msg.Echo("warn: ", "not found: ", cmds))
|
return can.base.isFunc(cb) && cb(msg.Echo("warn: ", "not found: ", cmds))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
|
<head>
|
||||||
|
<link rel="stylesheet" type="text/css" href="/page/cmd.css">
|
||||||
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<!-- <script src="/proto.js"></script> -->
|
<script src="/page/cmd.js"></script>
|
||||||
<script src="/page/can.js"></script>
|
<script>cmd()</script>
|
||||||
<script>app("/chat/")</script>
|
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
|
@ -96,7 +96,8 @@ Volcanos("onaction", {help: "交互操作", list: [], _init: function(can, msg,
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
can.onimport._share(can, can.user.Search(can, can._SHARE))
|
var ls = location.pathname.split("/")
|
||||||
|
can.onimport._share(can, can.user.Search(can, can._SHARE) || ls[1]=="share" && ls[2])
|
||||||
},
|
},
|
||||||
onresize: function(can, msg, width, height) { var args = {width: width, height: height}
|
onresize: function(can, msg, width, height) { var args = {width: width, height: height}
|
||||||
can.Conf(args), can.onengine.signal(can, "onaction_resize", can.request({}, args))
|
can.Conf(args), can.onengine.signal(can, "onaction_resize", can.request({}, args))
|
||||||
|
8
proto.js
8
proto.js
@ -131,6 +131,7 @@ const html = {
|
|||||||
ITEM: "item",
|
ITEM: "item",
|
||||||
LIST: "list",
|
LIST: "list",
|
||||||
}
|
}
|
||||||
|
|
||||||
function shy(help, meta, list, cb) {
|
function shy(help, meta, list, cb) {
|
||||||
var index = 0, args = arguments; function next(check) {
|
var index = 0, args = arguments; function next(check) {
|
||||||
if (index < args.length && (!check || check == typeof args[index])) {
|
if (index < args.length && (!check || check == typeof args[index])) {
|
||||||
@ -238,11 +239,10 @@ Volcanos.meta._load = function(url, cb) {
|
|||||||
return item
|
return item
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
function cmd(tool) {
|
||||||
function app(name, tool) {
|
Volcanos({name: "chat", iceberg: "/chat/", volcano: "/frame.js", preload: [],
|
||||||
Volcanos({name: name, iceberg: "/chat/", volcano: "/frame.js", preload: ["/page/can.css"],
|
|
||||||
libs: ["/lib/base.js", "/lib/core.js", "/lib/misc.js", "/lib/page.js", "/lib/user.js"],
|
libs: ["/lib/base.js", "/lib/core.js", "/lib/misc.js", "/lib/page.js", "/lib/user.js"],
|
||||||
panels: [{name: "cmd", help: "工作台", pos: "main", tool: tool}], main: {name: "Header", list: []}, plugin: [
|
panels: [{name: "cmd", help: "工作台", pos: "main", tool: tool}], main: {name: "cmd", list: []}, plugin: [
|
||||||
"/plugin/state.js",
|
"/plugin/state.js",
|
||||||
"/plugin/input.js",
|
"/plugin/input.js",
|
||||||
"/plugin/table.js",
|
"/plugin/table.js",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user