MCPcopy Create free account
hub / github.com/DISTRHO/DPF / onResize

Method onResize

tests/Demo.cpp:228–239  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

226 }
227
228 void onResize(const ResizeEvent& ev) override
229 {
230 const uint width = ev.size.getWidth();
231 const uint height = ev.size.getHeight();
232 const double scaleFactor = getWindow().getScaleFactor();
233
234 bgIcon.setWidth(width - 4 * scaleFactor);
235 bgIcon.setHeight(width - 4 * scaleFactor);
236
237 lineSep.setStartPos(width, 0);
238 lineSep.setEndPos(width, height);
239 }
240
241private:
242 Callback* const callback;

Callers

nothing calls this directly

Calls 7

getWidthMethod · 0.45
getHeightMethod · 0.45
getScaleFactorMethod · 0.45
setWidthMethod · 0.45
setHeightMethod · 0.45
setStartPosMethod · 0.45
setEndPosMethod · 0.45

Tested by

no test coverage detected