guy 8 years ago
parent
commit
497ee62de9
  1. 9
      bi/base.js
  2. 4
      bi/case.js
  3. 6
      bi/core.js
  4. 9
      docs/base.js
  5. 4
      docs/case.js
  6. 6
      docs/core.js
  7. 9
      src/base/layer/layer.floatbox.js
  8. 4
      src/case/clipboard/index.js
  9. 6
      src/core/ob.js

9
bi/base.js

@ -15109,15 +15109,16 @@ BI.FloatBox = BI.inherit(BI.Widget, {
populate: function (sectionProvider) { populate: function (sectionProvider) {
var self = this; var self = this;
if (this.currentSectionProvider && this.currentSectionProvider !== sectionProvider) {
this.currentSectionProvider.destroy();
}
this.currentSectionProvider = sectionProvider; this.currentSectionProvider = sectionProvider;
sectionProvider.rebuildNorth(this._north); sectionProvider.rebuildNorth(this._north);
sectionProvider.rebuildCenter(this._center); sectionProvider.rebuildCenter(this._center);
sectionProvider.rebuildSouth(this._south); sectionProvider.rebuildSouth(this._south);
if (sectionProvider instanceof BI.Widget) {
sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () { sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () {
self.close(); self.close();
}) })
}
}, },
show: function () { show: function () {
@ -15140,6 +15141,10 @@ BI.FloatBox = BI.inherit(BI.Widget, {
setZindex: function (zindex) { setZindex: function (zindex) {
this.element.css({"z-index": zindex}); this.element.css({"z-index": zindex});
},
destroyed: function () {
this.currentSectionProvider && this.currentSectionProvider.destroy();
} }
}); });

4
bi/case.js

