MCPcopy
hub / github.com/microsoft/SandDance / resizeRenderer

Function resizeRenderer

docs/app/js/sanddance-app.js:141740–141752  ·  view source on GitHub ↗
(view)

Source from the content-addressed store, hash-verified

141738 ];
141739}
141740function resizeRenderer(view) {
141741 var origin = offset(view), w = width(view), h = height(view);
141742 view._renderer.background(view.background());
141743 view._renderer.resize(w, h, origin);
141744 view._handler.origin(origin);
141745 view._resizeListeners.forEach((handler)=>{
141746 try {
141747 handler(w, h);
141748 } catch (error) {
141749 view.error(error);
141750 }
141751 });
141752}
141753/**
141754 * Extend an event with additional view-specific methods.
141755 * Adds a new property ('vega') to an event that provides a number

Callers 1

evaluateFunction · 0.70

Calls 7

offsetFunction · 0.70
widthFunction · 0.70
heightFunction · 0.70
handlerFunction · 0.70
resizeMethod · 0.45
forEachMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected