Open claravanstaden opened 10 years ago
Found it. Issue was related to Destroy/init stylesheet issue #227.
Fixed by adding Gridster.generated_stylesheets = []; to destroy().
@Clar64, could you please create a pull request?
It would probably be better to add that clearing of the generated stylesheets to the remove_style_tags function. That function is called in the destroy function anyway, but that way if the function is used on it's own, that cache will be cleared as well.
I have more issues which I suspect comes from this issue. I have multiple gridster instances. When I destroy an instance, and create it again, the drag stop callback function does not get invoked anymore.
I'd like to change the Gridster options at runtime, but I run into some issues. Sometimes the options change, other times they don't. The options values are from input fields.
Am I doing something wrong?
gridster.options.widget_margins = [parseInt(margin_size),parseInt(margin_size)]; gridster.options.widget_base_dimensions = [parseInt(widget_size),parseInt(widget_size)]; gridster.generate_grid_and_stylesheet();