@ -3567,9 +3567,7 @@ BI.ClipBoard = BI.inherit(BI.BasicButton, {
return BI.isFunction(o.copy) ? o.copy() : o.copy; return BI.isFunction(o.copy) ? o.copy() : o.copy;
} }
}); });
this.clipboard.on("success", function (e) { this.clipboard.on("success", o.afterCopy)
o.afterCopy();
})
} else { } else {
this.element.zclip({ this.element.zclip({
path: BI.resourceURL + "/ZeroClipboard.swf", path: BI.resourceURL + "/ZeroClipboard.swf",

6
bi/core.js

@ -4198,6 +4198,7 @@ BI.OB = function (config) {
$.extend(BI.OB.prototype, { $.extend(BI.OB.prototype, {
props: {}, props: {},
init: null, init: null,
destroyed: null,
_defaultConfig: function (config) { _defaultConfig: function (config) {
return {}; return {};
@ -4317,6 +4318,11 @@ $.extend(BI.OB.prototype, {
} }
} }
return true; return true;
},
destroy: function () {
this.destroyed && this.destroyed();
this.purgeListeners();
} }
});/** });/**
* Widget超类 * Widget超类

9
docs/base.js

@ -15109,15 +15109,16 @@ BI.FloatBox = BI.inherit(BI.Widget, {
populate: function (sectionProvider) { populate: function (sectionProvider) {
var self = this; var self = this;
if (this.currentSectionProvider && this.currentSectionProvider !== sectionProvider) {
this.currentSectionProvider.destroy();
}
this.currentSectionProvider = sectionProvider; this.currentSectionProvider = sectionProvider;
sectionProvider.rebuildNorth(this._north); sectionProvider.rebuildNorth(this._north);
sectionProvider.rebuildCenter(this._center); sectionProvider.rebuildCenter(this._center);
sectionProvider.rebuildSouth(this._south); sectionProvider.rebuildSouth(this._south);
if (sectionProvider instanceof BI.Widget) {
sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () { sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () {
self.close(); self.close();
}) })
}
}, },
show: function () { show: function () {
@ -15140,6 +15141,10 @@ BI.FloatBox = BI.inherit(BI.Widget, {
setZindex: function (zindex) { setZindex: function (zindex) {
this.element.css({"z-index": zindex}); this.element.css({"z-index": zindex});
},
destroyed: function () {
this.currentSectionProvider && this.currentSectionProvider.destroy();
} }
}); });

4
docs/case.js

@ -3567,9 +3567,7 @@ BI.ClipBoard = BI.inherit(BI.BasicButton, {
return BI.isFunction(o.copy) ? o.copy() : o.copy; return BI.isFunction(o.copy) ? o.copy() : o.copy;
} }
}); });
this.clipboard.on("success", function (e) { this.clipboard.on("success", o.afterCopy)
o.afterCopy();
})
} else { } else {
this.element.zclip({ this.element.zclip({
path: BI.resourceURL + "/ZeroClipboard.swf", path: BI.resourceURL + "/ZeroClipboard.swf",

6
docs/core.js

@ -14200,6 +14200,7 @@ BI.OB = function (config) {
$.extend(BI.OB.prototype, { $.extend(BI.OB.prototype, {
props: {}, props: {},
init: null, init: null,
destroyed: null,
_defaultConfig: function (config) { _defaultConfig: function (config) {
return {}; return {};
@ -14319,6 +14320,11 @@ $.extend(BI.OB.prototype, {
} }
} }
return true; return true;
},
destroy: function () {
this.destroyed && this.destroyed();
this.purgeListeners();
} }
});/** });/**
* Widget超类 * Widget超类

9
src/base/layer/layer.floatbox.js

@ -105,15 +105,16 @@ BI.FloatBox = BI.inherit(BI.Widget, {
populate: function (sectionProvider) { populate: function (sectionProvider) {
var self = this; var self = this;
if (this.currentSectionProvider && this.currentSectionProvider !== sectionProvider) {
this.currentSectionProvider.destroy();
}
this.currentSectionProvider = sectionProvider; this.currentSectionProvider = sectionProvider;
sectionProvider.rebuildNorth(this._north); sectionProvider.rebuildNorth(this._north);
sectionProvider.rebuildCenter(this._center); sectionProvider.rebuildCenter(this._center);
sectionProvider.rebuildSouth(this._south); sectionProvider.rebuildSouth(this._south);
if (sectionProvider instanceof BI.Widget) {
sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () { sectionProvider.on(BI.PopoverSection.EVENT_CLOSE, function () {
self.close(); self.close();
}) })
}
}, },
show: function () { show: function () {
@ -136,6 +137,10 @@ BI.FloatBox = BI.inherit(BI.Widget, {
setZindex: function (zindex) { setZindex: function (zindex) {
this.element.css({"z-index": zindex}); this.element.css({"z-index": zindex});
},
destroyed: function () {
this.currentSectionProvider && this.currentSectionProvider.destroy();
} }
}); });

4
src/case/clipboard/index.js

@ -25,9 +25,7 @@ BI.ClipBoard = BI.inherit(BI.BasicButton, {
return BI.isFunction(o.copy) ? o.copy() : o.copy; return BI.isFunction(o.copy) ? o.copy() : o.copy;
} }
}); });
this.clipboard.on("success", function (e) { this.clipboard.on("success", o.afterCopy)
o.afterCopy();
})
} else { } else {
this.element.zclip({ this.element.zclip({
path: BI.resourceURL + "/ZeroClipboard.swf", path: BI.resourceURL + "/ZeroClipboard.swf",

6
src/core/ob.js

@ -15,6 +15,7 @@ BI.OB = function (config) {
$.extend(BI.OB.prototype, { $.extend(BI.OB.prototype, {
props: {}, props: {},
init: null, init: null,
destroyed: null,
_defaultConfig: function (config) { _defaultConfig: function (config) {
return {}; return {};
@ -134,5 +135,10 @@ $.extend(BI.OB.prototype, {
} }
} }
return true; return true;
},
destroy: function () {
this.destroyed && this.destroyed();
this.purgeListeners();
} }
}); });
Loading…
Cancel
Save