MCPcopy Create free account
hub / github.com/LibreSprite/LibreSprite / flipDisplay

Method flipDisplay

src/ui/manager.cpp:175–202  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174
175void Manager::flipDisplay()
176{
177 if (!m_display)
178 return;
179
180 OverlayManager* overlays = OverlayManager::instance();
181
182 update_cursor_overlay();
183
184 // Draw overlays.
185 overlays->captureOverlappedAreas();
186 overlays->drawOverlays();
187
188 // Flip dirty region.
189 {
190 m_dirtyRegion.createIntersection(
191 m_dirtyRegion,
192 gfx::Region(gfx::Rect(0, 0, ui::display_w(), ui::display_h())));
193
194 for (auto& rc : m_dirtyRegion)
195 m_display->flip(rc);
196 m_display->present();
197
198 m_dirtyRegion.clear();
199 }
200
201 overlays->restoreOverlappedAreas();
202}
203
204bool Manager::generateMessages()
205{

Callers 2

onExecuteMethod · 0.80
flashCurrentLayerMethod · 0.80

Calls 12

instanceFunction · 0.85
update_cursor_overlayFunction · 0.85
display_wFunction · 0.85
display_hFunction · 0.85
drawOverlaysMethod · 0.80
flipMethod · 0.80
RegionClass · 0.70
createIntersectionMethod · 0.45
presentMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected