views:

20

answers:

1

Hi there,

I'm using jQuery UI to make an image resizable like this

.resizable({
      handles: 's,e,se'
});

And i would like the se handle to keep aspect ratio, not the other one.

I've tried like this:

   .resizable({
          handles: 's,e'
    }).resizable({
          handles: 'se',
          aspectRatio:true
    });

But it's not working... and Idea ?

Thanks

A: 

I answer to myself:

start: function(e,ui) {
  if (jQuery(e.originalTarget).hasClass("ui-resizable-se")) {
     // Keep aspect ratio function
  }
}
Maïs