MCPcopy Index your code
hub / github.com/csev/py4e / onResize

Function onResize

tools/pythonauto/static/codemirrorepl/codemirror.js:2371–2378  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2369 // When the window resizes, we need to refresh active editors.
2370 var resizeTimer;
2371 function onResize() {
2372 if (resizeTimer == null) resizeTimer = setTimeout(function() {
2373 resizeTimer = null;
2374 // Might be a text scaling operation, clear size caches.
2375 d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = knownScrollbarWidth = null;
2376 cm.setSize();
2377 }, 100);
2378 }
2379 on(window, "resize", onResize);
2380 // The above handler holds on to the editor and its data
2381 // structures. Here we poll to unregister it when the editor is no

Callers

nothing calls this directly

Calls 1

setSizeMethod · 0.45

Tested by

no test coverage detected