Resizable: Partial fix for #3728: Use this._trigger for all events/callbacks.

This commit is contained in:
Scott González 2009-01-03 15:37:51 +00:00
parent fc60db3bbf
commit 695b3e2c1b

View File

@ -340,7 +340,7 @@ $.widget("ui.resizable", $.extend({}, $.ui.mouse, {
this._updateCache(data); this._updateCache(data);
// calling the user callback at the end // calling the user callback at the end
this.element.triggerHandler("resize", [event, this.ui()], this.options["resize"]); this._trigger('resize', event, this.ui());
return false; return false;
}, },
@ -511,7 +511,8 @@ $.widget("ui.resizable", $.extend({}, $.ui.mouse, {
_propagate: function(n, event) { _propagate: function(n, event) {
$.ui.plugin.call(this, n, [event, this.ui()]); $.ui.plugin.call(this, n, [event, this.ui()]);
if (n != "resize") this.element.triggerHandler(["resize", n].join(""), [event, this.ui()], this.options[n]);
(n != "resize" && this._trigger(n, event, this.ui()));
}, },
plugins: {}, plugins: {},
@ -533,6 +534,7 @@ $.widget("ui.resizable", $.extend({}, $.ui.mouse, {
$.extend($.ui.resizable, { $.extend($.ui.resizable, {
version: "@VERSION", version: "@VERSION",
eventPrefix: "resize",
defaults: { defaults: {
alsoResize: false, alsoResize: false,
animate: false, animate: false,