forked from x/icebergs
add macosx
This commit is contained in:
parent
2d3adedc57
commit
4ae646ba30
@ -57,6 +57,9 @@ func ProcessCommand(m *ice.Message, cmd string, args []string, arg ...string) {
|
||||
m.Cmdy(cmd, arg[1:])
|
||||
}
|
||||
}
|
||||
func ProcessCmds(m *ice.Message, cmd string, arg ...string) {
|
||||
m.Cmdy(COMMAND, cmd).Push(ice.ARG, kit.Format(arg)).ProcessField(ACTION, ice.RUN, cmd)
|
||||
}
|
||||
|
||||
func ProcessRefresh(m *ice.Message, arg ...string) { m.ProcessRefresh(arg...) }
|
||||
func ProcessRewrite(m *ice.Message, arg ...ice.Any) { m.ProcessRewrite(arg...) }
|
||||
|
@ -120,6 +120,7 @@ const (
|
||||
OFFEND = "offend"
|
||||
OFFSET = "offset"
|
||||
|
||||
ICON = "icon"
|
||||
PAGE = "page"
|
||||
NEXT = "next"
|
||||
PREV = "prev"
|
||||
@ -140,6 +141,11 @@ var Index = &ice.Context{Name: MDB, Help: "数据模块", Commands: ice.Commands
|
||||
ice.CTX_INIT: {Hand: func(m *ice.Message, arg ...string) {}},
|
||||
ice.CTX_EXIT: {Hand: func(m *ice.Message, arg ...string) {}},
|
||||
INPUTS: {Name: "inputs key sub type field value", Hand: func(m *ice.Message, arg ...string) {
|
||||
switch arg[3] {
|
||||
case "index":
|
||||
m.Cmdy("command", SEARCH, "command", "", "", ice.OptionFields("index"))
|
||||
return
|
||||
}
|
||||
kit.Switch(arg[2],
|
||||
HASH, func() { _hash_inputs(m, arg[0], arg[1], kit.Select(NAME, arg, 3), kit.Select("", arg, 4)) },
|
||||
ZONE, func() { _zone_inputs(m, arg[0], arg[1], arg[3], kit.Select(NAME, arg, 4), kit.Select("", arg, 5)) },
|
||||
|
@ -111,7 +111,7 @@ func GoToast(m *ice.Message, title string, cb func(toast func(string, int, int))
|
||||
kit.If(total == 0, func() { total = 1 })
|
||||
Toast(m,
|
||||
kit.Format("%s %s/%s", name, strings.TrimSuffix(kit.FmtSize(int64(count)), "B"), strings.TrimSuffix(kit.FmtSize(int64(total)), "B")),
|
||||
kit.Format("%s %d%%", title, count*100/total), kit.Select("3000", "30000", count < total), count*100/total,
|
||||
kit.Format("%s %d%%", title, count*100/total), kit.Select("1000", "30000", count < total), count*100/total,
|
||||
)
|
||||
})
|
||||
}
|
||||
|
@ -34,6 +34,9 @@ func init() {
|
||||
ctx.CONFIG: {Hand: func(m *ice.Message, arg ...string) {
|
||||
ctx.ProcessField(m, ctx.CONFIG, arg, arg...)
|
||||
}},
|
||||
"help": {Hand: func(m *ice.Message, arg ...string) {
|
||||
ctx.ProcessField(m, web.WIKI_WORD, []string{"src/document/" + arg[0] + "/list.shy"}, arg...)
|
||||
}},
|
||||
}, ctx.CmdAction(), aaa.WhiteAction(ctx.COMMAND, ice.RUN)), Hand: func(m *ice.Message, arg ...string) {
|
||||
m.Result(kit.Select(mdb.Config(m, TITLE), ice.Info.Make.Email))
|
||||
}},
|
||||
|
Loading…
x
Reference in New Issue
Block a user