Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我知道如果封装的 div 大小发生变化,例如通过调试器控制台,那么我将不得不手动调用grid.resizeCanvas()slickgrid 来重新计算它的大小。每当调整网格的大小时,是否有一个我可以订阅的事件会被调用?
grid.resizeCanvas()
你能解释一下封装的 div 什么时候会调整大小吗?如果它只是在窗口本身调整大小时调整大小,您可以将它放在窗口调整大小处理程序中。
$(window).resize(function(){ grid.resizeCanvas(); });