|
|
@ -36009,6 +36009,13 @@ BI.BasicButton = BI.inherit(BI.Single, { |
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.BasicButton.superclass._init.apply(this, arguments); |
|
|
|
BI.BasicButton.superclass._init.apply(this, arguments); |
|
|
|
var opts = this.options; |
|
|
|
var opts = this.options; |
|
|
|
|
|
|
|
if (opts.selected === true) { |
|
|
|
|
|
|
|
BI.nextTick(BI.bind(function () { |
|
|
|
|
|
|
|
this.setSelected(opts.selected); |
|
|
|
|
|
|
|
}, this)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
BI.nextTick(BI.bind(this.bindEvent, this)); |
|
|
|
|
|
|
|
|
|
|
|
if (opts.shadow) { |
|
|
|
if (opts.shadow) { |
|
|
|
this._createShadow(); |
|
|
|
this._createShadow(); |
|
|
|
} |
|
|
|
} |
|
|
@ -36017,17 +36024,6 @@ BI.BasicButton = BI.inherit(BI.Single, { |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_mount: function () { |
|
|
|
|
|
|
|
var _mount = BI.BasicButton.superclass._mount.apply(this, arguments); |
|
|
|
|
|
|
|
if(_mount === true) { |
|
|
|
|
|
|
|
var o = this.options; |
|
|
|
|
|
|
|
if (o.selected === true) { |
|
|
|
|
|
|
|
this.setSelected(o.selected); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
this.bindEvent(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_createShadow: function () { |
|
|
|
_createShadow: function () { |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
|
|
|
|
|
|
|
@ -36184,8 +36180,8 @@ BI.BasicButton = BI.inherit(BI.Single, { |
|
|
|
|
|
|
|
|
|
|
|
// 之后的300ms点击无效
|
|
|
|
// 之后的300ms点击无效
|
|
|
|
var onClick = BI.debounce(this._doClick, BI.EVENT_RESPONSE_TIME, { |
|
|
|
var onClick = BI.debounce(this._doClick, BI.EVENT_RESPONSE_TIME, { |
|
|
|
leading: true, |
|
|
|
"leading": true, |
|
|
|
trailing: false |
|
|
|
"trailing": false |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
function ev (e) { |
|
|
|
function ev (e) { |
|
|
@ -36411,13 +36407,10 @@ BI.NodeButton = BI.inherit(BI.BasicButton, { |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.NodeButton.superclass._init.apply(this, arguments); |
|
|
|
BI.NodeButton.superclass._init.apply(this, arguments); |
|
|
|
}, |
|
|
|
var self = this; |
|
|
|
|
|
|
|
BI.nextTick(function () { |
|
|
|
_mount: function () { |
|
|
|
self.setOpened(self.isOpened()); |
|
|
|
var _mount = BI.NodeButton.superclass._mount.apply(this, arguments); |
|
|
|
}); |
|
|
|
if(_mount === true) { |
|
|
|
|
|
|
|
this.setOpened(this.isOpened()); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
doClick: function () { |
|
|
|
doClick: function () { |
|
|
|