Search code examples
gridster

Get new Height and Width of Widget after manual resize


After a make a manual resize of my widget using

gridster.resize_widget ( _widget_container , size_x , size_y);

I need to get the new widget size, but I get always the old height. I need to wait a few miliseconds to get the correct new height and width.

There is any way to get an event when Grister has complete the resize widget?


Solution

  • In current version of gridster you can add a callback function to resize widget:

    .resize_widget( $widget, [size_x], [size_y], [reposition], [callback] )

    You can read details in the gridster page.