Browse Source

Pull request #1827: 无JIRA任务 适配updateMode: "manual"的回滚

Merge in VISUAL/fineui from ~DAILER/fineui:master to master

* commit '959c26e25f60d80303ff0f6aadaf1ec815d979aa':
  无JIRA任务 适配updateMode: "manual"的回滚
es6
parent
commit
5fe3e3d4ae
  1. 11
      src/core/widget.js

11
src/core/widget.js

@ -7,7 +7,7 @@
*/ */
!(function () { !(function () {
function callLifeHook (self, life) { function callLifeHook(self, life) {
var hook = self.options[life] || self[life]; var hook = self.options[life] || self[life];
if (hook) { if (hook) {
var hooks = BI.isArray(hook) ? hook : [hook]; var hooks = BI.isArray(hook) ? hook : [hook];
@ -76,7 +76,8 @@
shouldUpdate: null, shouldUpdate: null,
update: null, update: function () {
},
beforeUpdate: null, beforeUpdate: null,
@ -98,7 +99,7 @@
_initRender: function () { _initRender: function () {
var self = this; var self = this;
function render () { function render() {
if (self.options.beforeRender || self.beforeRender) { if (self.options.beforeRender || self.beforeRender) {
(self.options.beforeRender || self.beforeRender).call(self, BI.bind(self._render, self)); (self.options.beforeRender || self.beforeRender).call(self, BI.bind(self._render, self));
} else { } else {
@ -593,12 +594,12 @@
BI.Widget.context = context = contextStack.pop(); BI.Widget.context = context = contextStack.pop();
}; };
function pushTarget (_current) { function pushTarget(_current) {
if (current) currentStack.push(current); if (current) currentStack.push(current);
BI.Widget.current = current = _current; BI.Widget.current = current = _current;
} }
function popTarget () { function popTarget() {
BI.Widget.current = current = currentStack.pop(); BI.Widget.current = current = currentStack.pop();
} }

Loading…
Cancel
Save