forked from x/icebergs
add some
This commit is contained in:
parent
e4fc6f7a8f
commit
c16a622aed
@ -247,6 +247,9 @@ func init() {
|
|||||||
kit.Switch(m.Option(mdb.TYPE), []string{WORKER, SERVER}, func() { m.PushButton(OPEN, ice.MAIN) })
|
kit.Switch(m.Option(mdb.TYPE), []string{WORKER, SERVER}, func() { m.PushButton(OPEN, ice.MAIN) })
|
||||||
}},
|
}},
|
||||||
}, DreamAction(), mdb.ImportantHashAction(ctx.TOOLS, "web.space,web.route,web.code.git.search", mdb.SHORT, mdb.NAME, mdb.FIELD, "time,name,icon,repos,binary,template")), Hand: func(m *ice.Message, arg ...string) {
|
}, DreamAction(), mdb.ImportantHashAction(ctx.TOOLS, "web.space,web.route,web.code.git.search", mdb.SHORT, mdb.NAME, mdb.FIELD, "time,name,icon,repos,binary,template")), Hand: func(m *ice.Message, arg ...string) {
|
||||||
|
if ice.Info.NodeType == WORKER {
|
||||||
|
return
|
||||||
|
}
|
||||||
if len(arg) == 0 {
|
if len(arg) == 0 {
|
||||||
_dream_list(m).RewriteAppend(func(value, key string, index int) string {
|
_dream_list(m).RewriteAppend(func(value, key string, index int) string {
|
||||||
if key == mdb.ICON {
|
if key == mdb.ICON {
|
||||||
|
@ -16,6 +16,7 @@ import (
|
|||||||
"shylinux.com/x/icebergs/base/ssh"
|
"shylinux.com/x/icebergs/base/ssh"
|
||||||
"shylinux.com/x/icebergs/base/tcp"
|
"shylinux.com/x/icebergs/base/tcp"
|
||||||
"shylinux.com/x/icebergs/base/web"
|
"shylinux.com/x/icebergs/base/web"
|
||||||
|
"shylinux.com/x/icebergs/base/web/html"
|
||||||
"shylinux.com/x/icebergs/core/chat"
|
"shylinux.com/x/icebergs/core/chat"
|
||||||
kit "shylinux.com/x/toolkits"
|
kit "shylinux.com/x/toolkits"
|
||||||
)
|
)
|
||||||
@ -66,7 +67,13 @@ func init() {
|
|||||||
}},
|
}},
|
||||||
})
|
})
|
||||||
Index.MergeCommands(ice.Commands{
|
Index.MergeCommands(ice.Commands{
|
||||||
VIMER: {Name: "vimer path=src/ file=main.go line=1 list", Icon: "vimer.png", Help: "编辑器", Meta: kit.Dict(ctx.STYLE, INNER), Actions: ice.MergeActions(ice.Actions{
|
VIMER: {Name: "vimer path=src/ file=main.go line=1 list", Icon: "vimer.png", Help: "编辑器", Meta: kit.Dict(
|
||||||
|
ctx.STYLE, INNER,
|
||||||
|
ice.CTX_TRANS, kit.Dict(html.INPUT, kit.Dict(
|
||||||
|
ice.HELP, "帮助",
|
||||||
|
cli.MAIN, "程序",
|
||||||
|
)),
|
||||||
|
), Actions: ice.MergeActions(ice.Actions{
|
||||||
mdb.SEARCH: {Hand: func(m *ice.Message, arg ...string) {
|
mdb.SEARCH: {Hand: func(m *ice.Message, arg ...string) {
|
||||||
if mdb.IsSearchPreview(m, arg) {
|
if mdb.IsSearchPreview(m, arg) {
|
||||||
m.PushSearch(mdb.TYPE, nfs.FILE, mdb.NAME, ice.MAIN, mdb.TEXT, ice.SRC_MAIN_SH)
|
m.PushSearch(mdb.TYPE, nfs.FILE, mdb.NAME, ice.MAIN, mdb.TEXT, ice.SRC_MAIN_SH)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user