Skip to content
Permalink
Browse files

alsoResize option bug fixes

  • Loading branch information
eduardolundgren committed Jun 26, 2008
1 parent 76f414b commit 70c593f4412c159797d1a6ae9ee1f1e4131b2a43
Showing with 2 additions and 1 deletion.
  1. +2 −1 ui/ui.resizable.js
@@ -722,7 +722,8 @@ $.ui.plugin.add("resizable", "alsoResize", {
};

if (typeof(o.alsoResize) == 'object') {
$.each(o.alsoResize, function(exp, c) { _store(exp); });
if (o.alsoResize.length) { o.alsoResize = o.alsoResize[0]; _store(o.alsoResize); }
else { $.each(o.alsoResize, function(exp, c) { _store(exp); }); }
}else{
_store(o.alsoResize);
}

4 comments on commit 70c593f

@benmosher

This comment has been minimized.

Copy link
Contributor

@benmosher benmosher replied Aug 25, 2014

Why was this necessary? Over 6 years later, I find myself commenting out everything but the _store(o.alsoResize) on line 727(->8). And this fixes the issue (for me) that that o.alsoResize[0] creates: adding a jQuery selection as alsoResize ignores all but the first element in the set.

//      if (typeof(o.alsoResize) === "object" && !o.alsoResize.parentNode) {
//          if (o.alsoResize.length) { o.alsoResize = o.alsoResize[0]; _store(o.alsoResize); }
//          else { $.each(o.alsoResize, function (exp) { _store(exp); }); }
//      }else{
            _store(o.alsoResize);
//      }

Is it still necessary? I don't understand the nature of the change.

@scottgonzalez

This comment has been minimized.

Copy link
Member

@scottgonzalez scottgonzalez replied Aug 25, 2014

I wouldn't expect to get any actual response here.

@benmosher

This comment has been minimized.

Copy link
Contributor

@benmosher benmosher replied Aug 25, 2014

Fair enough. Just figured I'd give it a try at the source.

@eduardolundgren

This comment has been minimized.

Copy link
Author

@eduardolundgren eduardolundgren replied Aug 25, 2014

This change was a long time ago, feel free to re-evaluate the behavior and add any fix needed. Thanks for reporting.

Please sign in to comment.
You can’t perform that action at this time.