mirror of
https://shylinux.com/x/volcanos
synced 2025-04-25 08:48:06 +08:00
add some
This commit is contained in:
parent
6042b1a00a
commit
59c850714c
1
const.js
1
const.js
@ -355,6 +355,7 @@ var html = {value: {
|
||||
FIELDSET_HEAD: "fieldset.head", FIELDSET_FOOT: "fieldset.foot", FIELDSET_LEFT: "fieldset.left", FIELDSET_MAIN: "fieldset.main",
|
||||
FIELDSET_PANEL: "fieldset.panel", FIELDSET_PLUGIN: "fieldset.plugin", FIELDSET_STORY: "fieldset.story", FIELDSET_PLUG: "fieldset.plug",
|
||||
FIELDSET_FLOAT: "fieldset.float", FIELDSET_INPUT: "fieldset.input",
|
||||
FIELDSET_OUTPUT: "fieldset.output",
|
||||
|
||||
H1: "h1", H2: "h2", H3: "h3", UL: "ul", OL: "ol", LI: "li", BR: "br", HR: "hr",
|
||||
A: "a", SPAN: "span", CODE: "code", DIV: "div",
|
||||
|
@ -1,5 +1,6 @@
|
||||
Volcanos(chat.ONIMPORT, {_init: function(can, msg, cb) { if (can.user.mod.isPod) { delete(can.onfigure.space), delete(can.onfigure.repos) }
|
||||
can.require(["/plugin/local/code/inner.js"], function(can) { can.onimport._last_init(can, msg, function() {
|
||||
can.onappend.style(can, "vimer", can._fields)
|
||||
can.onengine.listen(can, "tabview.line.select", function(msg) { can.onaction._selectLine(can) })
|
||||
can.db.undo = [], can.db.redo = [], can.onimport._input(can), cb && cb(msg)
|
||||
}) })
|
||||
|
@ -16,15 +16,17 @@ Volcanos(chat.ONIMPORT, {
|
||||
_cookie: function(can, msg) { can.misc.Cookie(can, msg._arg[0], msg._arg[1]), can.Update() },
|
||||
_session: function(can, msg) { can.misc.sessionStorage(can, msg._arg[0], msg._arg[1]), can.Update() },
|
||||
_field: function(can, msg, cb) {
|
||||
var height = can.ConfHeight()-can.onexport.actionHeight(can)-can.onexport.statusHeight(can), width = can.ConfWidth()
|
||||
var height = can.ConfHeight()-can.onexport.actionHeight(can)-(can.onexport.statusHeight(can)||1), width = can.ConfWidth()
|
||||
var tabs = false, tabHash = msg.Option("field.tabs")
|
||||
if (tabHash) {
|
||||
can.sub && can.sub.onimport.tabs(can, [{name: tabHash.slice(0, 6)}], function() {
|
||||
can.onmotion.cache(can, function() { return tabHash })
|
||||
}), tabs = true
|
||||
} else {
|
||||
if (!can.page.tagis(can._target, html.FIELDSET_OUTPUT)) {
|
||||
height = can.base.Max(html.STORY_HEIGHT, height)
|
||||
}
|
||||
}
|
||||
msg.Table(function(item) { tabs && can.onmotion.cache(can, function() { return tabHash })
|
||||
can.onappend._plugin(can, item, {index: item.index, args: can.base.Obj(item.args||item.arg, []), height: height, width: width}, function(sub) { can._plugins = (can._plugins||[]).concat([sub])
|
||||
sub.run = function(event, cmds, cb) { var index = msg.Option(ice.MSG_INDEX); can.run(can.request(event, {pod: item.space}), (msg[ice.MSG_PREFIX]? msg[ice.MSG_PREFIX]: index? [ctx.RUN, index]: []).concat(cmds), cb, true) }
|
||||
|
@ -157,7 +157,7 @@ Volcanos(chat.ONIMPORT, {_init: function(can, msg, target) {
|
||||
], _init: function(target) {
|
||||
item._select && (_select = target)
|
||||
}, onclick: function(event) {
|
||||
cb(event, item, event.currentTarget._list && can.onmotion.toggle(can, event.currentTarget._list))
|
||||
cb(event, item, event.currentTarget._list && can.onmotion.toggle(can, event.currentTarget._list), event.currentTarget)
|
||||
}, oncontextmenu: function(event) {
|
||||
if (can.base.isFunc(cbs)) { var menu = cbs(event, event.currentTarget); if (menu) { return can.user.carteRight(event, can, menu.meta, menu.list, menu) } }
|
||||
can.user.carteItem(event, can, item)
|
||||
|
Loading…
x
Reference in New Issue
Block a user